diff options
Diffstat (limited to 'external/meta-openembedded/meta-oe/recipes-connectivity')
89 files changed, 1351 insertions, 2871 deletions
diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/gammu/gammu_1.32.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/gammu/gammu_1.32.0.bb index 44411751..fd6b85ff 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/gammu/gammu_1.32.0.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/gammu/gammu_1.32.0.bb @@ -13,7 +13,7 @@ SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}/${PV}/${BP}.tar.bz2 \ SRC_URI[md5sum] = "8ea16c6b3cc48097a8e62311fe0e25b9" SRC_URI[sha256sum] = "de67caa102aa4c8fbed5300e5a0262e40411c4cc79f4379a8d34eed797968fc3" -inherit distutils cmake gettext +inherit distutils3 cmake gettext do_install_append() { # these files seem to only be used by symbian and trigger QA warnings diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/files/0001-cmake-Use-GNUInstallDirs.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/files/0001-cmake-Use-GNUInstallDirs.patch new file mode 100644 index 00000000..ffe0a006 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/files/0001-cmake-Use-GNUInstallDirs.patch @@ -0,0 +1,53 @@ +From 63dc2d0c9384d85482dc4cbb3c179b4b0bb18d4e Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Thu, 19 Dec 2019 22:32:01 -0800 +Subject: [PATCH] cmake: Use GNUInstallDirs + +Helps install cmakefiles in right libdir + +Upstream-Status: Submitted [https://github.com/labapart/gattlib/pull/139] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + CMakeLists.txt | 5 +++-- + dbus/CMakeLists.txt | 18 ++++++++++-------- + 2 files changed, 13 insertions(+), 10 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 12d8d71..ded7239 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -152,7 +152,8 @@ endif() + # + # List of file to install + # +-install(FILES include/gattlib.h DESTINATION include) +-install(FILES ${PROJECT_BINARY_DIR}/gattlib.pc DESTINATION lib/pkgconfig) ++include(GNUInstallDirs) ++install(FILES include/gattlib.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) ++install(FILES ${PROJECT_BINARY_DIR}/gattlib.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + + include(CPack) +diff --git a/dbus/CMakeLists.txt b/dbus/CMakeLists.txt +index f5096ce..cef031f 100644 +--- a/dbus/CMakeLists.txt ++++ b/dbus/CMakeLists.txt +@@ -19,7 +19,7 @@ + # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + # + +-cmake_minimum_required(VERSION 2.6) ++cmake_minimum_required(VERSION 3.0) + + find_package(PkgConfig REQUIRED) + +@@ -119,4 +119,6 @@ endif() + add_library(gattlib SHARED ${gattlib_SRCS}) + target_link_libraries(gattlib ${gattlib_LIBS}) + +-install(TARGETS gattlib LIBRARY DESTINATION lib) ++include(GNUInstallDirs) ++ ++install(TARGETS gattlib LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}) +-- +2.24.1 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/files/dbus-avoid-strange-chars-from-the-build-dir.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/files/dbus-avoid-strange-chars-from-the-build-dir.patch new file mode 100644 index 00000000..96e4f8d6 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/files/dbus-avoid-strange-chars-from-the-build-dir.patch @@ -0,0 +1,70 @@ +From 87df05c3f83c563af76ab00567e7a1ab7a6ebc88 Mon Sep 17 00:00:00 2001 +From: Peter Rosin <peda@axentia.se> +Date: Sat, 9 Nov 2019 15:42:03 +0100 +Subject: [PATCH] dbus: avoid 'strange' chars from the build dir in #defines + +gdbus-codegen uses include guards with the full path dir, and if there +are "bad" characters, such as '+', this fails miserably. E.g. Yocto has a +tendency to build in directories named from the Yocto package version and +that package version containing a '+' are not uncommon, and even the +standard in certain scenarios such as when using ${SRCPV}. + +Avoid the problem of the full path "leaking" into the source by avoiding +the normal include guards and request "#pragma once" instead. + +Signed-off-by: Peter Rosin <peda@axentia.se> +--- + dbus/CMakeLists.txt | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +diff --git a/dbus/CMakeLists.txt b/dbus/CMakeLists.txt +index f5096ce10ecd..013c32239e12 100644 +--- a/dbus/CMakeLists.txt ++++ b/dbus/CMakeLists.txt +@@ -43,37 +43,37 @@ else() + endif() + + add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-adaptater1.c +- COMMAND gdbus-codegen --interface-prefix org.bluez.Adapter1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-adaptater1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Adapter1.xml ++ COMMAND gdbus-codegen --pragma-once --interface-prefix org.bluez.Adapter1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-adaptater1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Adapter1.xml + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Adapter1.xml + COMMENT "Generate D-Bus 'org.bluez.Adapter1.xml'" + ) + + add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-device1.c +- COMMAND gdbus-codegen --interface-prefix org.bluez.Device1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-device1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Device1.xml ++ COMMAND gdbus-codegen --pragma-once --interface-prefix org.bluez.Device1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-device1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Device1.xml + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Device1.xml + COMMENT "Generate D-Bus 'org.bluez.Device1.xml'" + ) + + add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattservice1.c +- COMMAND gdbus-codegen --interface-prefix org.bluez.GattService1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattservice1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattService1.xml ++ COMMAND gdbus-codegen --pragma-once --interface-prefix org.bluez.GattService1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattservice1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattService1.xml + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattService1.xml + COMMENT "Generate D-Bus 'org.bluez.GattService1.xml'" + ) + + add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattcharacteristic1.c +- COMMAND gdbus-codegen --interface-prefix org.bluez.Characteristic1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattcharacteristic1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattCharacteristic1.xml ++ COMMAND gdbus-codegen --pragma-once --interface-prefix org.bluez.Characteristic1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattcharacteristic1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattCharacteristic1.xml + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattCharacteristic1.xml + COMMENT "Generate D-Bus 'org.bluez.GattCharacteristic1.xml'" + ) + + add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattdescriptor1.c +- COMMAND gdbus-codegen --interface-prefix org.bluez.Descriptor1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattdescriptor1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattDescriptor1.xml ++ COMMAND gdbus-codegen --pragma-once --interface-prefix org.bluez.Descriptor1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-gattdescriptor1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattDescriptor1.xml + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.GattDescriptor1.xml + COMMENT "Generate D-Bus 'org.bluez.GattDescriptor1.xml'" + ) + + add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-battery1.c +- COMMAND gdbus-codegen --interface-prefix org.bluez.Battery1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-battery1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Battery1.xml ++ COMMAND gdbus-codegen --pragma-once --interface-prefix org.bluez.Battery1. --generate-c-code ${CMAKE_CURRENT_BINARY_DIR}/org-bluez-battery1 ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Battery1.xml + DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${DBUS_BLUEZ_API}/org.bluez.Battery1.xml + COMMENT "Generate D-Bus 'org.bluez.Battery1.xml'" + ) +-- +2.11.0 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/gattlib_git.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/gattlib_git.bb new file mode 100644 index 00000000..6b4decce --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/gattlib/gattlib_git.bb @@ -0,0 +1,32 @@ +DESCRIPTION = "Bluetooth library with attribute support" +SECTION = "libs/network" + +LICENSE = "GPLv2+" +LIC_FILES_CHKSUM = "file://CMakeLists.txt;beginline=1;endline=20;md5=8d5efeb9189b60866baff80ff791bf00" + +DEPENDS = "bluez5 glib-2.0" +DEPENDS += "glib-2.0-native" + +PV = "0.2+git${SRCPV}" + +SRC_URI = "git://github.com/labapart/gattlib.git \ + file://dbus-avoid-strange-chars-from-the-build-dir.patch \ + file://0001-cmake-Use-GNUInstallDirs.patch \ + " + +SRCBRANCH = "master" +SRCREV = "5c7ee43bd70ee09a7170ddd55b9fdbdef69e9080" + +S = "${WORKDIR}/git" + +PACKAGECONFIG[examples] = "-DGATTLIB_BUILD_EXAMPLES=ON,-DGATTLIB_BUILD_EXAMPLES=OFF" + +# Set this to force use of DBus API if Bluez version is older than 5.42 +PACKAGECONFIG[force-dbus] = "-DGATTLIB_FORCE_DBUS=TRUE,-DGATTLIB_FORCE_DBUS=FALSE" + +EXTRA_OECMAKE += "-DGATTLIB_BUILD_DOCS=OFF" + +inherit pkgconfig cmake + +FILES_${PN} = "${libdir}/* ${includedir}/*" +FILES_${PN}-dev = "${includedir}/*" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/gensio/gensio/0001-filter-Rename-some-variables-to-tr_stdxxx.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/gensio/gensio/0001-filter-Rename-some-variables-to-tr_stdxxx.patch new file mode 100644 index 00000000..dbc48a21 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/gensio/gensio/0001-filter-Rename-some-variables-to-tr_stdxxx.patch @@ -0,0 +1,108 @@ +From 601e6e56f44b91d957bb643662455f52540f336a Mon Sep 17 00:00:00 2001 +From: Corey Minyard <cminyard@mvista.com> +Date: Tue, 25 Feb 2020 16:08:40 -0600 +Subject: [PATCH] filter: Rename some variables to tr_stdxxx + +stdout and stderr can be macros, don't use the names directly. + +Signed-off-by: Corey Minyard <cminyard@mvista.com> +Upstream-Status: Backport [https://github.com/cminyard/gensio/commit/601e6e56f44b91d957bb643662455f52540f336a] +Signed-off-by: Pierre-Jean Texier <pjtexier@koncepto.io> +--- + lib/gensio_filter_trace.c | 28 ++++++++++++++-------------- + 1 file changed, 14 insertions(+), 14 deletions(-) + +diff --git a/lib/gensio_filter_trace.c b/lib/gensio_filter_trace.c +index d39d58b..abe2db6 100644 +--- a/lib/gensio_filter_trace.c ++++ b/lib/gensio_filter_trace.c +@@ -32,8 +32,8 @@ struct trace_filter { + enum trace_dir dir; + bool raw; + char *filename; +- bool stdout; +- bool stderr; ++ bool tr_stdout; ++ bool tr_stderr; + + FILE *tr; + }; +@@ -82,9 +82,9 @@ trace_try_connect(struct gensio_filter *filter, struct timeval *timeout) + { + struct trace_filter *tfilter = filter_to_trace(filter); + +- if (tfilter->stdout) { ++ if (tfilter->tr_stdout) { + tfilter->tr = stdout; +- } else if (tfilter->stderr) { ++ } else if (tfilter->tr_stderr) { + tfilter->tr = stderr; + } else if (tfilter->filename) { + tfilter->tr = fopen(tfilter->filename, "a+"); +@@ -99,7 +99,7 @@ trace_try_disconnect(struct gensio_filter *filter, struct timeval *timeout) + { + struct trace_filter *tfilter = filter_to_trace(filter); + +- if (!tfilter->stdout && !tfilter->stderr && tfilter->tr) ++ if (!tfilter->tr_stdout && !tfilter->tr_stderr && tfilter->tr) + fclose(tfilter->tr); + tfilter->tr = NULL; + return 0; +@@ -331,12 +331,12 @@ static int gensio_trace_filter_func(struct gensio_filter *filter, int op, + + static struct gensio_filter * + gensio_trace_filter_raw_alloc(struct gensio_os_funcs *o, enum trace_dir dir, +- bool raw, const char *filename, bool stdout, +- bool stderr) ++ bool raw, const char *filename, bool tr_stdout, ++ bool tr_stderr) + { + struct trace_filter *tfilter; + +- if (!filename && !stdout && !stderr) ++ if (!filename && !tr_stdout && !tr_stderr) + dir = TRACE_NONE; + + tfilter = o->zalloc(o, sizeof(*tfilter)); +@@ -351,8 +351,8 @@ gensio_trace_filter_raw_alloc(struct gensio_os_funcs *o, enum trace_dir dir, + if (!tfilter->filename) + goto out_nomem; + } +- tfilter->stdout = stdout; +- tfilter->stderr = stderr; ++ tfilter->tr_stdout = tr_stdout; ++ tfilter->tr_stderr = tr_stderr; + + tfilter->lock = o->alloc_lock(o); + if (!tfilter->lock) +@@ -385,7 +385,7 @@ gensio_trace_filter_alloc(struct gensio_os_funcs *o, + { + struct gensio_filter *filter; + int dir = TRACE_NONE; +- bool raw = false, stdout = false, stderr = false; ++ bool raw = false, tr_stdout = false, tr_stderr = false; + const char *filename = NULL; + unsigned int i; + +@@ -396,15 +396,15 @@ gensio_trace_filter_alloc(struct gensio_os_funcs *o, + continue; + if (gensio_check_keyvalue(args[i], "file", &filename) > 0) + continue; +- if (gensio_check_keybool(args[i], "stdout", &stdout) > 0) ++ if (gensio_check_keybool(args[i], "stdout", &tr_stdout) > 0) + continue; +- if (gensio_check_keybool(args[i], "stderr", &stderr) > 0) ++ if (gensio_check_keybool(args[i], "stderr", &tr_stderr) > 0) + continue; + return GE_INVAL; + } + + filter = gensio_trace_filter_raw_alloc(o, dir, raw, filename, +- stdout, stderr); ++ tr_stdout, tr_stderr); + if (!filter) + return GE_NOMEM; + +-- +2.7.4 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/gensio/gensio_1.5.3.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/gensio/gensio_1.5.3.bb new file mode 100644 index 00000000..8c97662d --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/gensio/gensio_1.5.3.bb @@ -0,0 +1,27 @@ +SUMMARY = "A library to abstract stream I/O like serial port, TCP, telnet, etc" +HOMEPAGE = "https://github.com/cminyard/gensio" +LICENSE = "GPL-2.0 & LGPL-2.1" +LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=a0fd36908af843bcee10cb6dfc47fa67 \ + file://COPYING;md5=bae3019b4c6dc4138c217864bd04331f \ + " + +SRCREV = "95ec1ab31ee97411fc37156d12061adcf0331598" +PV = "1.5.3+git${SRCPV}" + +SRC_URI = "git://github.com/cminyard/gensio;protocol=https \ + file://0001-filter-Rename-some-variables-to-tr_stdxxx.patch \ + " + +S = "${WORKDIR}/git" + +inherit autotools + +PACKAGECONFIG ??= "openssl tcp-wrappers" + +PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_DIR_HOST}${prefix},--without-openssl, openssl" +PACKAGECONFIG[tcp-wrappers] = "--with-tcp-wrappers,--without-tcp-wrappers, tcp-wrappers" +PACKAGECONFIG[swig] = "--with-swig,--without-swig, swig" + +EXTRA_OECONF = "--without-python" + +RDEPENDS_${PN} += "bash" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0001-hostapd-Avoid-key-reinstallation-in-FT-handshake.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0001-hostapd-Avoid-key-reinstallation-in-FT-handshake.patch deleted file mode 100644 index 5535a3c5..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0001-hostapd-Avoid-key-reinstallation-in-FT-handshake.patch +++ /dev/null @@ -1,177 +0,0 @@ -From 044ae35c5694c39a4aca2a33502cc3897e88f79e Mon Sep 17 00:00:00 2001 -From: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be> -Date: Fri, 14 Jul 2017 15:15:35 +0200 -Subject: [PATCH 1/7] hostapd: Avoid key reinstallation in FT handshake - -Do not reinstall TK to the driver during Reassociation Response frame -processing if the first attempt of setting the TK succeeded. This avoids -issues related to clearing the TX/RX PN that could result in reusing -same PN values for transmitted frames (e.g., due to CCM nonce reuse and -also hitting replay protection on the receiver) and accepting replayed -frames on RX side. - -This issue was introduced by the commit -0e84c25434e6a1f283c7b4e62e483729085b78d2 ('FT: Fix PTK configuration in -authenticator') which allowed wpa_ft_install_ptk() to be called multiple -times with the same PTK. While the second configuration attempt is -needed with some drivers, it must be done only if the first attempt -failed. - -Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be> - -Upstream-Status: Backport -Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> ---- - src/ap/ieee802_11.c | 16 +++++++++++++--- - src/ap/wpa_auth.c | 11 +++++++++++ - src/ap/wpa_auth.h | 3 ++- - src/ap/wpa_auth_ft.c | 10 ++++++++++ - src/ap/wpa_auth_i.h | 1 + - 5 files changed, 37 insertions(+), 4 deletions(-) - -diff --git a/src/ap/ieee802_11.c b/src/ap/ieee802_11.c -index 4e04169..333035f 100644 ---- a/src/ap/ieee802_11.c -+++ b/src/ap/ieee802_11.c -@@ -1841,6 +1841,7 @@ static int add_associated_sta(struct hostapd_data *hapd, - { - struct ieee80211_ht_capabilities ht_cap; - struct ieee80211_vht_capabilities vht_cap; -+ int set = 1; - - /* - * Remove the STA entry to ensure the STA PS state gets cleared and -@@ -1848,9 +1849,18 @@ static int add_associated_sta(struct hostapd_data *hapd, - * FT-over-the-DS, where a station re-associates back to the same AP but - * skips the authentication flow, or if working with a driver that - * does not support full AP client state. -+ * -+ * Skip this if the STA has already completed FT reassociation and the -+ * TK has been configured since the TX/RX PN must not be reset to 0 for -+ * the same key. - */ -- if (!sta->added_unassoc) -+ if (!sta->added_unassoc && -+ (!(sta->flags & WLAN_STA_AUTHORIZED) || -+ !wpa_auth_sta_ft_tk_already_set(sta->wpa_sm))) { - hostapd_drv_sta_remove(hapd, sta->addr); -+ wpa_auth_sm_event(sta->wpa_sm, WPA_DRV_STA_REMOVED); -+ set = 0; -+ } - - #ifdef CONFIG_IEEE80211N - if (sta->flags & WLAN_STA_HT) -@@ -1873,11 +1883,11 @@ static int add_associated_sta(struct hostapd_data *hapd, - sta->flags & WLAN_STA_VHT ? &vht_cap : NULL, - sta->flags | WLAN_STA_ASSOC, sta->qosinfo, - sta->vht_opmode, sta->p2p_ie ? 1 : 0, -- sta->added_unassoc)) { -+ set)) { - hostapd_logger(hapd, sta->addr, - HOSTAPD_MODULE_IEEE80211, HOSTAPD_LEVEL_NOTICE, - "Could not %s STA to kernel driver", -- sta->added_unassoc ? "set" : "add"); -+ set ? "set" : "add"); - - if (sta->added_unassoc) { - hostapd_drv_sta_remove(hapd, sta->addr); -diff --git a/src/ap/wpa_auth.c b/src/ap/wpa_auth.c -index 3587086..707971d 100644 ---- a/src/ap/wpa_auth.c -+++ b/src/ap/wpa_auth.c -@@ -1745,6 +1745,9 @@ int wpa_auth_sm_event(struct wpa_state_machine *sm, enum wpa_event event) - #else /* CONFIG_IEEE80211R */ - break; - #endif /* CONFIG_IEEE80211R */ -+ case WPA_DRV_STA_REMOVED: -+ sm->tk_already_set = FALSE; -+ return 0; - } - - #ifdef CONFIG_IEEE80211R -@@ -3250,6 +3253,14 @@ int wpa_auth_sta_wpa_version(struct wpa_state_machine *sm) - } - - -+int wpa_auth_sta_ft_tk_already_set(struct wpa_state_machine *sm) -+{ -+ if (!sm || !wpa_key_mgmt_ft(sm->wpa_key_mgmt)) -+ return 0; -+ return sm->tk_already_set; -+} -+ -+ - int wpa_auth_sta_clear_pmksa(struct wpa_state_machine *sm, - struct rsn_pmksa_cache_entry *entry) - { -diff --git a/src/ap/wpa_auth.h b/src/ap/wpa_auth.h -index 0de8d97..97461b0 100644 ---- a/src/ap/wpa_auth.h -+++ b/src/ap/wpa_auth.h -@@ -267,7 +267,7 @@ void wpa_receive(struct wpa_authenticator *wpa_auth, - u8 *data, size_t data_len); - enum wpa_event { - WPA_AUTH, WPA_ASSOC, WPA_DISASSOC, WPA_DEAUTH, WPA_REAUTH, -- WPA_REAUTH_EAPOL, WPA_ASSOC_FT -+ WPA_REAUTH_EAPOL, WPA_ASSOC_FT, WPA_DRV_STA_REMOVED - }; - void wpa_remove_ptk(struct wpa_state_machine *sm); - int wpa_auth_sm_event(struct wpa_state_machine *sm, enum wpa_event event); -@@ -280,6 +280,7 @@ int wpa_auth_pairwise_set(struct wpa_state_machine *sm); - int wpa_auth_get_pairwise(struct wpa_state_machine *sm); - int wpa_auth_sta_key_mgmt(struct wpa_state_machine *sm); - int wpa_auth_sta_wpa_version(struct wpa_state_machine *sm); -+int wpa_auth_sta_ft_tk_already_set(struct wpa_state_machine *sm); - int wpa_auth_sta_clear_pmksa(struct wpa_state_machine *sm, - struct rsn_pmksa_cache_entry *entry); - struct rsn_pmksa_cache_entry * -diff --git a/src/ap/wpa_auth_ft.c b/src/ap/wpa_auth_ft.c -index 42242a5..e63b99a 100644 ---- a/src/ap/wpa_auth_ft.c -+++ b/src/ap/wpa_auth_ft.c -@@ -780,6 +780,14 @@ void wpa_ft_install_ptk(struct wpa_state_machine *sm) - return; - } - -+ if (sm->tk_already_set) { -+ /* Must avoid TK reconfiguration to prevent clearing of TX/RX -+ * PN in the driver */ -+ wpa_printf(MSG_DEBUG, -+ "FT: Do not re-install same PTK to the driver"); -+ return; -+ } -+ - /* FIX: add STA entry to kernel/driver here? The set_key will fail - * most likely without this.. At the moment, STA entry is added only - * after association has been completed. This function will be called -@@ -792,6 +800,7 @@ void wpa_ft_install_ptk(struct wpa_state_machine *sm) - - /* FIX: MLME-SetProtection.Request(TA, Tx_Rx) */ - sm->pairwise_set = TRUE; -+ sm->tk_already_set = TRUE; - } - - -@@ -898,6 +907,7 @@ static int wpa_ft_process_auth_req(struct wpa_state_machine *sm, - - sm->pairwise = pairwise; - sm->PTK_valid = TRUE; -+ sm->tk_already_set = FALSE; - wpa_ft_install_ptk(sm); - - buflen = 2 + sizeof(struct rsn_mdie) + 2 + sizeof(struct rsn_ftie) + -diff --git a/src/ap/wpa_auth_i.h b/src/ap/wpa_auth_i.h -index 72b7eb3..7fd8f05 100644 ---- a/src/ap/wpa_auth_i.h -+++ b/src/ap/wpa_auth_i.h -@@ -65,6 +65,7 @@ struct wpa_state_machine { - struct wpa_ptk PTK; - Boolean PTK_valid; - Boolean pairwise_set; -+ Boolean tk_already_set; - int keycount; - Boolean Pair; - struct wpa_key_replay_counter { --- -1.8.3.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0002-Prevent-reinstallation-of-an-already-in-use-group-ke.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0002-Prevent-reinstallation-of-an-already-in-use-group-ke.patch deleted file mode 100644 index 4e57bcaa..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0002-Prevent-reinstallation-of-an-already-in-use-group-ke.patch +++ /dev/null @@ -1,253 +0,0 @@ -From c623cc973de525f7411dffe438e957ba86ef4733 Mon Sep 17 00:00:00 2001 -From: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be> -Date: Wed, 12 Jul 2017 16:03:24 +0200 -Subject: [PATCH 2/7] Prevent reinstallation of an already in-use group key - -Track the current GTK and IGTK that is in use and when receiving a -(possibly retransmitted) Group Message 1 or WNM-Sleep Mode Response, do -not install the given key if it is already in use. This prevents an -attacker from trying to trick the client into resetting or lowering the -sequence counter associated to the group key. - -Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be> - -Upstream-Status: Backport -Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> ---- - src/common/wpa_common.h | 11 +++++ - src/rsn_supp/wpa.c | 116 ++++++++++++++++++++++++++++++------------------ - src/rsn_supp/wpa_i.h | 4 ++ - 3 files changed, 87 insertions(+), 44 deletions(-) - -diff --git a/src/common/wpa_common.h b/src/common/wpa_common.h -index af1d0f0..d200285 100644 ---- a/src/common/wpa_common.h -+++ b/src/common/wpa_common.h -@@ -217,6 +217,17 @@ struct wpa_ptk { - size_t tk_len; - }; - -+struct wpa_gtk { -+ u8 gtk[WPA_GTK_MAX_LEN]; -+ size_t gtk_len; -+}; -+ -+#ifdef CONFIG_IEEE80211W -+struct wpa_igtk { -+ u8 igtk[WPA_IGTK_MAX_LEN]; -+ size_t igtk_len; -+}; -+#endif /* CONFIG_IEEE80211W */ - - /* WPA IE version 1 - * 00-50-f2:1 (OUI:OUI type) -diff --git a/src/rsn_supp/wpa.c b/src/rsn_supp/wpa.c -index 3c47879..95bd7be 100644 ---- a/src/rsn_supp/wpa.c -+++ b/src/rsn_supp/wpa.c -@@ -714,6 +714,15 @@ static int wpa_supplicant_install_gtk(struct wpa_sm *sm, - const u8 *_gtk = gd->gtk; - u8 gtk_buf[32]; - -+ /* Detect possible key reinstallation */ -+ if (sm->gtk.gtk_len == (size_t) gd->gtk_len && -+ os_memcmp(sm->gtk.gtk, gd->gtk, sm->gtk.gtk_len) == 0) { -+ wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, -+ "WPA: Not reinstalling already in-use GTK to the driver (keyidx=%d tx=%d len=%d)", -+ gd->keyidx, gd->tx, gd->gtk_len); -+ return 0; -+ } -+ - wpa_hexdump_key(MSG_DEBUG, "WPA: Group Key", gd->gtk, gd->gtk_len); - wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, - "WPA: Installing GTK to the driver (keyidx=%d tx=%d len=%d)", -@@ -748,6 +757,9 @@ static int wpa_supplicant_install_gtk(struct wpa_sm *sm, - } - os_memset(gtk_buf, 0, sizeof(gtk_buf)); - -+ sm->gtk.gtk_len = gd->gtk_len; -+ os_memcpy(sm->gtk.gtk, gd->gtk, sm->gtk.gtk_len); -+ - return 0; - } - -@@ -854,6 +866,48 @@ static int wpa_supplicant_pairwise_gtk(struct wpa_sm *sm, - } - - -+#ifdef CONFIG_IEEE80211W -+static int wpa_supplicant_install_igtk(struct wpa_sm *sm, -+ const struct wpa_igtk_kde *igtk) -+{ -+ size_t len = wpa_cipher_key_len(sm->mgmt_group_cipher); -+ u16 keyidx = WPA_GET_LE16(igtk->keyid); -+ -+ /* Detect possible key reinstallation */ -+ if (sm->igtk.igtk_len == len && -+ os_memcmp(sm->igtk.igtk, igtk->igtk, sm->igtk.igtk_len) == 0) { -+ wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, -+ "WPA: Not reinstalling already in-use IGTK to the driver (keyidx=%d)", -+ keyidx); -+ return 0; -+ } -+ -+ wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, -+ "WPA: IGTK keyid %d pn %02x%02x%02x%02x%02x%02x", -+ keyidx, MAC2STR(igtk->pn)); -+ wpa_hexdump_key(MSG_DEBUG, "WPA: IGTK", igtk->igtk, len); -+ if (keyidx > 4095) { -+ wpa_msg(sm->ctx->msg_ctx, MSG_WARNING, -+ "WPA: Invalid IGTK KeyID %d", keyidx); -+ return -1; -+ } -+ if (wpa_sm_set_key(sm, wpa_cipher_to_alg(sm->mgmt_group_cipher), -+ broadcast_ether_addr, -+ keyidx, 0, igtk->pn, sizeof(igtk->pn), -+ igtk->igtk, len) < 0) { -+ wpa_msg(sm->ctx->msg_ctx, MSG_WARNING, -+ "WPA: Failed to configure IGTK to the driver"); -+ return -1; -+ } -+ -+ sm->igtk.igtk_len = len; -+ os_memcpy(sm->igtk.igtk, igtk->igtk, sm->igtk.igtk_len); -+ -+ return 0; -+} -+#endif /* CONFIG_IEEE80211W */ -+ -+ - static int ieee80211w_set_keys(struct wpa_sm *sm, - struct wpa_eapol_ie_parse *ie) - { -@@ -864,30 +918,14 @@ static int ieee80211w_set_keys(struct wpa_sm *sm, - if (ie->igtk) { - size_t len; - const struct wpa_igtk_kde *igtk; -- u16 keyidx; -+ - len = wpa_cipher_key_len(sm->mgmt_group_cipher); - if (ie->igtk_len != WPA_IGTK_KDE_PREFIX_LEN + len) - return -1; -+ - igtk = (const struct wpa_igtk_kde *) ie->igtk; -- keyidx = WPA_GET_LE16(igtk->keyid); -- wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, "WPA: IGTK keyid %d " -- "pn %02x%02x%02x%02x%02x%02x", -- keyidx, MAC2STR(igtk->pn)); -- wpa_hexdump_key(MSG_DEBUG, "WPA: IGTK", -- igtk->igtk, len); -- if (keyidx > 4095) { -- wpa_msg(sm->ctx->msg_ctx, MSG_WARNING, -- "WPA: Invalid IGTK KeyID %d", keyidx); -- return -1; -- } -- if (wpa_sm_set_key(sm, wpa_cipher_to_alg(sm->mgmt_group_cipher), -- broadcast_ether_addr, -- keyidx, 0, igtk->pn, sizeof(igtk->pn), -- igtk->igtk, len) < 0) { -- wpa_msg(sm->ctx->msg_ctx, MSG_WARNING, -- "WPA: Failed to configure IGTK to the driver"); -+ if (wpa_supplicant_install_igtk(sm, igtk) < 0) - return -1; -- } - } - - return 0; -@@ -2307,7 +2345,7 @@ void wpa_sm_deinit(struct wpa_sm *sm) - */ - void wpa_sm_notify_assoc(struct wpa_sm *sm, const u8 *bssid) - { -- int clear_ptk = 1; -+ int clear_keys = 1; - - if (sm == NULL) - return; -@@ -2333,11 +2371,11 @@ void wpa_sm_notify_assoc(struct wpa_sm *sm, const u8 *bssid) - /* Prepare for the next transition */ - wpa_ft_prepare_auth_request(sm, NULL); - -- clear_ptk = 0; -+ clear_keys = 0; - } - #endif /* CONFIG_IEEE80211R */ - -- if (clear_ptk) { -+ if (clear_keys) { - /* - * IEEE 802.11, 8.4.10: Delete PTK SA on (re)association if - * this is not part of a Fast BSS Transition. -@@ -2347,6 +2385,10 @@ void wpa_sm_notify_assoc(struct wpa_sm *sm, const u8 *bssid) - os_memset(&sm->ptk, 0, sizeof(sm->ptk)); - sm->tptk_set = 0; - os_memset(&sm->tptk, 0, sizeof(sm->tptk)); -+ os_memset(&sm->gtk, 0, sizeof(sm->gtk)); -+#ifdef CONFIG_IEEE80211W -+ os_memset(&sm->igtk, 0, sizeof(sm->igtk)); -+#endif /* CONFIG_IEEE80211W */ - } - - #ifdef CONFIG_TDLS -@@ -2877,6 +2919,10 @@ void wpa_sm_drop_sa(struct wpa_sm *sm) - os_memset(sm->pmk, 0, sizeof(sm->pmk)); - os_memset(&sm->ptk, 0, sizeof(sm->ptk)); - os_memset(&sm->tptk, 0, sizeof(sm->tptk)); -+ os_memset(&sm->gtk, 0, sizeof(sm->gtk)); -+#ifdef CONFIG_IEEE80211W -+ os_memset(&sm->igtk, 0, sizeof(sm->igtk)); -+#endif /* CONFIG_IEEE80211W */ - #ifdef CONFIG_IEEE80211R - os_memset(sm->xxkey, 0, sizeof(sm->xxkey)); - os_memset(sm->pmk_r0, 0, sizeof(sm->pmk_r0)); -@@ -2949,29 +2995,11 @@ int wpa_wnmsleep_install_key(struct wpa_sm *sm, u8 subelem_id, u8 *buf) - os_memset(&gd, 0, sizeof(gd)); - #ifdef CONFIG_IEEE80211W - } else if (subelem_id == WNM_SLEEP_SUBELEM_IGTK) { -- struct wpa_igtk_kde igd; -- u16 keyidx; -- -- os_memset(&igd, 0, sizeof(igd)); -- keylen = wpa_cipher_key_len(sm->mgmt_group_cipher); -- os_memcpy(igd.keyid, buf + 2, 2); -- os_memcpy(igd.pn, buf + 4, 6); -- -- keyidx = WPA_GET_LE16(igd.keyid); -- os_memcpy(igd.igtk, buf + 10, keylen); -- -- wpa_hexdump_key(MSG_DEBUG, "Install IGTK (WNM SLEEP)", -- igd.igtk, keylen); -- if (wpa_sm_set_key(sm, wpa_cipher_to_alg(sm->mgmt_group_cipher), -- broadcast_ether_addr, -- keyidx, 0, igd.pn, sizeof(igd.pn), -- igd.igtk, keylen) < 0) { -- wpa_printf(MSG_DEBUG, "Failed to install the IGTK in " -- "WNM mode"); -- os_memset(&igd, 0, sizeof(igd)); -+ const struct wpa_igtk_kde *igtk; -+ -+ igtk = (const struct wpa_igtk_kde *) (buf + 2); -+ if (wpa_supplicant_install_igtk(sm, igtk) < 0) - return -1; -- } -- os_memset(&igd, 0, sizeof(igd)); - #endif /* CONFIG_IEEE80211W */ - } else { - wpa_printf(MSG_DEBUG, "Unknown element id"); -diff --git a/src/rsn_supp/wpa_i.h b/src/rsn_supp/wpa_i.h -index f653ba6..afc9e37 100644 ---- a/src/rsn_supp/wpa_i.h -+++ b/src/rsn_supp/wpa_i.h -@@ -31,6 +31,10 @@ struct wpa_sm { - u8 rx_replay_counter[WPA_REPLAY_COUNTER_LEN]; - int rx_replay_counter_set; - u8 request_counter[WPA_REPLAY_COUNTER_LEN]; -+ struct wpa_gtk gtk; -+#ifdef CONFIG_IEEE80211W -+ struct wpa_igtk igtk; -+#endif /* CONFIG_IEEE80211W */ - - struct eapol_sm *eapol; /* EAPOL state machine from upper level code */ - --- -1.8.3.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0003-Extend-protection-of-GTK-IGTK-reinstallation-of-WNM-.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0003-Extend-protection-of-GTK-IGTK-reinstallation-of-WNM-.patch deleted file mode 100644 index e39bbf63..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0003-Extend-protection-of-GTK-IGTK-reinstallation-of-WNM-.patch +++ /dev/null @@ -1,187 +0,0 @@ -From a6caab8060ab60876e233306f5c586451169eba1 Mon Sep 17 00:00:00 2001 -From: Jouni Malinen <j@w1.fi> -Date: Sun, 1 Oct 2017 12:12:24 +0300 -Subject: [PATCH 3/7] Extend protection of GTK/IGTK reinstallation of WNM-Sleep - Mode cases - -This extends the protection to track last configured GTK/IGTK value -separately from EAPOL-Key frames and WNM-Sleep Mode frames to cover a -corner case where these two different mechanisms may get used when the -GTK/IGTK has changed and tracking a single value is not sufficient to -detect a possible key reconfiguration. - -Signed-off-by: Jouni Malinen <j@w1.fi> - -Upstream-Status: Backport -Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> ---- - src/rsn_supp/wpa.c | 53 +++++++++++++++++++++++++++++++++++++--------------- - src/rsn_supp/wpa_i.h | 2 ++ - 2 files changed, 40 insertions(+), 15 deletions(-) - -diff --git a/src/rsn_supp/wpa.c b/src/rsn_supp/wpa.c -index 95bd7be..7a2c68d 100644 ---- a/src/rsn_supp/wpa.c -+++ b/src/rsn_supp/wpa.c -@@ -709,14 +709,17 @@ struct wpa_gtk_data { - - static int wpa_supplicant_install_gtk(struct wpa_sm *sm, - const struct wpa_gtk_data *gd, -- const u8 *key_rsc) -+ const u8 *key_rsc, int wnm_sleep) - { - const u8 *_gtk = gd->gtk; - u8 gtk_buf[32]; - - /* Detect possible key reinstallation */ -- if (sm->gtk.gtk_len == (size_t) gd->gtk_len && -- os_memcmp(sm->gtk.gtk, gd->gtk, sm->gtk.gtk_len) == 0) { -+ if ((sm->gtk.gtk_len == (size_t) gd->gtk_len && -+ os_memcmp(sm->gtk.gtk, gd->gtk, sm->gtk.gtk_len) == 0) || -+ (sm->gtk_wnm_sleep.gtk_len == (size_t) gd->gtk_len && -+ os_memcmp(sm->gtk_wnm_sleep.gtk, gd->gtk, -+ sm->gtk_wnm_sleep.gtk_len) == 0)) { - wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, - "WPA: Not reinstalling already in-use GTK to the driver (keyidx=%d tx=%d len=%d)", - gd->keyidx, gd->tx, gd->gtk_len); -@@ -757,8 +760,14 @@ static int wpa_supplicant_install_gtk(struct wpa_sm *sm, - } - os_memset(gtk_buf, 0, sizeof(gtk_buf)); - -- sm->gtk.gtk_len = gd->gtk_len; -- os_memcpy(sm->gtk.gtk, gd->gtk, sm->gtk.gtk_len); -+ if (wnm_sleep) { -+ sm->gtk_wnm_sleep.gtk_len = gd->gtk_len; -+ os_memcpy(sm->gtk_wnm_sleep.gtk, gd->gtk, -+ sm->gtk_wnm_sleep.gtk_len); -+ } else { -+ sm->gtk.gtk_len = gd->gtk_len; -+ os_memcpy(sm->gtk.gtk, gd->gtk, sm->gtk.gtk_len); -+ } - - return 0; - } -@@ -852,7 +861,7 @@ static int wpa_supplicant_pairwise_gtk(struct wpa_sm *sm, - (wpa_supplicant_check_group_cipher(sm, sm->group_cipher, - gtk_len, gtk_len, - &gd.key_rsc_len, &gd.alg) || -- wpa_supplicant_install_gtk(sm, &gd, key_rsc))) { -+ wpa_supplicant_install_gtk(sm, &gd, key_rsc, 0))) { - wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, - "RSN: Failed to install GTK"); - os_memset(&gd, 0, sizeof(gd)); -@@ -868,14 +877,18 @@ static int wpa_supplicant_pairwise_gtk(struct wpa_sm *sm, - - #ifdef CONFIG_IEEE80211W - static int wpa_supplicant_install_igtk(struct wpa_sm *sm, -- const struct wpa_igtk_kde *igtk) -+ const struct wpa_igtk_kde *igtk, -+ int wnm_sleep) - { - size_t len = wpa_cipher_key_len(sm->mgmt_group_cipher); - u16 keyidx = WPA_GET_LE16(igtk->keyid); - - /* Detect possible key reinstallation */ -- if (sm->igtk.igtk_len == len && -- os_memcmp(sm->igtk.igtk, igtk->igtk, sm->igtk.igtk_len) == 0) { -+ if ((sm->igtk.igtk_len == len && -+ os_memcmp(sm->igtk.igtk, igtk->igtk, sm->igtk.igtk_len) == 0) || -+ (sm->igtk_wnm_sleep.igtk_len == len && -+ os_memcmp(sm->igtk_wnm_sleep.igtk, igtk->igtk, -+ sm->igtk_wnm_sleep.igtk_len) == 0)) { - wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, - "WPA: Not reinstalling already in-use IGTK to the driver (keyidx=%d)", - keyidx); -@@ -900,8 +913,14 @@ static int wpa_supplicant_install_igtk(struct wpa_sm *sm, - return -1; - } - -- sm->igtk.igtk_len = len; -- os_memcpy(sm->igtk.igtk, igtk->igtk, sm->igtk.igtk_len); -+ if (wnm_sleep) { -+ sm->igtk_wnm_sleep.igtk_len = len; -+ os_memcpy(sm->igtk_wnm_sleep.igtk, igtk->igtk, -+ sm->igtk_wnm_sleep.igtk_len); -+ } else { -+ sm->igtk.igtk_len = len; -+ os_memcpy(sm->igtk.igtk, igtk->igtk, sm->igtk.igtk_len); -+ } - - return 0; - } -@@ -924,7 +943,7 @@ static int ieee80211w_set_keys(struct wpa_sm *sm, - return -1; - - igtk = (const struct wpa_igtk_kde *) ie->igtk; -- if (wpa_supplicant_install_igtk(sm, igtk) < 0) -+ if (wpa_supplicant_install_igtk(sm, igtk, 0) < 0) - return -1; - } - -@@ -1574,7 +1593,7 @@ static void wpa_supplicant_process_1_of_2(struct wpa_sm *sm, - if (wpa_supplicant_rsc_relaxation(sm, key->key_rsc)) - key_rsc = null_rsc; - -- if (wpa_supplicant_install_gtk(sm, &gd, key_rsc) || -+ if (wpa_supplicant_install_gtk(sm, &gd, key_rsc, 0) || - wpa_supplicant_send_2_of_2(sm, key, ver, key_info) < 0) - goto failed; - os_memset(&gd, 0, sizeof(gd)); -@@ -2386,8 +2405,10 @@ void wpa_sm_notify_assoc(struct wpa_sm *sm, const u8 *bssid) - sm->tptk_set = 0; - os_memset(&sm->tptk, 0, sizeof(sm->tptk)); - os_memset(&sm->gtk, 0, sizeof(sm->gtk)); -+ os_memset(&sm->gtk_wnm_sleep, 0, sizeof(sm->gtk_wnm_sleep)); - #ifdef CONFIG_IEEE80211W - os_memset(&sm->igtk, 0, sizeof(sm->igtk)); -+ os_memset(&sm->igtk_wnm_sleep, 0, sizeof(sm->igtk_wnm_sleep)); - #endif /* CONFIG_IEEE80211W */ - } - -@@ -2920,8 +2941,10 @@ void wpa_sm_drop_sa(struct wpa_sm *sm) - os_memset(&sm->ptk, 0, sizeof(sm->ptk)); - os_memset(&sm->tptk, 0, sizeof(sm->tptk)); - os_memset(&sm->gtk, 0, sizeof(sm->gtk)); -+ os_memset(&sm->gtk_wnm_sleep, 0, sizeof(sm->gtk_wnm_sleep)); - #ifdef CONFIG_IEEE80211W - os_memset(&sm->igtk, 0, sizeof(sm->igtk)); -+ os_memset(&sm->igtk_wnm_sleep, 0, sizeof(sm->igtk_wnm_sleep)); - #endif /* CONFIG_IEEE80211W */ - #ifdef CONFIG_IEEE80211R - os_memset(sm->xxkey, 0, sizeof(sm->xxkey)); -@@ -2986,7 +3009,7 @@ int wpa_wnmsleep_install_key(struct wpa_sm *sm, u8 subelem_id, u8 *buf) - - wpa_hexdump_key(MSG_DEBUG, "Install GTK (WNM SLEEP)", - gd.gtk, gd.gtk_len); -- if (wpa_supplicant_install_gtk(sm, &gd, key_rsc)) { -+ if (wpa_supplicant_install_gtk(sm, &gd, key_rsc, 1)) { - os_memset(&gd, 0, sizeof(gd)); - wpa_printf(MSG_DEBUG, "Failed to install the GTK in " - "WNM mode"); -@@ -2998,7 +3021,7 @@ int wpa_wnmsleep_install_key(struct wpa_sm *sm, u8 subelem_id, u8 *buf) - const struct wpa_igtk_kde *igtk; - - igtk = (const struct wpa_igtk_kde *) (buf + 2); -- if (wpa_supplicant_install_igtk(sm, igtk) < 0) -+ if (wpa_supplicant_install_igtk(sm, igtk, 1) < 0) - return -1; - #endif /* CONFIG_IEEE80211W */ - } else { -diff --git a/src/rsn_supp/wpa_i.h b/src/rsn_supp/wpa_i.h -index afc9e37..9a54631 100644 ---- a/src/rsn_supp/wpa_i.h -+++ b/src/rsn_supp/wpa_i.h -@@ -32,8 +32,10 @@ struct wpa_sm { - int rx_replay_counter_set; - u8 request_counter[WPA_REPLAY_COUNTER_LEN]; - struct wpa_gtk gtk; -+ struct wpa_gtk gtk_wnm_sleep; - #ifdef CONFIG_IEEE80211W - struct wpa_igtk igtk; -+ struct wpa_igtk igtk_wnm_sleep; - #endif /* CONFIG_IEEE80211W */ - - struct eapol_sm *eapol; /* EAPOL state machine from upper level code */ --- -1.8.3.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0004-Prevent-installation-of-an-all-zero-TK.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0004-Prevent-installation-of-an-all-zero-TK.patch deleted file mode 100644 index 51036251..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0004-Prevent-installation-of-an-all-zero-TK.patch +++ /dev/null @@ -1,82 +0,0 @@ -From abf941647f2dc33b0b59612f525e1b292331cc9f Mon Sep 17 00:00:00 2001 -From: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be> -Date: Fri, 29 Sep 2017 04:22:51 +0200 -Subject: [PATCH 4/7] Prevent installation of an all-zero TK - -Properly track whether a PTK has already been installed to the driver -and the TK part cleared from memory. This prevents an attacker from -trying to trick the client into installing an all-zero TK. - -This fixes the earlier fix in commit -ad00d64e7d8827b3cebd665a0ceb08adabf15e1e ('Fix TK configuration to the -driver in EAPOL-Key 3/4 retry case') which did not take into account -possibility of an extra message 1/4 showing up between retries of -message 3/4. - -Signed-off-by: Mathy Vanhoef <Mathy.Vanhoef@cs.kuleuven.be> - -Upstream-Status: Backport -Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> ---- - src/common/wpa_common.h | 1 + - src/rsn_supp/wpa.c | 5 ++--- - src/rsn_supp/wpa_i.h | 1 - - 3 files changed, 3 insertions(+), 4 deletions(-) - -diff --git a/src/common/wpa_common.h b/src/common/wpa_common.h -index d200285..1021ccb 100644 ---- a/src/common/wpa_common.h -+++ b/src/common/wpa_common.h -@@ -215,6 +215,7 @@ struct wpa_ptk { - size_t kck_len; - size_t kek_len; - size_t tk_len; -+ int installed; /* 1 if key has already been installed to driver */ - }; - - struct wpa_gtk { -diff --git a/src/rsn_supp/wpa.c b/src/rsn_supp/wpa.c -index 7a2c68d..0550a41 100644 ---- a/src/rsn_supp/wpa.c -+++ b/src/rsn_supp/wpa.c -@@ -510,7 +510,6 @@ static void wpa_supplicant_process_1_of_4(struct wpa_sm *sm, - os_memset(buf, 0, sizeof(buf)); - } - sm->tptk_set = 1; -- sm->tk_to_set = 1; - - kde = sm->assoc_wpa_ie; - kde_len = sm->assoc_wpa_ie_len; -@@ -615,7 +614,7 @@ static int wpa_supplicant_install_ptk(struct wpa_sm *sm, - enum wpa_alg alg; - const u8 *key_rsc; - -- if (!sm->tk_to_set) { -+ if (sm->ptk.installed) { - wpa_dbg(sm->ctx->msg_ctx, MSG_DEBUG, - "WPA: Do not re-install same PTK to the driver"); - return 0; -@@ -659,7 +658,7 @@ static int wpa_supplicant_install_ptk(struct wpa_sm *sm, - - /* TK is not needed anymore in supplicant */ - os_memset(sm->ptk.tk, 0, WPA_TK_MAX_LEN); -- sm->tk_to_set = 0; -+ sm->ptk.installed = 1; - - if (sm->wpa_ptk_rekey) { - eloop_cancel_timeout(wpa_sm_rekey_ptk, sm, NULL); -diff --git a/src/rsn_supp/wpa_i.h b/src/rsn_supp/wpa_i.h -index 9a54631..41f371f 100644 ---- a/src/rsn_supp/wpa_i.h -+++ b/src/rsn_supp/wpa_i.h -@@ -24,7 +24,6 @@ struct wpa_sm { - struct wpa_ptk ptk, tptk; - int ptk_set, tptk_set; - unsigned int msg_3_of_4_ok:1; -- unsigned int tk_to_set:1; - u8 snonce[WPA_NONCE_LEN]; - u8 anonce[WPA_NONCE_LEN]; /* ANonce from the last 1/4 msg */ - int renew_snonce; --- -1.8.3.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0005-Fix-PTK-rekeying-to-generate-a-new-ANonce.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0005-Fix-PTK-rekeying-to-generate-a-new-ANonce.patch deleted file mode 100644 index b0e1df31..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0005-Fix-PTK-rekeying-to-generate-a-new-ANonce.patch +++ /dev/null @@ -1,67 +0,0 @@ -From 804b9d72808cddd822e7dcec4d60f40c1aceda82 Mon Sep 17 00:00:00 2001 -From: Jouni Malinen <j@w1.fi> -Date: Sun, 1 Oct 2017 12:32:57 +0300 -Subject: [PATCH 5/7] Fix PTK rekeying to generate a new ANonce - -The Authenticator state machine path for PTK rekeying ended up bypassing -the AUTHENTICATION2 state where a new ANonce is generated when going -directly to the PTKSTART state since there is no need to try to -determine the PMK again in such a case. This is far from ideal since the -new PTK would depend on a new nonce only from the supplicant. - -Fix this by generating a new ANonce when moving to the PTKSTART state -for the purpose of starting new 4-way handshake to rekey PTK. - -Signed-off-by: Jouni Malinen <j@w1.fi> - -Upstream-Status: Backport -Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> ---- - src/ap/wpa_auth.c | 24 +++++++++++++++++++++--- - 1 file changed, 21 insertions(+), 3 deletions(-) - -diff --git a/src/ap/wpa_auth.c b/src/ap/wpa_auth.c -index 707971d..bf10cc1 100644 ---- a/src/ap/wpa_auth.c -+++ b/src/ap/wpa_auth.c -@@ -1901,6 +1901,21 @@ SM_STATE(WPA_PTK, AUTHENTICATION2) - } - - -+static int wpa_auth_sm_ptk_update(struct wpa_state_machine *sm) -+{ -+ if (random_get_bytes(sm->ANonce, WPA_NONCE_LEN)) { -+ wpa_printf(MSG_ERROR, -+ "WPA: Failed to get random data for ANonce"); -+ sm->Disconnect = TRUE; -+ return -1; -+ } -+ wpa_hexdump(MSG_DEBUG, "WPA: Assign new ANonce", sm->ANonce, -+ WPA_NONCE_LEN); -+ sm->TimeoutCtr = 0; -+ return 0; -+} -+ -+ - SM_STATE(WPA_PTK, INITPMK) - { - u8 msk[2 * PMK_LEN]; -@@ -2458,9 +2473,12 @@ SM_STEP(WPA_PTK) - SM_ENTER(WPA_PTK, AUTHENTICATION); - else if (sm->ReAuthenticationRequest) - SM_ENTER(WPA_PTK, AUTHENTICATION2); -- else if (sm->PTKRequest) -- SM_ENTER(WPA_PTK, PTKSTART); -- else switch (sm->wpa_ptk_state) { -+ else if (sm->PTKRequest) { -+ if (wpa_auth_sm_ptk_update(sm) < 0) -+ SM_ENTER(WPA_PTK, DISCONNECTED); -+ else -+ SM_ENTER(WPA_PTK, PTKSTART); -+ } else switch (sm->wpa_ptk_state) { - case WPA_PTK_INITIALIZE: - break; - case WPA_PTK_DISCONNECT: --- -1.8.3.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0006-TDLS-Reject-TPK-TK-reconfiguration.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0006-TDLS-Reject-TPK-TK-reconfiguration.patch deleted file mode 100644 index 72c7d51e..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0006-TDLS-Reject-TPK-TK-reconfiguration.patch +++ /dev/null @@ -1,135 +0,0 @@ -From 7fd26db2d8147ed662db192c41d7bc15752a601d Mon Sep 17 00:00:00 2001 -From: Jouni Malinen <j@w1.fi> -Date: Fri, 22 Sep 2017 11:03:15 +0300 -Subject: [PATCH 6/7] TDLS: Reject TPK-TK reconfiguration - -Do not try to reconfigure the same TPK-TK to the driver after it has -been successfully configured. This is an explicit check to avoid issues -related to resetting the TX/RX packet number. There was already a check -for this for TPK M2 (retries of that message are ignored completely), so -that behavior does not get modified. - -For TPK M3, the TPK-TK could have been reconfigured, but that was -followed by immediate teardown of the link due to an issue in updating -the STA entry. Furthermore, for TDLS with any real security (i.e., -ignoring open/WEP), the TPK message exchange is protected on the AP path -and simple replay attacks are not feasible. - -As an additional corner case, make sure the local nonce gets updated if -the peer uses a very unlikely "random nonce" of all zeros. - -Signed-off-by: Jouni Malinen <j@w1.fi> - -Upstream-Status: Backport -Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> ---- - src/rsn_supp/tdls.c | 38 ++++++++++++++++++++++++++++++++++++-- - 1 file changed, 36 insertions(+), 2 deletions(-) - -diff --git a/src/rsn_supp/tdls.c b/src/rsn_supp/tdls.c -index e424168..9eb9738 100644 ---- a/src/rsn_supp/tdls.c -+++ b/src/rsn_supp/tdls.c -@@ -112,6 +112,7 @@ struct wpa_tdls_peer { - u8 tk[16]; /* TPK-TK; assuming only CCMP will be used */ - } tpk; - int tpk_set; -+ int tk_set; /* TPK-TK configured to the driver */ - int tpk_success; - int tpk_in_progress; - -@@ -192,6 +193,20 @@ static int wpa_tdls_set_key(struct wpa_sm *sm, struct wpa_tdls_peer *peer) - u8 rsc[6]; - enum wpa_alg alg; - -+ if (peer->tk_set) { -+ /* -+ * This same TPK-TK has already been configured to the driver -+ * and this new configuration attempt (likely due to an -+ * unexpected retransmitted frame) would result in clearing -+ * the TX/RX sequence number which can break security, so must -+ * not allow that to happen. -+ */ -+ wpa_printf(MSG_INFO, "TDLS: TPK-TK for the peer " MACSTR -+ " has already been configured to the driver - do not reconfigure", -+ MAC2STR(peer->addr)); -+ return -1; -+ } -+ - os_memset(rsc, 0, 6); - - switch (peer->cipher) { -@@ -209,12 +224,15 @@ static int wpa_tdls_set_key(struct wpa_sm *sm, struct wpa_tdls_peer *peer) - return -1; - } - -+ wpa_printf(MSG_DEBUG, "TDLS: Configure pairwise key for peer " MACSTR, -+ MAC2STR(peer->addr)); - if (wpa_sm_set_key(sm, alg, peer->addr, -1, 1, - rsc, sizeof(rsc), peer->tpk.tk, key_len) < 0) { - wpa_printf(MSG_WARNING, "TDLS: Failed to set TPK to the " - "driver"); - return -1; - } -+ peer->tk_set = 1; - return 0; - } - -@@ -696,7 +714,7 @@ static void wpa_tdls_peer_clear(struct wpa_sm *sm, struct wpa_tdls_peer *peer) - peer->cipher = 0; - peer->qos_info = 0; - peer->wmm_capable = 0; -- peer->tpk_set = peer->tpk_success = 0; -+ peer->tk_set = peer->tpk_set = peer->tpk_success = 0; - peer->chan_switch_enabled = 0; - os_memset(&peer->tpk, 0, sizeof(peer->tpk)); - os_memset(peer->inonce, 0, WPA_NONCE_LEN); -@@ -1159,6 +1177,7 @@ skip_rsnie: - wpa_tdls_peer_free(sm, peer); - return -1; - } -+ peer->tk_set = 0; /* A new nonce results in a new TK */ - wpa_hexdump(MSG_DEBUG, "TDLS: Initiator Nonce for TPK handshake", - peer->inonce, WPA_NONCE_LEN); - os_memcpy(ftie->Snonce, peer->inonce, WPA_NONCE_LEN); -@@ -1751,6 +1770,19 @@ static int wpa_tdls_addset_peer(struct wpa_sm *sm, struct wpa_tdls_peer *peer, - } - - -+static int tdls_nonce_set(const u8 *nonce) -+{ -+ int i; -+ -+ for (i = 0; i < WPA_NONCE_LEN; i++) { -+ if (nonce[i]) -+ return 1; -+ } -+ -+ return 0; -+} -+ -+ - static int wpa_tdls_process_tpk_m1(struct wpa_sm *sm, const u8 *src_addr, - const u8 *buf, size_t len) - { -@@ -2004,7 +2036,8 @@ skip_rsn: - peer->rsnie_i_len = kde.rsn_ie_len; - peer->cipher = cipher; - -- if (os_memcmp(peer->inonce, ftie->Snonce, WPA_NONCE_LEN) != 0) { -+ if (os_memcmp(peer->inonce, ftie->Snonce, WPA_NONCE_LEN) != 0 || -+ !tdls_nonce_set(peer->inonce)) { - /* - * There is no point in updating the RNonce for every obtained - * TPK M1 frame (e.g., retransmission due to timeout) with the -@@ -2020,6 +2053,7 @@ skip_rsn: - "TDLS: Failed to get random data for responder nonce"); - goto error; - } -+ peer->tk_set = 0; /* A new nonce results in a new TK */ - } - - #if 0 --- -1.8.3.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0007-FT-Do-not-allow-multiple-Reassociation-Response-fram.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0007-FT-Do-not-allow-multiple-Reassociation-Response-fram.patch deleted file mode 100644 index d0978c79..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/0007-FT-Do-not-allow-multiple-Reassociation-Response-fram.patch +++ /dev/null @@ -1,85 +0,0 @@ -From a42eb67c42f845faf266b0633d52e17f2a82f511 Mon Sep 17 00:00:00 2001 -From: Jouni Malinen <j@w1.fi> -Date: Fri, 22 Sep 2017 12:06:37 +0300 -Subject: [PATCH 7/7] FT: Do not allow multiple Reassociation Response frames - -The driver is expected to not report a second association event without -the station having explicitly request a new association. As such, this -case should not be reachable. However, since reconfiguring the same -pairwise or group keys to the driver could result in nonce reuse issues, -be extra careful here and do an additional state check to avoid this -even if the local driver ends up somehow accepting an unexpected -Reassociation Response frame. - -Signed-off-by: Jouni Malinen <j@w1.fi> - -Upstream-Status: Backport -Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> ---- - src/rsn_supp/wpa.c | 3 +++ - src/rsn_supp/wpa_ft.c | 8 ++++++++ - src/rsn_supp/wpa_i.h | 1 + - 3 files changed, 12 insertions(+) - -diff --git a/src/rsn_supp/wpa.c b/src/rsn_supp/wpa.c -index 0550a41..2a53c6f 100644 ---- a/src/rsn_supp/wpa.c -+++ b/src/rsn_supp/wpa.c -@@ -2440,6 +2440,9 @@ void wpa_sm_notify_disassoc(struct wpa_sm *sm) - #ifdef CONFIG_TDLS - wpa_tdls_disassoc(sm); - #endif /* CONFIG_TDLS */ -+#ifdef CONFIG_IEEE80211R -+ sm->ft_reassoc_completed = 0; -+#endif /* CONFIG_IEEE80211R */ - - /* Keys are not needed in the WPA state machine anymore */ - wpa_sm_drop_sa(sm); -diff --git a/src/rsn_supp/wpa_ft.c b/src/rsn_supp/wpa_ft.c -index 205793e..d45bb45 100644 ---- a/src/rsn_supp/wpa_ft.c -+++ b/src/rsn_supp/wpa_ft.c -@@ -153,6 +153,7 @@ static u8 * wpa_ft_gen_req_ies(struct wpa_sm *sm, size_t *len, - u16 capab; - - sm->ft_completed = 0; -+ sm->ft_reassoc_completed = 0; - - buf_len = 2 + sizeof(struct rsn_mdie) + 2 + sizeof(struct rsn_ftie) + - 2 + sm->r0kh_id_len + ric_ies_len + 100; -@@ -681,6 +682,11 @@ int wpa_ft_validate_reassoc_resp(struct wpa_sm *sm, const u8 *ies, - return -1; - } - -+ if (sm->ft_reassoc_completed) { -+ wpa_printf(MSG_DEBUG, "FT: Reassociation has already been completed for this FT protocol instance - ignore unexpected retransmission"); -+ return 0; -+ } -+ - if (wpa_ft_parse_ies(ies, ies_len, &parse) < 0) { - wpa_printf(MSG_DEBUG, "FT: Failed to parse IEs"); - return -1; -@@ -781,6 +787,8 @@ int wpa_ft_validate_reassoc_resp(struct wpa_sm *sm, const u8 *ies, - return -1; - } - -+ sm->ft_reassoc_completed = 1; -+ - if (wpa_ft_process_gtk_subelem(sm, parse.gtk, parse.gtk_len) < 0) - return -1; - -diff --git a/src/rsn_supp/wpa_i.h b/src/rsn_supp/wpa_i.h -index 41f371f..56f88dc 100644 ---- a/src/rsn_supp/wpa_i.h -+++ b/src/rsn_supp/wpa_i.h -@@ -128,6 +128,7 @@ struct wpa_sm { - size_t r0kh_id_len; - u8 r1kh_id[FT_R1KH_ID_LEN]; - int ft_completed; -+ int ft_reassoc_completed; - int over_the_ds_in_progress; - u8 target_ap[ETH_ALEN]; /* over-the-DS target AP */ - int set_ptk_after_assoc; --- -1.8.3.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/CVE-2019-16275.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/CVE-2019-16275.patch new file mode 100644 index 00000000..9cefd4f2 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/CVE-2019-16275.patch @@ -0,0 +1,79 @@ +From d86d66dc073bc21d3b12faf4112062ae00c1773f Mon Sep 17 00:00:00 2001 +From: Jouni Malinen <j@w1.fi> +Date: Thu, 29 Aug 2019 11:52:04 +0300 +Subject: AP: Silently ignore management frame from unexpected source +address + +Do not process any received Management frames with unexpected/invalid SA +so that we do not add any state for unexpected STA addresses or end up +sending out frames to unexpected destination. This prevents unexpected +sequences where an unprotected frame might end up causing the AP to send +out a response to another device and that other device processing the +unexpected response. + +In particular, this prevents some potential denial of service cases +where the unexpected response frame from the AP might result in a +connected station dropping its association. + +Upstream-Status: Accepted +CVE: CVE-2019-16275 + +Reference to upstream patch: +https://w1.fi/cgit/hostap/commit/?id=d86d66dc073bc21d3b12faf4112062ae00c1773f + +Signed-off-by: Jouni Malinen <j@w1.fi> +--- + src/ap/drv_callbacks.c | 13 +++++++++++++ + src/ap/ieee802_11.c | 12 ++++++++++++ + 2 files changed, 25 insertions(+) + +diff --git a/src/ap/drv_callbacks.c b/src/ap/drv_callbacks.c +index 3158768..34ca379 100644 +--- a/src/ap/drv_callbacks.c ++++ b/src/ap/drv_callbacks.c +@@ -131,6 +131,19 @@ int hostapd_notif_assoc(struct hostapd_data *hapd, const u8 *addr, + "hostapd_notif_assoc: Skip event with no address"); + return -1; + } ++ ++ if (is_multicast_ether_addr(addr) || ++ is_zero_ether_addr(addr) || ++ os_memcmp(addr, hapd->own_addr, ETH_ALEN) == 0) { ++ /* Do not process any frames with unexpected/invalid SA so that ++ * we do not add any state for unexpected STA addresses or end ++ * up sending out frames to unexpected destination. */ ++ wpa_printf(MSG_DEBUG, "%s: Invalid SA=" MACSTR ++ " in received indication - ignore this indication silently", ++ __func__, MAC2STR(addr)); ++ return 0; ++ } ++ + random_add_randomness(addr, ETH_ALEN); + + hostapd_logger(hapd, addr, HOSTAPD_MODULE_IEEE80211, +diff --git a/src/ap/ieee802_11.c b/src/ap/ieee802_11.c +index c85a28d..2816812 100644 +--- a/src/ap/ieee802_11.c ++++ b/src/ap/ieee802_11.c +@@ -4626,6 +4626,18 @@ int ieee802_11_mgmt(struct hostapd_data *hapd, const u8 *buf, size_t len, + fc = le_to_host16(mgmt->frame_control); + stype = WLAN_FC_GET_STYPE(fc); + ++ if (is_multicast_ether_addr(mgmt->sa) || ++ is_zero_ether_addr(mgmt->sa) || ++ os_memcmp(mgmt->sa, hapd->own_addr, ETH_ALEN) == 0) { ++ /* Do not process any frames with unexpected/invalid SA so that ++ * we do not add any state for unexpected STA addresses or end ++ * up sending out frames to unexpected destination. */ ++ wpa_printf(MSG_DEBUG, "MGMT: Invalid SA=" MACSTR ++ " in received frame - ignore this frame silently", ++ MAC2STR(mgmt->sa)); ++ return 0; ++ } ++ + if (stype == WLAN_FC_STYPE_BEACON) { + handle_beacon(hapd, mgmt, len, fi); + return 1; +-- +2.17.1 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/defconfig b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/defconfig index 27896401..a62bec40 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/defconfig +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/defconfig @@ -139,6 +139,9 @@ CONFIG_DRIVER_RADIUS_ACL=y # IEEE 802.11n (High Throughput) support CONFIG_IEEE80211N=y +# IEEE 802.11ac (Very High Throughput) support +CONFIG_IEEE80211AC=y + # Remove debugging code that is printing out debug messages to stdout. # This can be used to reduce the size of the hostapd considerably if debugging # code is not needed. diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/hostapd-CVE-2018-14526.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/hostapd-CVE-2018-14526.patch deleted file mode 100644 index 522fc394..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd/hostapd-CVE-2018-14526.patch +++ /dev/null @@ -1,44 +0,0 @@ -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/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.6.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.9.bb index 42aae427..68dc1237 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.6.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/hostapd/hostapd_2.9.bb @@ -2,7 +2,7 @@ SUMMARY = "User space daemon for extended IEEE 802.11 management" HOMEPAGE = "http://w1.fi/hostapd/" SECTION = "kernel/userland" LICENSE = "BSD-3-Clause" -LIC_FILES_CHKSUM = "file://hostapd/README;md5=8aa4e8c78b59b12016c4cb2d0a8db350" +LIC_FILES_CHKSUM = "file://hostapd/README;md5=1ec986bec88070e2a59c68c95d763f89" DEPENDS = "libnl openssl" @@ -11,23 +11,16 @@ SRC_URI = " \ file://defconfig \ file://init \ file://hostapd.service \ - file://0001-hostapd-Avoid-key-reinstallation-in-FT-handshake.patch \ - file://0002-Prevent-reinstallation-of-an-already-in-use-group-ke.patch \ - file://0003-Extend-protection-of-GTK-IGTK-reinstallation-of-WNM-.patch \ - file://0004-Prevent-installation-of-an-all-zero-TK.patch \ - 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 \ + file://CVE-2019-16275.patch \ " -SRC_URI[md5sum] = "eaa56dce9bd8f1d195eb62596eab34c7" -SRC_URI[sha256sum] = "01526b90c1d23bec4b0f052039cc4456c2fd19347b4d830d1d58a0a6aea7117d" +SRC_URI[md5sum] = "f188fc53a495fe7af3b6d77d3c31dee8" +SRC_URI[sha256sum] = "881d7d6a90b2428479288d64233151448f8990ab4958e0ecaca7eeb3c9db2bd7" S = "${WORKDIR}/hostapd-${PV}" B = "${WORKDIR}/hostapd-${PV}/hostapd" -inherit update-rc.d systemd pkgconfig distro_features_check +inherit update-rc.d systemd pkgconfig features_check CONFLICT_DISTRO_FEATURES = "openssl-no-weak-ciphers" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/ifplugd/ifplugd/Fix-build-with-musl.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/ifplugd/ifplugd/Fix-build-with-musl.patch new file mode 100644 index 00000000..35665bd3 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/ifplugd/ifplugd/Fix-build-with-musl.patch @@ -0,0 +1,29 @@ +From 3f2fc79385398f213a9bd3c99616d749d699f2bb Mon Sep 17 00:00:00 2001 +From: Fabio Berton <fabio.berton@ossystems.com.br> +Date: Thu, 14 Mar 2019 19:26:14 -0300 +Subject: [PATCH] Fix build with musl +Organization: O.S. Systems Software LTDA. + +Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br> +--- + src/ethtool-local.h | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +--- a/src/ethtool-local.h ++++ b/src/ethtool-local.h +@@ -20,11 +20,11 @@ + * along with ifplugd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ +- ++#include <stdint.h> + typedef unsigned long long u64; +-typedef __uint32_t u32; +-typedef __uint16_t u16; +-typedef __uint8_t u8; ++typedef uint32_t u32; ++typedef uint16_t u16; ++typedef uint8_t u8; + + #include "ethtool-kernel.h" + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/ifplugd/ifplugd_0.28.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/ifplugd/ifplugd_0.28.bb new file mode 100644 index 00000000..0b5c5a6c --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/ifplugd/ifplugd_0.28.bb @@ -0,0 +1,25 @@ +DESCRIPTION = "ifplugd is a Linux daemon which will automatically configure your ethernet device \ +when a cable is plugged in and automatically unconfigure it if the cable is pulled." +HOMEPAGE = "http://0pointer.de/lennart/projects/ifplugd/" +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://LICENSE;md5=94d55d512a9ba36caa9b7df079bae19f" + +DEPENDS = "libdaemon" + +SRC_URI = "http://0pointer.de/lennart/projects/ifplugd/ifplugd-${PV}.tar.gz" + +SRC_URI_append_libc-musl = " file://Fix-build-with-musl.patch" + +SRC_URI[md5sum] = "df6f4bab52f46ffd6eb1f5912d4ccee3" +SRC_URI[sha256sum] = "474754ac4ab32d738cbf2a4a3e87ee0a2c71b9048a38bdcd7df1e4f9fd6541f0" + +inherit autotools update-rc.d pkgconfig + +EXTRA_OECONF = "--disable-lynx --with-initdir=${sysconfdir}/init.d" + +INITSCRIPT_NAME = "ifplugd" +INITSCRIPT_PARAMS = "defaults" + +CONFFILES_${PN} = "${sysconfdir}/ifplugd/ifplugd.conf" + +RDEPENDS_${PN} += "bash" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/irssi/irssi_1.0.4.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/irssi/irssi_1.2.2.bb index 10b04bb5..1c5a912f 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/irssi/irssi_1.0.4.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/irssi/irssi_1.2.2.bb @@ -6,8 +6,10 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=55fdc1113306167d6ea2561404ce02f8" DEPENDS = "glib-2.0 ncurses openssl" SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/${PV}/${BP}.tar.xz" -SRC_URI[md5sum] = "46d4ac2a7ab472e5dc800e5d7bd9a879" -SRC_URI[sha256sum] = "b85c07dbafe178213eccdc69f5f8f0ac024dea01c67244668f91ec1c06b986ca" +SRC_URI[md5sum] = "8547f89e014e23e1bbbb665bcf7e2f70" +SRC_URI[sha256sum] = "6727060c918568ba2ff4295ad736128dba0b995d7b20491bca11f593bd857578" + +UPSTREAM_CHECK_URI = "https://github.com/${BPN}/${BPN}/releases" inherit autotools pkgconfig @@ -16,3 +18,5 @@ EXTRA_OECONF += "--with-textui \ --with-bot \ --with-perl=no \ --enable-true-color" + +FILES_${PN}-staticdev += "${libdir}/${BPN}/modules/*.a" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/iwd/iwd_1.6.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/iwd/iwd_1.6.bb new file mode 100644 index 00000000..10ac03ef --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/iwd/iwd_1.6.bb @@ -0,0 +1,54 @@ +SUMMARY = "Wireless daemon for Linux" +HOMEPAGE = "https://iwd.wiki.kernel.org/" +LICENSE = "LGPL-2.1" +LIC_FILES_CHKSUM = "file://COPYING;md5=fb504b67c50331fc78734fed90fb0e09" + +DEPENDS = "ell" + +SRC_URI = "git://git.kernel.org/pub/scm/network/wireless/iwd.git" +SRCREV = "ad97f4f945b828425ff288e905523e11b330d41d" +S = "${WORKDIR}/git" + +inherit autotools manpages pkgconfig python3native systemd + +PACKAGECONFIG ??= " \ + client \ + monitor \ + ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \ +" +PACKAGECONFIG[client] = "--enable-client,--disable-client,readline" +PACKAGECONFIG[monitor] = "--enable-monitor,--disable-monitor" +PACKAGECONFIG[manpages] = "--enable-manual-pages,--disable-manual-pages,python3-docutils-native" +PACKAGECONFIG[wired] = "--enable-wired,--disable-wired" +PACKAGECONFIG[ofono] = "--enable-ofono,--disable-ofono" +PACKAGECONFIG[systemd] = "--with-systemd-unitdir=${systemd_system_unitdir},--disable-systemd-service,systemd" + +EXTRA_OECONF = "--enable-external-ell" + +SYSTEMD_SERVICE_${PN} = " \ + iwd.service \ + ${@bb.utils.contains('PACKAGECONFIG', 'wired', 'ead.service', '', d)} \ +" + +do_configure_prepend() { + install -d ${S}/build-aux +} + +do_install_append() { + # If client and monitor are disabled, bindir is empty, causing a QA error + rmdir --ignore-fail-on-non-empty ${D}/${bindir} +} + +FILES_${PN} += " \ + ${datadir}/dbus-1 \ + ${nonarch_libdir}/modules-load.d \ + ${systemd_unitdir}/network \ +" + +RDEPENDS_${PN} = "dbus" + +RRECOMMENDS_${PN} = "\ + kernel-module-pkcs7-message \ + kernel-module-pkcs8-key-parser \ + kernel-module-x509-key-parser \ +" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.1.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.17.1.bb index 11748cbd..6164c824 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.16.1.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5_1.17.1.bb @@ -14,7 +14,7 @@ DESCRIPTION = "Kerberos is a system for authenticating users and services on a n HOMEPAGE = "http://web.mit.edu/Kerberos/" SECTION = "console/network" LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://${S}/../NOTICE;md5=7f95bc3d8d0351aa481d56d5e9de20c3" +LIC_FILES_CHKSUM = "file://${S}/../NOTICE;md5=aff541e7261f1926ac6a2a9a7bbab839" DEPENDS = "bison-native ncurses util-linux e2fsprogs e2fsprogs-native openssl" inherit autotools-brokensep binconfig perlnative systemd update-rc.d @@ -31,19 +31,21 @@ SRC_URI = "http://web.mit.edu/kerberos/dist/${BPN}/${SHRT_VER}/${BP}.tar.gz \ file://krb5-kdc.service \ file://krb5-admin-server.service \ " -SRC_URI[md5sum] = "848e9b80d6aaaa798e3f3df24b83c407" -SRC_URI[sha256sum] = "214ffe394e3ad0c730564074ec44f1da119159d94281bbec541dc29168d21117" +SRC_URI[md5sum] = "417d654c72526ac51466e7fe84608878" +SRC_URI[sha256sum] = "3706d7ec2eaa773e0e32d3a87bf742ebaecae7d064e190443a3acddfd8afb181" CVE_PRODUCT = "kerberos" +CVE_VERSION = "5-${PV}" S = "${WORKDIR}/${BP}/src" -PACKAGECONFIG ??= "" +PACKAGECONFIG ??= "pkinit" 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" +PACKAGECONFIG[pkinit] = "--enable-pkinit, --disable-pkinit" EXTRA_OECONF += " --without-tcl --with-system-et --disable-rpath" CACHED_CONFIGUREVARS += "krb5_cv_attr_constructor_destructor=yes ac_cv_func_regcomp=yes \ @@ -103,6 +105,7 @@ PACKAGES =+ "${PN}-admin-server \ ${PN}-kpropd \ ${PN}-otp \ ${PN}-pkinit \ + ${PN}-spake \ ${PN}-user \ libgssapi-krb5 \ libgssrpc \ @@ -149,6 +152,7 @@ FILES_${PN}-kdc-ldap = "${libdir}/krb5/libkdb_ldap${SOLIBS} \ 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}-spake = "${libdir}/krb5/plugins/preauth/spake.so" FILES_${PN}-user = "${bindir}/k*" FILES_libgssapi-krb5 = "${libdir}/libgssapi_krb5${SOLIBS}" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.24.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.33.bb index a5838d36..760c2dbc 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.24.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libev/libev_4.33.bb @@ -5,9 +5,8 @@ LICENSE = "BSD-2-Clause | GPL-2.0+" LIC_FILES_CHKSUM = "file://LICENSE;md5=d6ad416afd040c90698edcdf1cbee347" SRC_URI = "http://dist.schmorp.de/libev/Attic/${BP}.tar.gz" - -SRC_URI[md5sum] = "94459a5a22db041dec6f98424d6efe54" -SRC_URI[sha256sum] = "973593d3479abdf657674a55afe5f78624b0e440614e2b8cb3a07f16d4d7f821" +SRC_URI[md5sum] = "a3433f23583167081bf4acdd5b01b34f" +SRC_URI[sha256sum] = "507eb7b8d1015fbec5b935f34ebed15bf346bed04a11ab82b8eee848c4205aea" inherit autotools @@ -18,3 +17,5 @@ do_install_append() { # still basic so drop it for now. rm ${D}${includedir}/event.h } + +BBCLASSEXTEND = "native" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim/clang.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim/clang.patch deleted file mode 100644 index 92e657c0..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim/clang.patch +++ /dev/null @@ -1,73 +0,0 @@ -Check for clang compiler since we need to disable -unused-function warning for clang, at same time -pass werror when checking for compiler options if -werror is enabled so spurious options do not get -enabled. Only the ones that are supported by given -compiler are accepted. - -Signed-off-by: Khem Raj <raj.khem@gmail.com> -Upstream-Status: Pending - -Index: libmbim-1.14.0/m4/compiler-warnings.m4 -=================================================================== ---- libmbim-1.14.0.orig/m4/compiler-warnings.m4 -+++ libmbim-1.14.0/m4/compiler-warnings.m4 -@@ -2,10 +2,30 @@ AC_DEFUN([LIBMBIM_COMPILER_WARNINGS], - [AC_ARG_ENABLE(more-warnings, - AS_HELP_STRING([--enable-more-warnings], [Possible values: no/yes/error]), - set_more_warnings="$enableval",set_more_warnings=error) -+ -+# Clang throws a lot of warnings when it does not understand a flag. Disable -+# this warning for now so other warnings are visible. -+AC_MSG_CHECKING([if compiling with clang]) -+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [[ -+#ifndef __clang__ -+ not clang -+#endif -+ ]])], -+ [CLANG=yes], -+ [CLANG=no] -+) -+AC_MSG_RESULT([$CLANG]) -+AS_IF([test "x$CLANG" = "xyes"], [CLANG_FLAGS=-Wno-error=unused-function]) -+CFLAGS="$CFLAGS $CLANG_FLAGS" -+LDFLAGS="$LDFLAGS $CLANG_FLAGS" -+ - AC_MSG_CHECKING(for more warnings) - if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then - AC_MSG_RESULT(yes) - CFLAGS="-Wall -std=gnu89 $CFLAGS" -+ if test "x$set_more_warnings" = xerror; then -+ WERROR="-Werror" -+ fi - - for option in -Wmissing-declarations -Wmissing-prototypes \ - -Wdeclaration-after-statement -Wstrict-prototypes \ -@@ -17,22 +37,23 @@ if test "$GCC" = "yes" -a "$set_more_war - -Wmissing-include-dirs -Waggregate-return \ - -Wformat-security; do - SAVE_CFLAGS="$CFLAGS" -- CFLAGS="$CFLAGS $option" -+ CFLAGS="$CFLAGS $option $WERROR" - AC_MSG_CHECKING([whether gcc understands $option]) - AC_TRY_COMPILE([], [], - has_option=yes, - has_option=no,) - if test $has_option = no; then - CFLAGS="$SAVE_CFLAGS" -+ else -+ CFLAGS="$SAVE_CFLAGS $option" - fi - AC_MSG_RESULT($has_option) - unset has_option - unset SAVE_CFLAGS - done -+ CFLAGS="$CFLAGS $WERROR" - unset option -- if test "x$set_more_warnings" = xerror; then -- CFLAGS="$CFLAGS -Werror" -- fi -+ unset WERROR - else - AC_MSG_RESULT(no) - fi diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.16.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.22.0.bb index 5260c0f1..61e314f1 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.16.0.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libmbim/libmbim_1.22.0.bb @@ -11,8 +11,7 @@ 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" +SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BPN}-${PV}.tar.xz" + +SRC_URI[md5sum] = "87060e8957013177e4140edc6f64f5bd" +SRC_URI[sha256sum] = "5c0778eb1cd12c3604523134e55183f5147b0cae71150e875b583768f7aa1f38" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libmtp/libmtp_1.1.16.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libmtp/libmtp_1.1.17.bb index 596e315b..54decbcc 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libmtp/libmtp_1.1.16.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libmtp/libmtp_1.1.17.bb @@ -21,8 +21,8 @@ DEPENDS_append_class-target = " ${BPN}-native" SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz" SRC_URI_append_class-target = " file://0001-Use-native-mtp-hotplug.patch" -SRC_URI[md5sum] = "7796179af46e90938dde1d0c4d1d1d4c" -SRC_URI[sha256sum] = "5b68f9dd1ed38de558de687f40e255a39e4d5e32ef3de601f0ac19dd5682bba0" +SRC_URI[md5sum] = "81aea5d3139e5189c2e055ed2c98cd91" +SRC_URI[sha256sum] = "f8a34cf52d9f9b9cb8c7f26b12da347d4af7eb904c13189602e4c6b62d1a79dc" inherit autotools pkgconfig lib_package diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb index c9913444..785abf66 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libnet/libnet_1.2-rc3.bb @@ -2,7 +2,7 @@ SUMMARY = "A packet dissection and creation library" # libnet at packetfactory.net is dead HOMEPAGE = "https://github.com/sam-github/libnet" SECTION = "libs" -LICENSE = "BSD" +LICENSE = "BSD-2-Clause" LIC_FILES_CHKSUM = "file://doc/COPYING;md5=3ec839e00408b484d33b472a86b7c266" DEPENDS = "libpcap" # There are major API changes beween libnet v1.0 and libnet v1.1 diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-Detect-clang.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-Detect-clang.patch deleted file mode 100644 index 7a3429b9..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-Detect-clang.patch +++ /dev/null @@ -1,85 +0,0 @@ -From 4cfb728804157e8f3c69e11ba4df449d8f76388f Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Thu, 20 Oct 2016 04:42:26 +0000 -Subject: [PATCH] Detect clang - -Check for clang compiler since we need to disable -unused-function warning for clang, at same time -pass werror when checking for compiler options if -werror is enabled so spurious options do not get -enabled. Only the ones that are supported by given -compiler are accepted. - -Signed-off-by: Khem Raj <raj.khem@gmail.com> -Upstream-Status: Pending - ---- - m4/compiler-warnings.m4 | 29 +++++++++++++++++++++++++---- - 1 file changed, 25 insertions(+), 4 deletions(-) - -diff --git a/m4/compiler-warnings.m4 b/m4/compiler-warnings.m4 -index de4a8b0..e4ba718 100644 ---- a/m4/compiler-warnings.m4 -+++ b/m4/compiler-warnings.m4 -@@ -2,10 +2,30 @@ AC_DEFUN([LIBQMI_COMPILER_WARNINGS], - [AC_ARG_ENABLE(more-warnings, - AS_HELP_STRING([--enable-more-warnings], [Possible values: no/yes/error]), - set_more_warnings="$enableval",set_more_warnings=error) -+ -+# Clang throws a lot of warnings when it does not understand a flag. Disable -+# this warning for now so other warnings are visible. -+AC_MSG_CHECKING([if compiling with clang]) -+AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [[ -+#ifndef __clang__ -+ not clang -+#endif -+ ]])], -+ [CLANG=yes], -+ [CLANG=no] -+) -+AC_MSG_RESULT([$CLANG]) -+AS_IF([test "x$CLANG" = "xyes"], [CLANG_FLAGS=-Wno-error=unused-function]) -+CFLAGS="$CFLAGS $CLANG_FLAGS" -+LDFLAGS="$LDFLAGS $CLANG_FLAGS" -+ - AC_MSG_CHECKING(for more warnings) - if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then - AC_MSG_RESULT(yes) - CFLAGS="-Wall -std=gnu89 $CFLAGS" -+ if test "x$set_more_warnings" = xerror; then -+ WERROR="-Werror" -+ fi - - for option in -Wmissing-declarations -Wmissing-prototypes \ - -Wdeclaration-after-statement -Wstrict-prototypes \ -@@ -17,22 +37,23 @@ if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then - -Wmissing-include-dirs -Waggregate-return \ - -Wformat-security -Wtype-limits; do - SAVE_CFLAGS="$CFLAGS" -- CFLAGS="$CFLAGS $option" -+ CFLAGS="$CFLAGS $option $WERROR" - AC_MSG_CHECKING([whether gcc understands $option]) - AC_TRY_COMPILE([], [], - has_option=yes, - has_option=no,) - if test $has_option = no; then - CFLAGS="$SAVE_CFLAGS" -+ else -+ CFLAGS="$SAVE_CFLAGS $option" - fi - AC_MSG_RESULT($has_option) - unset has_option - unset SAVE_CFLAGS - done -+ CFLAGS="$CFLAGS $WERROR" - unset option -- if test "x$set_more_warnings" = xerror; then -- CFLAGS="$CFLAGS -Werror" -- fi -+ unset WERROR - else - AC_MSG_RESULT(no) - fi --- -1.9.1 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-qmi-network-Don-t-create-invalid-wds-start-network-w.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-qmi-network-Don-t-create-invalid-wds-start-network-w.patch deleted file mode 100644 index d230d680..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi/0001-qmi-network-Don-t-create-invalid-wds-start-network-w.patch +++ /dev/null @@ -1,41 +0,0 @@ -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/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.24.12.bb index f0bc81cc..6f863854 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libqmi/libqmi_1.24.12.bb @@ -12,12 +12,13 @@ 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" + +SRC_URI[md5sum] = "7e6e49fddb9ae2b6fcde14619d6cfe49" +SRC_URI[sha256sum] = "2d3b91a2b8a882b17b16403c9ef7bdce522db4f0ceaa3e4dff76033885428b69" PACKAGECONFIG ??= "udev mbim" PACKAGECONFIG[udev] = ",--without-udev,libgudev" PACKAGECONFIG[mbim] = "--enable-mbim-qmux,--disable-mbim-qmux,libmbim" + +EXTRA_OECONF_append_toolchain-clang = " --enable-more-warnings=no" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/0001-Define-64bit-atomic-helpers-for-ppc-32-bit.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/0001-Define-64bit-atomic-helpers-for-ppc-32-bit.patch deleted file mode 100644 index 4d097971..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/0001-Define-64bit-atomic-helpers-for-ppc-32-bit.patch +++ /dev/null @@ -1,30 +0,0 @@ -From c9859a38a58996b8767a30e14febc03845f66f95 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Sat, 1 Jul 2017 13:10:53 -0700 -Subject: [PATCH] Define 64bit atomic helpers for ppc 32-bit - -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - src/atomic64.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/src/atomic64.c b/src/atomic64.c -index f841b39b..35c7c9d8 100644 ---- a/src/atomic64.c -+++ b/src/atomic64.c -@@ -18,10 +18,10 @@ - #include <stdbool.h> - - /* -- * only need these on MIPS, since it lacks hardware 64-bit atomics, -+ * only need these on MIPS & PPC32, since it lacks hardware 64-bit atomics, - * unlike x86 and ARM. - */ --#if defined(__mips__) || defined(__mipsel__) -+#if defined(__mips__) || defined(__mipsel__) || defined(__powerpc__) - - static void __spin_lock(volatile int *lock) { - while (__sync_lock_test_and_set(lock, 1)) --- -2.13.2 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/0001-implement-64bit-atomic-for-mips.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/0001-implement-64bit-atomic-for-mips.patch deleted file mode 100644 index 84e0772a..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent/0001-implement-64bit-atomic-for-mips.patch +++ /dev/null @@ -1,263 +0,0 @@ -From d7b6df5808e7bef5930b61a82e880699a9f9e208 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Thu, 29 Jun 2017 15:39:19 -0700 -Subject: [PATCH] implement 64bit atomic for mips - -GCC does not provide 64bit atomics for mips32 - -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - src/Makefile.am | 1 + - src/atomic64.c | 228 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 229 insertions(+) - create mode 100644 src/atomic64.c - -diff --git a/src/Makefile.am b/src/Makefile.am -index 99aaace0..cbbbbee9 100644 ---- a/src/Makefile.am -+++ b/src/Makefile.am -@@ -27,6 +27,7 @@ libtorrent_la_LIBADD = \ - utils/libsub_utils.la - - libtorrent_la_SOURCES = \ -+ atomic64.c \ - globals.cc \ - globals.h \ - manager.cc \ -diff --git a/src/atomic64.c b/src/atomic64.c -new file mode 100644 -index 00000000..f841b39b ---- /dev/null -+++ b/src/atomic64.c -@@ -0,0 +1,228 @@ -+/*===----- atomic64.c - Support functions for 64-bit atomic operations.-----=== -+ * -+ * The LLVM Compiler Infrastructure -+ * -+ * This file is dual licensed under the MIT and the University of Illinois Open -+ * Source Licenses. See LICENSE.TXT for details. -+ * -+ *===-----------------------------------------------------------------------=== -+ * -+ * atomic64.c defines a set of functions for performing atomic accesses on -+ * 64-bit memory locations. It also implements spinlock synchronization -+ * operations. -+ * -+ *===-----------------------------------------------------------------------=== -+ */ -+ -+#include <stdint.h> -+#include <stdbool.h> -+ -+/* -+ * only need these on MIPS, since it lacks hardware 64-bit atomics, -+ * unlike x86 and ARM. -+ */ -+#if defined(__mips__) || defined(__mipsel__) -+ -+static void __spin_lock(volatile int *lock) { -+ while (__sync_lock_test_and_set(lock, 1)) -+ while (*lock) {} -+} -+ -+static void __spin_unlock(volatile int *lock) { -+ __sync_lock_release(lock); -+} -+ -+/* -+ * Make sure the lock is on its own cache line to prevent false sharing. -+ * Put it inside a struct that is aligned and padded to the typical MIPS -+ * cacheline which is 32 bytes. -+ */ -+static struct { -+ int lock; -+ char pad[32 - sizeof(int)]; -+} __attribute__((aligned (32))) lock = { 0 }; -+ -+ -+uint64_t __sync_fetch_and_add_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr; -+ *ptr = ret + val; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_fetch_and_sub_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr; -+ *ptr = ret - val; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_fetch_and_and_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr; -+ *ptr = ret & val; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_fetch_and_or_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr; -+ *ptr = ret | val; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_fetch_and_xor_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr; -+ *ptr = ret ^ val; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_add_and_fetch_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr + val; -+ *ptr = ret; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_sub_and_fetch_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr - val; -+ *ptr = ret; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_and_and_fetch_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr & val; -+ *ptr = ret; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_or_and_fetch_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr | val; -+ *ptr = ret; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_xor_and_fetch_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr ^ val; -+ *ptr = ret; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+bool __sync_bool_compare_and_swap_8(volatile uint64_t *ptr, -+ uint64_t oldval, uint64_t newval) { -+ bool ret = false; -+ -+ __spin_lock(&lock.lock); -+ -+ if (*ptr == oldval) { -+ *ptr = newval; -+ ret = true; -+ } -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_val_compare_and_swap_8(volatile uint64_t *ptr, -+ uint64_t oldval, uint64_t newval) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr; -+ if (ret == oldval) -+ *ptr = newval; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+uint64_t __sync_lock_test_and_set_8(volatile uint64_t *ptr, uint64_t val) { -+ uint64_t ret; -+ -+ __spin_lock(&lock.lock); -+ -+ ret = *ptr; -+ *ptr = val; -+ -+ __spin_unlock(&lock.lock); -+ -+ return ret; -+} -+ -+void __sync_lock_release_8(volatile uint64_t *ptr) { -+ __spin_lock(&lock.lock); -+ -+ *ptr = 0; -+ -+ __spin_unlock(&lock.lock); -+} -+ -+#endif --- -2.13.2 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb index b2dffcdb..3ee69554 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libtorrent/libtorrent_git.bb @@ -8,15 +8,20 @@ DEPENDS = "zlib libsigc++-2.0 openssl cppunit" SRC_URI = "git://github.com/rakshasa/libtorrent \ file://don-t-run-code-while-configuring-package.patch \ - file://0001-implement-64bit-atomic-for-mips.patch \ - file://0001-Define-64bit-atomic-helpers-for-ppc-32-bit.patch \ " -SRCREV = "074f6ec51a2e4bc5c6140b4dad13c9bb56f3f0dc" +SRCREV = "756f70010779927dc0691e1e722ed433d5d295e1" -PV = "0.13.7+git${SRCPV}" +PV = "0.13.8" S = "${WORKDIR}/git" +PACKAGECONFIG ??= "instrumentation" + +PACKAGECONFIG_remove_mipsarch = "instrumentation" +PACKAGECONFIG_remove_powerpc = "instrumentation" + +PACKAGECONFIG[instrumentation] = "--enable-instrumentation,--disable-instrumentation," + inherit autotools pkgconfig EXTRA_OECONF = "--with-zlib=${STAGING_EXECPREFIXDIR}" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.20.3.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.36.0.bb index a11ff9d2..deeaa2b1 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.20.3.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libuv/libuv_1.36.0.bb @@ -4,10 +4,10 @@ BUGTRACKER = "https://github.com/libuv/libuv/issues" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://LICENSE;md5=a68902a430e32200263d182d44924d47" +SRCREV = "533b738838ad8407032e14b6772b29ef9af63cfa" +SRC_URI = "git://github.com/libuv/libuv;branch=v1.x" + S = "${WORKDIR}/git" -SRCREV = "8cfd67e59195251dff793ee47c185c9d6a8f3818" -BRANCH = "v1.x" -SRC_URI = "git://github.com/libuv/libuv.git;protocol=https;branch=${BRANCH};" inherit autotools diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_3.0.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_4.0.1.bb index f3841486..0d1f57ab 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_3.0.0.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/libwebsockets/libwebsockets_4.0.1.bb @@ -1,13 +1,16 @@ SUMMARY = "Canonical libwebsockets.org websocket library" HOMEPAGE = "https://libwebsockets.org/" -LICENSE = "LGPL-2.1" -LIC_FILES_CHKSUM = "file://LICENSE;md5=4ce87f3facb6f911c142c8bef9bfb380" +LICENSE = "MIT & Zlib & BSD-3-Clause" +LIC_FILES_CHKSUM = "file://LICENSE;md5=8c47b078124308a4e1354e8d59f606b7" DEPENDS = "zlib" S = "${WORKDIR}/git" -SRCREV = "eaa935a80adb38b5cc4d09ce06ec987b87dcddfa" -SRC_URI = "git://github.com/warmcat/libwebsockets.git;protocol=https;" +SRCREV = "6eb39388f43f6e2a27f0efcbf8cb2391e38824e9" +SRC_URI = "git://github.com/warmcat/libwebsockets.git;protocol=https;branch=v4.0-stable" + +UPSTREAM_CHECK_URI = "https://github.com/warmcat/${BPN}/releases" +UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)" inherit cmake pkgconfig @@ -21,6 +24,12 @@ 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," +EXTRA_OECMAKE += " \ + -DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \ +" + PACKAGES =+ "${PN}-testapps" FILES_${PN}-testapps += "${datadir}/libwebsockets-test-server/*" + +CFLAGS_append = " -Wno-error" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/0003-include-missing-time.h-for-time_t.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/0003-include-missing-time.h-for-time_t.patch deleted file mode 100644 index 96163f65..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/0003-include-missing-time.h-for-time_t.patch +++ /dev/null @@ -1,26 +0,0 @@ -From b36cafdbcbe2193f5b669e703c608e19e23f80a3 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Sat, 15 Jul 2017 11:16:42 -0700 -Subject: [PATCH 3/4] include missing time.h for time_t - -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - util.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/util.h b/util.h -index e912f19..3c634c1 100644 ---- a/util.h -+++ b/util.h -@@ -22,7 +22,7 @@ - - #include "ddt.h" - #include "ether.h" -- -+#include <time.h> - /** - * Table of human readable strings, one for each port state. - */ --- -2.13.3 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/0004-Adjust-include-header-sequence-to-avoid-duplicate-de.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/0004-Adjust-include-header-sequence-to-avoid-duplicate-de.patch deleted file mode 100644 index e6992751..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/0004-Adjust-include-header-sequence-to-avoid-duplicate-de.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 3cd28aa771934d9165ff0d7e19932cde65de3e52 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Sat, 15 Jul 2017 11:16:57 -0700 -Subject: [PATCH 4/4] Adjust include header sequence to avoid duplicate - definitions on musl - -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - raw.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/raw.c b/raw.c -index f51c829..494ea7f 100644 ---- a/raw.c -+++ b/raw.c -@@ -18,8 +18,6 @@ - */ - #include <errno.h> - #include <fcntl.h> --#include <linux/filter.h> --#include <linux/if_ether.h> - #include <net/ethernet.h> - #include <net/if.h> - #include <netinet/in.h> -@@ -32,6 +30,8 @@ - #include <sys/types.h> - #include <unistd.h> - -+#include <linux/filter.h> -+#include <linux/if_ether.h> - #include <linux/errqueue.h> - #include <linux/net_tstamp.h> - #include <linux/sockios.h> --- -2.13.3 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/time_t_maybe_long_long.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/time_t_maybe_long_long.patch new file mode 100644 index 00000000..af99d2b7 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp/time_t_maybe_long_long.patch @@ -0,0 +1,135 @@ +Fix printf if time_t is long long + +On some platforms, time_t has recently switched from "long" to "long +long" [1]. For these platforms it is necessary to use "%lld" as printf +format specifier because the ABI differs between "long" and "long long". + +I found no way for creating something similar to PRId64 for time_t. No +idea how to determine whether it's "long" or "long long". So I cast +everything to "long long" instead. + +[1] https://git.musl-libc.org/cgit/musl/commit/?id=38143339646a4ccce8afe298c34467767c899f51 + +Upstream-Status: Accepted [next version is after 2.0] +Upstream-Patch: https://github.com/richardcochran/linuxptp/commit/7de73fefc378cc42b9ed1115b3afa409d0250a48 + +Signed-off-by: Christian Eggers <ceggers@arri.de> +--- +diff -Naur linuxptp-2.0.org/phc_ctl.c linuxptp-2.0/phc_ctl.c +--- linuxptp-2.0.org/phc_ctl.c 2018-08-12 23:08:43.000000000 +0200 ++++ linuxptp-2.0/phc_ctl.c 2020-05-29 21:34:26.166519963 +0200 +@@ -230,8 +230,8 @@ + strerror(errno)); + return -1; + } else { +- pr_notice("set clock time to %ld.%09ld or %s", +- ts.tv_sec, ts.tv_nsec, ctime(&ts.tv_sec)); ++ pr_notice("set clock time to %lld.%09ld or %s", ++ (long long)ts.tv_sec, ts.tv_nsec, ctime(&ts.tv_sec)); + } + + return args_to_eat; +@@ -248,8 +248,8 @@ + + return -1; + } else { +- pr_notice("clock time is %ld.%09lu or %s", +- ts.tv_sec, ts.tv_nsec, ctime(&ts.tv_sec)); ++ pr_notice("clock time is %lld.%09lu or %s", ++ (long long)ts.tv_sec, ts.tv_nsec, ctime(&ts.tv_sec)); + } + + /* get operation does not require any arguments */ +diff -Naur linuxptp-2.0.org/print.c linuxptp-2.0/print.c +--- linuxptp-2.0.org/print.c 2018-08-12 23:08:43.000000000 +0200 ++++ linuxptp-2.0/print.c 2020-05-29 21:34:26.166519963 +0200 +@@ -73,16 +73,16 @@ + + if (verbose) { + f = level >= LOG_NOTICE ? stdout : stderr; +- fprintf(f, "%s[%ld.%03ld]: %s%s%s\n", ++ fprintf(f, "%s[%lld.%03ld]: %s%s%s\n", + progname ? progname : "", +- ts.tv_sec, ts.tv_nsec / 1000000, ++ (long long)ts.tv_sec, ts.tv_nsec / 1000000, + message_tag ? message_tag : "", message_tag ? " " : "", + buf); + fflush(f); + } + if (use_syslog) { +- syslog(level, "[%ld.%03ld] %s%s%s", +- ts.tv_sec, ts.tv_nsec / 1000000, ++ syslog(level, "[%lld.%03ld] %s%s%s", ++ (long long)ts.tv_sec, ts.tv_nsec / 1000000, + message_tag ? message_tag : "", message_tag ? " " : "", + buf); + } +diff -Naur linuxptp-2.0.org/unicast_service.c linuxptp-2.0/unicast_service.c +--- linuxptp-2.0.org/unicast_service.c 2018-08-12 23:08:43.000000000 +0200 ++++ linuxptp-2.0/unicast_service.c 2020-05-29 21:36:23.170497415 +0200 +@@ -209,9 +209,9 @@ + tmo = now.tv_sec + req->durationField; + if (tmo > client->grant_tmo) { + client->grant_tmo = tmo; +- pr_debug("%s grant of 0x%x extended to %ld", ++ pr_debug("%s grant of 0x%x extended to %lld", + pid2str(&client->portIdentity), +- client->message_types, tmo); ++ client->message_types, (long long)tmo); + } + } + +@@ -226,8 +226,8 @@ + interval = pqueue_peek(p->unicast_service->queue); + if (interval) { + tmo.it_value = interval->tmo; +- pr_debug("arming timer tmo={%ld,%ld}", +- interval->tmo.tv_sec, interval->tmo.tv_nsec); ++ pr_debug("arming timer tmo={%lld,%ld}", ++ (long long)interval->tmo.tv_sec, interval->tmo.tv_nsec); + } else { + pr_debug("stopping unicast service timer"); + } +@@ -499,8 +499,8 @@ + + while ((interval = pqueue_peek(p->unicast_service->queue)) != NULL) { + +- pr_debug("peek i={2^%d} tmo={%ld,%ld}", interval->log_period, +- interval->tmo.tv_sec, interval->tmo.tv_nsec); ++ pr_debug("peek i={2^%d} tmo={%lld,%ld}", interval->log_period, ++ (long long)interval->tmo.tv_sec, interval->tmo.tv_nsec); + + if (timespec_compare(&now, &interval->tmo) >= 0) { + break; +@@ -519,8 +519,8 @@ + } + + interval_increment(interval); +- pr_debug("next i={2^%d} tmo={%ld,%ld}", interval->log_period, +- interval->tmo.tv_sec, interval->tmo.tv_nsec); ++ pr_debug("next i={2^%d} tmo={%lld,%ld}", interval->log_period, ++ (long long)interval->tmo.tv_sec, interval->tmo.tv_nsec); + pqueue_insert(p->unicast_service->queue, interval); + } + +diff -Naur linuxptp-2.0.org/unicast_client.c linuxptp-2.0/unicast_client.c +--- linuxptp-2.0.org/unicast_client.c 2018-08-12 23:08:43.000000000 +0200 ++++ linuxptp-2.0/unicast_client.c 2020-06-02 11:13:06.922997844 +0200 +@@ -216,7 +216,7 @@ + long duration) + { + struct timespec now; +- long tmo; ++ time_t tmo; + + if (clock_gettime(CLOCK_MONOTONIC, &now)) { + pr_err("clock_gettime failed: %m"); +@@ -226,7 +226,7 @@ + tmo = now.tv_sec + duration; + if (!master->renewal_tmo || tmo < master->renewal_tmo) { + master->renewal_tmo = tmo; +- pr_debug("port %d: renewal timeout at %ld", portnum(p), tmo); ++ pr_debug("port %d: renewal timeout at %lld", portnum(p), (long long)tmo); + } + } + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp_1.8.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp_2.0.bb index c7b8b293..930c6673 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp_1.8.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/linuxptp/linuxptp_2.0.bb @@ -5,12 +5,11 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" SRC_URI = "http://sourceforge.net/projects/linuxptp/files/v${PV}/linuxptp-${PV}.tgz \ file://build-Allow-CC-and-prefix-to-be-overriden.patch \ file://no-incdefs-using-host-headers.patch \ - file://0003-include-missing-time.h-for-time_t.patch \ - file://0004-Adjust-include-header-sequence-to-avoid-duplicate-de.patch \ + file://time_t_maybe_long_long.patch \ " -SRC_URI[md5sum] = "5688cdfe57932273e1dbf35b3b97b9a0" -SRC_URI[sha256sum] = "fa8e00f6ec73cefa7bb313dce7f60dfe5eb9e2bde3353594e9ac18edc93e5165" +SRC_URI[md5sum] = "d8bb7374943bb747db7786ac26f17f11" +SRC_URI[sha256sum] = "0a24d9401e87d4af023d201e234d91127d82c350daad93432106284aa9459c7d" EXTRA_OEMAKE = "ARCH=${TARGET_ARCH} \ EXTRA_CFLAGS='-D_GNU_SOURCE -DHAVE_CLOCK_ADJTIME -DHAVE_POSIX_SPAWN -DHAVE_ONESTEP_SYNC ${CFLAGS}'" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lirc.tmpfiles b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lirc.tmpfiles deleted file mode 100644 index 0b80e2e4..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lirc.tmpfiles +++ /dev/null @@ -1 +0,0 @@ -d /run/lirc 0755 root root - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lirc_options.conf b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lirc_options.conf deleted file mode 100644 index d8ddedd8..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lirc_options.conf +++ /dev/null @@ -1,24 +0,0 @@ -# These are the default options to lircd, if installed as -# /etc/lirc/lirc_options.conf. See the lircd(8) and lircmd(8) -# manpages for info on the different options. - -[lircd] -nodaemon = False -permission = 666 -driver = default -device = /dev/lirc0 -output = /var/run/lirc/lircd -pidfile = /var/run/lirc/lircd.pid -plugindir = /usr/lib/lirc/plugins -allow-simulate = No -repeat-max = 600 -#listen = [address:]port -#connect = host[:port] -#debug = 5 -#uinput = ... -#release = ... -#logfile = ... - -[lircmd] -uinput = False -nodeamon = False diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.conf b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.conf deleted file mode 100644 index 29b03c72..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.conf +++ /dev/null @@ -1,315 +0,0 @@ -# contributed by angelo castello -# -# note: this config file has been deduced starting from the -# raw codes provided to run mode2 utility. -# -# brand: futarque - -begin remote - name futarque - bits 8 - flags SPACE_ENC|CONST_LENGTH - eps 30 - aeps 100 - - header 8048 3898 - one 555 1436 - zero 555 439 - gap 113123 - ptrail 555 - pre_data_bits 8 - pre_data 0x54 - pre 570 3890 - - begin codes - MUTE 0x70 - EXIT 0xA8 - POWER 0xF0 - CHANNEL_UP 0x50 - CHANNEL_DOWN 0xD0 - VOLUME_UP 0x30 - VOLUME_DOWN 0xB0 - OK 0x98 - FAVORITES 0x04 - TEXT 0x68 - EPG 0xC8 - BACK 0x48 - MENU 0x88 - 1 0x00 - 2 0x80 - 3 0x40 - 4 0xC0 - 5 0x20 - 6 0xA0 - 7 0x60 - 8 0xE0 - 9 0x10 - 0 0x90 - PAUSE 0x84 - INFO 0x38 - RED 0xE8 - GREEN 0x08 - YELLOW 0x28 - BLUE 0x78 - UP 0xD8 - DOWN 0xB8 - REWIND 0x44 - FASTFORWARD 0x24 - PLAYPAUSE 0xC4 - STOP 0x64 - RECORD 0xA4 - AUDIO 0xE4 - TAPE 0x14 - DVD 0x94 - CAPITAL_A 0xF8 - CAPITAL_B 0x54 - end codes - -end remote - -# brand: STM PVR-1 - -begin remote - name stm_pvr_1 - bits 16 - flags SPACE_ENC|CONST_LENGTH - eps 30 - aeps 150 - - header 9000 4500 - one 572 1700 - zero 572 572 - ptrail 572 - repeat 9000 2200 - pre_data_bits 16 - pre_data 0xFE - gap 100000 - - begin codes - POWER 0x00ff - FAVORITES 0x7887 - MUTE 0x28d7 - 0 0x708F - 1 0xc03f - 2 0x40bf - 3 0x807f - 4 0xe01f - 5 0x609f - 6 0xa05f - 7 0xd02f - 8 0x50af - 9 0x906f - INFO 0x38c7 - SUBTITLE 0xe817 - MENU 0x9867 - EXIT 0x20df - EPG 0xa857 - BACK 0x48b7 - CURSOR_UP 0x58a7 - CURSOR_DOWN 0xd827 - CURSOR_LEFT 0x8877 - CURSOR_RIGHT 0xb04f - OK 0x10ef - VOLUME_UP 0x22dd - VOLUME_DOWN 0x8a75 - CHANNEL_UP 0x12ed - CHANNEL_DOWN 0x4ab5 - TEXT 0xf00f - RADIO 0x926d - ZOOM 0x6897 - AUDIO 0x08f7 - RED 0x42bd - GREEN 0xa25d - YELLOW 0x827d - BLUE 0x02fd - CUSTOM0 0x52ad - CUSTOM1 0x30cf - PLAY 0x629d - PAUSE 0xb24d - PREVIOUS 0xc837 - NEXT 0xf807 - REWIND 0x32cd - FASTFORWARD 0x0af5 - AUX 0x7a85 - CUSTOM3 0xb847 - PIP 0x3ac5 - SWAP 0xba45 - end codes - -end remote - -# brand: STM DTV-2 - -begin remote - - name stm_dtv_2 - flags SHIFT_ENC|CONST_LENGTH - bits 13 - aeps 150 - - one 850 850 - zero 850 850 - plead 850 - gap 67800 - toggle_bit 2 - - begin codes - POWER 0x100C - FAVORITES 0x1015 - AUX 0x1038 - 1 0x1001 - 2 0x1002 - 3 0x1003 - 4 0x1004 - 5 0x1005 - 6 0x1006 - 7 0x1007 - 8 0x1008 - 9 0x1009 - PERIOD 0x1024 - 0 0x103E - BACK 0x1023 - MENU 0x1016 - INFO 0x100F - EPG 0x101E - EXIT 0x1018 - CURSOR_UP 0x1017 - CURSOR_DOWN 0x101D - CURSOR_LEFT 0x1019 - CURSOR_RIGHT 0x101B - OK 0x101A - VOLUME_UP 0x1010 - VOLUME_DOWN 0x1011 - CHANNEL_UP 0x1020 - CHANNEL_DOWN 0x1021 - TEXT 0x102E - SUBTITLE 0x103C - FREEZE 0x1014 - ZOOM 0x102B - RED 0x1028 - GREEN 0x102A - YELLOW 0x102F - BLUE 0x1030 - CUSTOM10 0x1022 - INTERNET 0x1027 - CUSTOM11 0x102C - AUDIO 0x1025 - RECORD 0x102D - PLAYPAUSE 0x1029 - STOP 0x1026 - CUSTOM1 0x101C - MUTE 0x100d - CUSTOM12 0x101F - PIP 0x100B - SWAP 0x100E - end codes - -end remote - -# brand: Comcast -# model no. of remote control: XR2 -# 32 bits for the pre-date (should be value 0x170F443E) -# width between pre_bits and data: 12900 microseconds -# -# 24 bits for the data (key code) -# To get key REPEAT, XOR 0x088 with KEY value -# There are 8 post bits (both should be zero) -# -# Gap between keys: 8100 microseconds -begin remote - - name Xfinity-XR2 - bits 24 - flags XMP - eps 20 - aeps 300 - - one 0 137 - zero 250 710 - ptrail 250 - pre_data_bits 32 - pre_data 0x170F443E - post_data_bits 8 - post_data 0x0 - pre 250 12921 - gap 81698 - toggle_bit_mask 0x0 - - begin codes - 1 0x1E0001 - 1_repeat 0x168001 - 2 0x1D0002 - 2_repeat 0x158002 - 3 0x1C0003 - 3_repeat 0x148003 - 4 0x1B0004 - 4_repeat 0x138004 - 5 0x1A0005 - 5_repeat 0x128005 - 6 0x190006 - 6_repeat 0x118006 - 7 0x180007 - 7_repeat 0x108007 - 8 0x170008 - 8_repeat 0x1F8008 - 9 0x160009 - 9_repeat 0x1E8009 - 0 0x1F0000 - 0_repeat 0x178000 - OK 0x180025 - OK_repeat 0x108025 - POWER 0x10000F - POWER_repeat 0x18800F - UP 0x1C0021 - UP_repeat 0x148021 - DOWN 0x1B0022 - DOWN_repeat 0x138022 - LEFT 0x1A0023 - LEFT_repeat 0x128023 - RIGHT 0x190024 - RIGHT_repeat 0x118024 - REWIND 0x190033 - REWIND_repeat 0x118033 - PLAY 0x1C0030 - PLAY_repeat 0x148030 - FASTFORWARD 0x180034 - FASTFORWARD_repeat 0x108034 - RECORD 0x170035 - RECORD_repeat 0x1F8035 - REPLAY 0x170053 - REPLAY_repeat 0x1F8053 - A 0x190060 - A_repeat 0x118060 - B 0x180061 - B_repeat 0x108061 - C 0x170062 - C_repeat 0x1F8062 - D 0x160063 - D_repeat 0x1E8063 - PAGE_UP 0x150028 - PAGE_UP_repeat 0x1D8028 - PAGE_DOWN 0x140029 - PAGE_DOWN_repeat 0x1C8029 - GUIDE 0x160027 - GUIDE_repeat 0x1E8027 - MENU 0x1D0020 - MENU_repeat 0x158020 - EXIT 0x13002A - EXIT_repeat 0x1B802A - INFO 0x170026 - INFO_repeat 0x1F8026 - LAST 0x190051 - LAST_repeat 0x118051 - VOLUME_UP 0x15000A - VOLUME_UP_repeat 0x1D800A - CHANNEL_UP 0x12000D - CHANNEL_UP_repeat 0x1A800D - VOLUME_DOWN 0x14000B - VOLUME_DOWN_repeat 0x1C800B - CHANNEL_DOWN 0x11000E - CHANNEL_DOWN_repeat 0x19800E - MUTE 0x13000C - MUTE_repeat 0x1B800D - end codes - -end remote diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.init b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.init deleted file mode 100644 index 8b124af6..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.init +++ /dev/null @@ -1,40 +0,0 @@ -#! /bin/sh -# -# This is an init script for Familiar -# Copy it to /etc/init.d/lircd and type -# > update-rc.d lircd defaults 20 -# - - -test -f /usr/sbin/lircd || exit 0 -test -f /etc/lircd.conf || exit 0 - -case "$1" in - start) - echo -n "Starting lirc daemon: lircd" - start-stop-daemon --start --quiet --exec /usr/sbin/lircd -- --device=/dev/lirc0 - echo "." - ;; - stop) - echo -n "Stopping lirc daemon: lircd" - start-stop-daemon --stop --quiet --exec /usr/sbin/lircd - echo "." - ;; - reload|force-reload) - start-stop-daemon --stop --quiet --signal 1 --exec /usr/sbin/lircd - ;; - restart) - echo -n "Stopping lirc daemon: lircd" - start-stop-daemon --stop --quiet --exec /usr/sbin/lircd - sleep 1 - echo -n "Starting lirc daemon: lircd" - start-stop-daemon --start --quiet --exec /usr/sbin/lircd -- --device=/dev/lirc0 - echo "." - ;; - *) - echo "Usage: /etc/init.d/lircd {start|stop|reload|restart|force-reload}" - exit 1 -esac - -exit 0 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.service b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.service deleted file mode 100644 index c8661368..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircd.service +++ /dev/null @@ -1,20 +0,0 @@ -[Unit] -Description=LIRC Infrared Signal Decoder -After=network.target - -[Service] -Type=forking -EnvironmentFile=/etc/lirc/lircd.conf -PIDFile=/run/lirc/lircd.pid -ExecStartPre=/bin/mkdir -p /run/lirc -ExecStartPre=/bin/rm -f /dev/lircd -ExecStartPre=/bin/rm -f /run/lirc/lircd -ExecStartPre=/bin/ln -s /run/lirc/lircd /dev/lircd - -ExecStart=/usr/sbin/lircd --pidfile=/run/lirc/lircd.pid --device=/dev/lirc0 - -ExecStopPost=/bin/rm -f /dev/lircd -ExecStopPost=/bin/rm -fR /run/lirc - -[Install] -WantedBy=multi-user.target diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircexec.init b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircexec.init deleted file mode 100644 index 3a8c1a30..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/lircexec.init +++ /dev/null @@ -1,37 +0,0 @@ -#! /bin/sh -# -# This is an init script for Familiar -# Copy it to /etc/init.d/lircexecd and type -# > update-rc.d lircexecd defaults 20 -# It must be started after lircd (and it does alphabetically :-) -# irexec reads /etc/lircrc by default - - -test -f /usr/bin/irexec || exit 0 -test -f /etc/lircrc || exit 0 - -case "$1" in - start) - echo -n "Starting lircexec daemon: irexec" - start-stop-daemon --start --quiet --exec /usr/bin/irexec -- --daemon - echo "." - ;; - stop) - echo -n "Stopping lircexec daemon: irexec" - start-stop-daemon --stop --quiet --exec /usr/bin/irexec - echo "." - ;; - restart|force-restart) - echo -n "Stopping lircexec daemon: irexec" - start-stop-daemon --stop --quiet --exec /usr/bin/irexec - sleep 1 - echo -n "Starting lircexec daemon: irexec" - start-stop-daemon --start --quiet --exec /usr/bin/irexec -- --daemon - echo "." - ;; - *) - echo "Usage: /etc/init.d/lircexec {start|stop|reload|restart|force-restart}" - exit 1 -esac - -exit 0 diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/pollfd.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/pollfd.patch deleted file mode 100644 index 4feea803..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc/pollfd.patch +++ /dev/null @@ -1,101 +0,0 @@ -Index: lirc-0.9.4d/daemons/lircrcd.cpp -=================================================================== ---- lirc-0.9.4d.orig/daemons/lircrcd.cpp -+++ lirc-0.9.4d/daemons/lircrcd.cpp -@@ -29,10 +29,12 @@ - #include <sys/un.h> - #include <sys/stat.h> - #include <sys/types.h> -+#include <poll.h> - #include <syslog.h> - - #include "lirc_client.h" - #include "lirc/lirc_log.h" -+#include "lirc/curl_poll.h" - - #define MAX_CLIENTS 100 - #define WHITE_SPACE " \t" -Index: lirc-0.9.4d/lib/curl_poll.c -=================================================================== ---- lirc-0.9.4d.orig/lib/curl_poll.c -+++ lirc-0.9.4d/lib/curl_poll.c -@@ -36,6 +36,7 @@ - #include <stdlib.h> - #include <sys/time.h> - #include <sys/types.h> -+#include <sys/poll.h> - - #include "lirc_log.h" - #include "curl_poll.h" -@@ -67,7 +68,7 @@ static const logchannel_t logchannel = L - - #ifdef HAVE_POLL_FINE - --int curl_poll(struct pollfd ufds[], unsigned int nfds, int timeout_ms) -+int curl_poll(struct pollfd *ufds, unsigned int nfds, int timeout_ms) - { - return poll(ufds, nfds, timeout_ms); - } -@@ -112,7 +113,7 @@ static int verify_sock(int s) - } - - --int curl_poll(struct pollfd ufds[], unsigned int nfds, int timeout_ms) -+int curl_poll(struct pollfd *ufds, unsigned int nfds, int timeout_ms) - { - struct timeval pending_tv; - struct timeval* ptimeout; -Index: lirc-0.9.4d/lib/curl_poll.h -=================================================================== ---- lirc-0.9.4d.orig/lib/curl_poll.h -+++ lirc-0.9.4d/lib/curl_poll.h -@@ -1,5 +1,5 @@ --#ifndef _POLL_H --#define _POLL_H -+#ifndef _LIB_CURL_POLL_H -+#define _LIB_CURL_POLL_H - /*************************************************************************** - * _ _ ____ _ - * Project ___| | | | _ \| | -@@ -29,13 +29,9 @@ - extern "C" { - #endif - --#ifdef HAVE_SYS_POLL_H --#include <sys/poll.h> --#else - #include <poll.h> --#endif - --int curl_poll(struct pollfd ufds[], unsigned int nfds, int timeout_ms); -+int curl_poll(struct pollfd *ufds, unsigned int nfds, int timeout_ms); - - #ifdef __cplusplus - } -Index: lirc-0.9.4d/lib/lirc/curl_poll.h -=================================================================== ---- lirc-0.9.4d.orig/lib/lirc/curl_poll.h -+++ lirc-0.9.4d/lib/lirc/curl_poll.h -@@ -1,5 +1,5 @@ --#ifndef _POLL_H --#define _POLL_H -+#ifndef _LIRC_CURL_POLL_H -+#define _LIRC_CURL_POLL_H - /*************************************************************************** - * _ _ ____ _ - * Project ___| | | | _ \| | -@@ -29,13 +29,9 @@ - extern "C" { - #endif - --#ifdef HAVE_SYS_POLL_H --#include <sys/poll.h> --#else - #include <poll.h> --#endif - --int curl_poll(struct pollfd ufds[], unsigned int nfds, int timeout_ms); -+int curl_poll(struct pollfd *ufds, unsigned int nfds, int timeout_ms); - - #ifdef __cplusplus - } diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc_0.9.4d.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc_0.9.4d.bb deleted file mode 100644 index b13163de..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/lirc/lirc_0.9.4d.bb +++ /dev/null @@ -1,87 +0,0 @@ -DESCRIPTION = "LIRC is a package that allows you to decode and send infra-red signals of many commonly used remote controls." -DESCRIPTION_append_lirc = " This package contains the lirc daemon, libraries and tools." -DESCRIPTION_append_lirc-exec = " This package contains a daemon that runs programs on IR signals." -DESCRIPTION_append_lirc-remotes = " This package contains some config files for remotes." -DESCRIPTION_append_lirc-nslu2example = " This package contains a working config for RC5 remotes and a modified NSLU2." -HOMEPAGE = "http://www.lirc.org" -SECTION = "console/network" -LICENSE = "GPLv2" -DEPENDS = "libxslt-native alsa-lib libftdi libusb1 libusb-compat jack portaudio-v19" - - -LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" - -SRC_URI = "http://prdownloads.sourceforge.net/lirc/lirc-${PV}.tar.bz2 \ - file://pollfd.patch \ - file://lircd.service \ - file://lircd.init \ - file://lircexec.init \ - file://lircd.conf \ - file://lirc_options.conf \ - file://lirc.tmpfiles \ -" -SRC_URI[md5sum] = "0d11679cbdd94a5a6da00a8e7231b4bf" -SRC_URI[sha256sum] = "c68f18c35b489b865c0a741d119b136e8702191538cd3551b977a7af6c4e41ab" - -SYSTEMD_PACKAGES = "lirc lirc-exec" -SYSTEMD_SERVICE_${PN} = "lircd.service lircmd.service lircd-setup.service lircd-uinput.service" -SYSTEMD_SERVICE_${PN}-exec = "irexec.service" -SYSTEMD_AUTO_ENABLE_lirc = "enable" -SYSTEMD_AUTO_ENABLE_lirc-exec = "enable" - -inherit autotools pkgconfig systemd python3native - -PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir,systemd" -PACKAGECONFIG[x11] = "--with-x,--with-x=no,libx11," - -PACKAGECONFIG ?= " \ - ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', ' systemd', '', d)} \ - ${@bb.utils.contains('DISTRO_FEATURES', 'x11', ' x11', '', d)} \ -" -CACHED_CONFIGUREVARS = "HAVE_WORKING_POLL=yes" - -#EXTRA_OEMAKE = 'SUBDIRS="lib daemons tools"' -do_install_append() { - install -m 0755 -d ${D}${sysconfdir} - install -m 0755 -d ${D}${sysconfdir}/lirc - install -m 0755 -d ${D}${systemd_unitdir}/system - install -m 0755 -d ${D}${libdir}/tmpfiles.d - install -m 0644 ${WORKDIR}/lircd.conf ${D}${sysconfdir}/lirc/ - install -m 0644 ${WORKDIR}/lirc_options.conf ${D}${sysconfdir}/lirc/ - install -m 0644 ${WORKDIR}/lircd.service ${D}${systemd_unitdir}/system/ - install -m 0755 ${WORKDIR}/lircexec.init ${D}${systemd_unitdir}/system/ - install -m 0644 ${WORKDIR}/lirc.tmpfiles ${D}${libdir}/tmpfiles.d/lirc.conf - rm -rf ${D}${libdir}/lirc/plugins/*.la - rmdir ${D}/var/run/lirc ${D}/var/run - chown -R root:root ${D}${datadir}/lirc/contrib -} - -PACKAGES =+ "${PN}-contrib ${PN}-exec ${PN}-plugins ${PN}-python" - -RDEPENDS_${PN} = "bash" -RDEPENDS_${PN}-exec = "${PN}" -RDEPENDS_${PN}-python = "python" - -RRECOMMENDS_lirc = "${PN}-exec ${PN}-plugins" - -FILES_${PN}-plugins = "${libdir}/lirc/plugins/*.so ${datadir}/lirc/configs" -FILES_${PN}-contrib = "${datadir}/lirc/contrib" -FILES_${PN}-exec = "${bindir}/irexec ${sysconfdir}/lircexec ${systemd_unitdir}/system/irexec.service" -FILES_${PN} += "${systemd_unitdir}/system/lircexec.init" -FILES_${PN} += "${systemd_unitdir}/system/lircd.service" -FILES_${PN} += "${systemd_unitdir}/system/lircd.socket" -FILES_${PN} += "${libdir}/tmpfiles.d/lirc.conf" -FILES_${PN}-dbg += "${libdir}/lirc/plugins/.debug" -FILES_${PN}-python += "${libdir}/python*/site-packages" - - -INITSCRIPT_PACKAGES = "lirc lirc-exec" -INITSCRIPT_NAME_lirc-exec = "lircexec" -INITSCRIPT_PARAMS_lirc-exec = "defaults 21" - -# this is for distributions that don't use udev -pkg_postinst_${PN}_append() { - if [ ! -c $D/dev/lirc -a ! -f /sbin/udevd ]; then mknod $D/dev/lirc c 61 0; fi -} - -SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager/0001-Do-not-set-Wno-unused-but-set-variable.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager/0001-Do-not-set-Wno-unused-but-set-variable.patch deleted file mode 100644 index dcbe01d5..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager/0001-Do-not-set-Wno-unused-but-set-variable.patch +++ /dev/null @@ -1,30 +0,0 @@ -From d4f73b037d11d20f080e74c05df28853fb833075 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Fri, 7 Dec 2018 22:59:47 -0800 -Subject: [PATCH] Do not set Wno-unused-but-set-variable - -This is gcc specific warning, not implemented by pretending to be gcc -like compilers e.g. clang. - -We will pass this option from recipe - -Upstream-Status: Inappropriate [OE-Specific] - -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - m4/compiler_warnings.m4 | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/m4/compiler_warnings.m4 b/m4/compiler_warnings.m4 -index f498a28..e65e97f 100644 ---- a/m4/compiler_warnings.m4 -+++ b/m4/compiler_warnings.m4 -@@ -11,7 +11,7 @@ if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then - -Wdeclaration-after-statement -Wstrict-prototypes \ - -Wno-unused-parameter -Wno-sign-compare \ - -Wno-deprecated-declarations \ -- -Wno-unused-but-set-variable -Wformat-security; do -+ -Wno-unused -Wformat-security; do - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS $option" - AC_MSG_CHECKING([whether gcc understands $option]) diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.12.10.bb index 01c62144..deab6f04 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.8.2.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/modemmanager/modemmanager_1.12.10.bb @@ -9,37 +9,37 @@ LIC_FILES_CHKSUM = " \ inherit gnomebase gettext systemd vala gobject-introspection bash-completion -DEPENDS = "glib-2.0 libgudev dbus-glib intltool-native" +DEPENDS = "glib-2.0 libgudev intltool-native libxslt-native" SRC_URI = "http://www.freedesktop.org/software/ModemManager/ModemManager-${PV}.tar.xz \ - file://0001-Do-not-set-Wno-unused-but-set-variable.patch \ " -SRC_URI[md5sum] = "a49c9f73e46c7b89e5efedda250d22c0" -SRC_URI[sha256sum] = "96f2a5f0ed15532b4c4c185b756fdc0326e7c2027cea26a1264f91e098260f80" +SRC_URI[sha256sum] = "b2b3058bbb72adf98b24707fdbebe58e590644a38145e30d574f685f154bf8aa" S = "${WORKDIR}/ModemManager-${PV}" -PACKAGECONFIG ??= "mbim qmi polkit \ - ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \ +PACKAGECONFIG ??= "mbim qmi \ + ${@bb.utils.filter('DISTRO_FEATURES', 'systemd polkit', d)} \ " +PACKAGECONFIG[at] = "--with-at-command-via-dbus" 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" +PACKAGECONFIG[mbim] = "--with-mbim,--without-mbim,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 \ " -CFLAGS_append_toolchain-gcc = " -Wno-unused-but-set-variable" +EXTRA_OECONF_append_toolchain-clang = " --enable-more-warnings=no" FILES_${PN} += " \ ${datadir}/icons \ ${datadir}/polkit-1 \ ${datadir}/dbus-1 \ + ${datadir}/ModemManager \ ${libdir}/ModemManager \ ${systemd_unitdir}/system \ " diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/mosh/mosh/0001-Fix-building-with-libc.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/mosh/mosh/0001-Fix-building-with-libc.patch new file mode 100644 index 00000000..100ede17 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/mosh/mosh/0001-Fix-building-with-libc.patch @@ -0,0 +1,24 @@ +From efa9e49714b30d7d9128946a2504c93e10d109b5 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Tue, 29 Jan 2019 12:20:03 -0800 +Subject: [PATCH] Fix building with libc++ + +Upstream-Status: Pending +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + src/network/network.cc | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/network/network.cc b/src/network/network.cc +index 26da603..e480853 100644 +--- a/src/network/network.cc ++++ b/src/network/network.cc +@@ -335,7 +335,7 @@ bool Connection::try_bind( const char *addr, int port_low, int port_high ) + } + } + +- if ( bind( sock(), &local_addr.sa, local_addr_len ) == 0 ) { ++ if ( ::bind( sock(), &local_addr.sa, local_addr_len ) == 0 ) { + set_MTU( local_addr.sa.sa_family ); + return true; + } else if ( i == search_high ) { /* last port to search */ diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/mosh/mosh_1.3.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/mosh/mosh_1.3.2.bb index 9fc8435e..9c439354 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/mosh/mosh_1.3.0.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/mosh/mosh_1.3.2.bb @@ -14,9 +14,11 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504" DEPENDS = "protobuf-native protobuf ncurses zlib libio-pty-perl openssl libutempter" -SRC_URI = "http://mosh.mit.edu/mosh-${PV}.tar.gz" -SRC_URI[md5sum] = "d961276995936953bf2d5a794068b076" -SRC_URI[sha256sum] = "320e12f461e55d71566597976bd9440ba6c5265fa68fbf614c6f1c8401f93376" +SRC_URI = "http://mosh.mit.edu/mosh-${PV}.tar.gz \ + file://0001-Fix-building-with-libc.patch \ + " +SRC_URI[md5sum] = "5122f4d2b973ab7c38dcdac8c35cb61e" +SRC_URI[sha256sum] = "da600573dfa827d88ce114e0fed30210689381bbdcff543c931e4d6a2e851216" inherit autotools pkgconfig diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/obex/obex-data-server_0.4.6.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/obex/obex-data-server_0.4.6.bb index 715b0235..87637093 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/obex/obex-data-server_0.4.6.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/obex/obex-data-server_0.4.6.bb @@ -2,8 +2,7 @@ DESCRIPTION = "obex-data-server is a D-Bus service providing high-level OBEX cli LICENSE = "GPLv2" LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" -DEPENDS = "gtk+ dbus-glib dbus-glib-native imagemagick openobex" -DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES','bluez5','bluez5','bluez4',d)}" +DEPENDS = "gtk+ dbus-glib dbus-glib-native imagemagick openobex bluez5" SRC_URI = "http://tadas.dailyda.com/software/obex-data-server-${PV}.tar.gz \ file://obex-data-server-0.4.6-build-fixes-1.patch \ @@ -11,7 +10,7 @@ SRC_URI = "http://tadas.dailyda.com/software/obex-data-server-${PV}.tar.gz \ SRC_URI[md5sum] = "961ca5db6fe9c97024e133cc6203cc4d" SRC_URI[sha256sum] = "b399465ddbd6d0217abedd9411d9d74a820effa0a6a142adc448268d3920094f" -inherit distro_features_check autotools-brokensep pkgconfig +inherit features_check autotools-brokensep pkgconfig REQUIRED_DISTRO_FEATURES = "x11" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb index 3fb8cb19..87907239 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/obex/openobex_1.7.2.bb @@ -8,7 +8,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a \ " DEPENDS = "virtual/libusb0" -DEPENDS_append_class-target = " ${@bb.utils.contains('DISTRO_FEATURES','bluez5','bluez5','bluez4',d)}" +DEPENDS_append_class-target = " bluez5" SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}/${PV}/${BP}-Source.tar.gz \ " diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/packagegroups/packagegroup-tools-bluetooth.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/packagegroups/packagegroup-tools-bluetooth.bb index f2a16dcf..efa3467a 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/packagegroups/packagegroup-tools-bluetooth.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/packagegroups/packagegroup-tools-bluetooth.bb @@ -6,19 +6,12 @@ LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" SUMMARY = "Set of Bluetooth related tools for inclusion in images" -DESCRIPTION = "Includes bluetooth specific tools for this version of BlueZ.\ -These tools are used at runtime. \ -Supports BlueZ4 and BlueZ5." +DESCRIPTION = "Includes bluetooth specific tools for BlueZ.\ +These tools are used at runtime." inherit packagegroup -inherit bluetooth -RDEPENDS_bluez4 = " \ - obexftp \ - ${@bb.utils.contains('DISTRO_FEATURES', 'alsa', 'libasound-module-bluez', '', d)} \ -" - -RDEPENDS_bluez5 = " \ +RDEPENDS_${PN} = " \ bluez5-noinst-tools \ bluez5-obex \ bluez5-testtools \ @@ -31,7 +24,3 @@ RDEPENDS_bluez5 = " \ pulseaudio-module-loopback', \ '', d)} \ " - -# Install bluez4 tools or bluez5 tools depending on what is specified in the distro. -# Otherwise install nothing. -RDEPENDS_${PN} = "${RDEPENDS_${BLUEZ}}" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/files/0001-Fix-bug-of-free-with-musl.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/files/0001-Fix-bug-of-free-with-musl.patch new file mode 100644 index 00000000..12f9e7ab --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/files/0001-Fix-bug-of-free-with-musl.patch @@ -0,0 +1,39 @@ +From 96233a8382b9520293a48b08dc3b204a21205800 Mon Sep 17 00:00:00 2001 +From: Wang Mingyu <wangmy@cn.fujitsu.com> +Date: Fri, 24 Apr 2020 00:53:19 +0900 +Subject: [PATCH] Fix bug of free() with musl + +This fixes build error with musl C library: +/ubinux-dev/ubinux001/contribution/build/tmp/work/armv7vet2hf-neon-poky-linux-musleabi/paho-mqtt-c/1.3.2-r0/git/src/Heap.h:55:24: +error: expected declaration specifiers or '...' before string constant + 55 | #define free(x) myfree(__FILE__, __LINE__, x) + | ^~~~~~~~ +/ubinux-dev/ubinux001/contribution/build/tmp/work/armv7vet2hf-neon-poky-linux-musleabi/paho-mqtt-c/1.3.2-r0/git/src/Heap.h:55:34: +error: expected declaration specifiers or '...' before numeric constant + 55 | #define free(x) myfree(__FILE__, __LINE__, x) + | ^~~~~~~~ + +Signed-off-by: Wang Mingyu <wangmy@cn.fujitsu.com> +--- + src/MQTTReasonCodes.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/MQTTReasonCodes.c b/src/MQTTReasonCodes.c +index 416eab5..479dbac 100644 +--- a/src/MQTTReasonCodes.c ++++ b/src/MQTTReasonCodes.c +@@ -16,10 +16,10 @@ + + #include "MQTTReasonCodes.h" + +-#include "Heap.h" + #include "StackTrace.h" + + #include <memory.h> ++#include "Heap.h" + + #define ARRAY_SIZE(a) (sizeof(a) / sizeof(a[0])) + +-- +2.17.1 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.1.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.1.bb deleted file mode 100644 index a7a9b5a6..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.2.1.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 = "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/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.3.2.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.3.2.bb new file mode 100644 index 00000000..071d51fc --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/paho-mqtt-c/paho-mqtt-c_1.3.2.bb @@ -0,0 +1,31 @@ +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-2.0 | EDL-1.0" + +LIC_FILES_CHKSUM = " \ + file://edl-v10;md5=3adfcc70f5aeb7a44f3f9b495aa1fbf3 \ + file://epl-v20;md5=d9fc0efef5228704e7f5b37f27192723 \ + file://notice.html;md5=943f861069889acecebf51dfa24478e2 \ + file://about.html;md5=e5662cbb5f8fd5c9faac526e4077898e \ +" + +SRC_URI = "git://github.com/eclipse/paho.mqtt.c;protocol=http \ + file://0001-Fix-bug-of-free-with-musl.patch" + +SRCREV = "3148fe2d5f4b87e16266dfe559c0764e16ca0546" + +DEPENDS = "openssl" + +S = "${WORKDIR}/git" + +inherit cmake + +do_install_append() { + # paho-mqtt installes some thing that we don't want. + rm -rf ${D}${prefix}/samples + find ${D}${prefix} -maxdepth 1 -type f -delete +} + +EXTRA_OECMAKE = "-DPAHO_WITH_SSL=ON" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/rabbitmq-c/rabbitmq-c_0.7.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/rabbitmq-c/rabbitmq-c_0.10.0.bb index e9846fde..2ef6b187 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/rabbitmq-c/rabbitmq-c_0.7.0.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/rabbitmq-c/rabbitmq-c_0.10.0.bb @@ -4,15 +4,16 @@ LIC_FILES_CHKSUM = "file://LICENSE-MIT;md5=6b7424f9db80cfb11fdd5c980b583f53" LICENSE = "MIT" SRC_URI = "git://github.com/alanxz/rabbitmq-c.git" -SRCREV = "4dde30ce8d984edda540349f57eb7995a87ba9de" +# v0.10.0-master +SRCREV = "ffe918a5fcef72038a88054dca3c56762b1953d4" S = "${WORKDIR}/git" DEPENDS = "popt openssl" -EXTRA_OECONF = "--disable-examples --enable-tools --disable-docs" +EXTRA_OECMAKE = "-DBUILD_EXAMPLES=OFF -DBUILD_TOOLS=ON -DBUILD_TOOLS_DOCS=OFF -DBUILD_API_DOCS=OFF" -inherit autotools pkgconfig +inherit cmake pkgconfig PACKAGE_BEFORE_PN += "${PN}-tools" FILES_${PN}-tools = "${bindir}" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/rfkill/rfkill_0.5.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/rfkill/rfkill_0.5.bb index 3e644760..5c19e65b 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/rfkill/rfkill_0.5.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/rfkill/rfkill_0.5.bb @@ -1,7 +1,7 @@ SUMMARY = "Radio enable/disable command line utility" HOMEPAGE = "http://linuxwireless.org/en/users/Documentation/rfkill" SECTION = "base" -LICENSE = "BSD" +LICENSE = "BSD-0-Clause" LIC_FILES_CHKSUM = "file://COPYING;md5=c6036d0eb7edbfced28c4160e5d3fa94" SRC_URI = "http://www.kernel.org/pub/software/network/${BPN}/${BP}.tar.bz2 \ diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent/don-t-run-code-while-configuring-package.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent/don-t-run-code-while-configuring-package.patch index 79d4f29f..7d09f438 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent/don-t-run-code-while-configuring-package.patch +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent/don-t-run-code-while-configuring-package.patch @@ -1,19 +1,26 @@ -Using AC_RUN_IFELSE prevent people from configuring package for -cross-compiling. Don't run code while configuring package. +Using AC_RUN_IFELSE prevent people from configuring package + for cross-compiling. Don't run code while configuring package. Upstream-Status: Pending Signed-off-by: Andrei Gherzan <andrei@gherzan.ro> -Index: libtorrent-0.13.3/scripts/checks.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 @@ +Update for 0.9.8. +Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> +--- + scripts/checks.m4 | 34 ---------------------------------- + scripts/common.m4 | 28 ---------------------------- + 2 files changed, 62 deletions(-) +diff --git a/scripts/checks.m4 b/scripts/checks.m4 +index 83be846..1af80f5 100644 +--- a/scripts/checks.m4 ++++ b/scripts/checks.m4 +@@ -95,40 +95,6 @@ AC_DEFUN([TORRENT_CHECK_KQUEUE], [ + AC_DEFUN([TORRENT_CHECK_KQUEUE_SOCKET_ONLY], [ AC_MSG_CHECKING(whether kqueue supports pipes and ptys) - -- AC_RUN_IFELSE([AC_LANG_SOURCE([ +- AC_LINK_IFELSE([AC_LANG_SOURCE([ - #include <fcntl.h> - #include <stdlib.h> - #include <unistd.h> @@ -47,18 +54,18 @@ Index: libtorrent-0.13.3/scripts/checks.m4 - 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 @@ - +diff --git a/scripts/common.m4 b/scripts/common.m4 +index aaf005e..42fb016 100644 +--- a/scripts/common.m4 ++++ b/scripts/common.m4 +@@ -152,38 +152,10 @@ dnl Need to fix this so that it uses the stuff defined by the system. + AC_DEFUN([TORRENT_CHECK_EXECINFO], [ AC_MSG_CHECKING(for execinfo.h) - -- AC_RUN_IFELSE([AC_LANG_SOURCE([ +- AC_COMPILE_IFELSE([AC_LANG_SOURCE([ - #include <execinfo.h> - int main() { backtrace((void**)0, 0); backtrace_symbols((char**)0, 0); return 0;} - ])], @@ -69,11 +76,11 @@ Index: libtorrent-0.13.3/scripts/common.m4 - AC_MSG_RESULT(no) - ]) ]) - + AC_DEFUN([TORRENT_CHECK_ALIGNED], [ AC_MSG_CHECKING(the byte alignment) - -- AC_RUN_IFELSE([AC_LANG_SOURCE([ +- AC_LINK_IFELSE([AC_LANG_SOURCE([ - #include <inttypes.h> - int main() { - char buf@<:@8@:>@ = { 0, 0, 0, 0, 1, 0, 0, 0 }; @@ -90,5 +97,8 @@ Index: libtorrent-0.13.3/scripts/common.m4 - AC_MSG_RESULT(required) - ]) ]) - + + +-- +2.7.4 diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb index 9bb81c40..331f978f 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/rtorrent/rtorrent_git.bb @@ -8,10 +8,10 @@ DEPENDS = "libsigc++-2.0 curl cppunit libtorrent ncurses" SRC_URI = "git://github.com/rakshasa/rtorrent \ file://don-t-run-code-while-configuring-package.patch \ " -# v0.9.7 -SRCREV = "327164f9d86aafcd2500a317d485374df32ea622" +# v0.9.8 +SRCREV = "6154d1698756e0c4842b1c13a0e56db93f1aa947" -PV = "0.9.7+git${SRCPV}" +PV = "0.9.8" S = "${WORKDIR}/git" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.5.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_4.1.8.bb index f64776c5..4a91fa4f 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_3.5.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/ser2net/ser2net_4.1.8.bb @@ -5,10 +5,13 @@ HOMEPAGE = "http://sourceforge.net/projects/ser2net/" LICENSE = "GPLv2" LIC_FILES_CHKSUM = "file://COPYING;md5=bae3019b4c6dc4138c217864bd04331f" +DEPENDS = "gensio libyaml" + SRC_URI = "${SOURCEFORGE_MIRROR}/project/ser2net/ser2net/ser2net-${PV}.tar.gz" -SRC_URI[md5sum] = "e10e7c8c97e5bade5e85ce6e89bdf1f4" -SRC_URI[sha256sum] = "ba9e1d60a89fd7ed075553b4a2074352902203f7fbd9b65b15048c05f0e3f3be" +SRC_URI[sha256sum] = "cffb5147021202b064eb0a9389d0db63d1bb2dcde5a896f7785f97b1b5f51a72" + +UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/ser2net/files/ser2net" inherit autotools pkgconfig diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-glib_0.24.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-glib_0.24.1.bb index 01c6e378..2b05c61a 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-glib_0.24.0.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-glib_0.24.1.bb @@ -5,12 +5,14 @@ DEPENDS = "glib-2.0 dbus hostpython-runtime-native dbus-native dbus-glib libxslt LICENSE = "LGPLv2.1+" SRC_URI = "http://telepathy.freedesktop.org/releases/telepathy-glib/${BP}.tar.gz" -SRC_URI[md5sum] = "93c429e37750b25dcf8de86bb514664f" -SRC_URI[sha256sum] = "ae0002134991217f42e503c43dea7817853afc18863b913744d51ffa029818cf" +SRC_URI[md5sum] = "cbeb0a24acc26e7f095be281c324da69" +SRC_URI[sha256sum] = "9e0df1d8f857e0270cf0b32e2d1ca5a24aa7282873361785d573f72ad7f7d5eb" LIC_FILES_CHKSUM = "file://COPYING;md5=e413d83db6ee8f2c8e6055719096a48e" -inherit autotools pkgconfig gettext gobject-introspection +inherit autotools pkgconfig gettext gobject-introspection vala + +EXTRA_OECONF = "--enable-vala-bindings" FILES_${PN} += "${datadir}/telepathy \ ${datadir}/dbus-1" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-idle_0.2.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-idle_0.2.0.bb index ca09f6da..7cb25b67 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-idle_0.2.0.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/telepathy/telepathy-idle_0.2.0.bb @@ -11,7 +11,12 @@ SRC_URI = "http://telepathy.freedesktop.org/releases/${BPN}/${BPN}-${PV}.tar.gz SRC_URI[md5sum] = "92a2de5198284cbd3c430b0d1a971a86" SRC_URI[sha256sum] = "3013ad4b38d14ee630b8cc8ada5e95ccaa849b9a6fe15d2eaf6d0717d76f2fab" -inherit autotools pkgconfig pythonnative +inherit autotools pkgconfig ${@bb.utils.contains("BBFILE_COLLECTIONS", "meta-python2", "pythonnative", "", d)} FILES_${PN} += "${datadir}/telepathy \ ${datadir}/dbus-1" + +python() { + if 'meta-python2' not in d.getVar('BBFILE_COLLECTIONS').split(): + raise bb.parse.SkipRecipe('Requires meta-python2 to be present.') +} diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-Forcibly-disable-check-for-Qt5.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-Forcibly-disable-check-for-Qt5.patch deleted file mode 100644 index a77cd284..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-Forcibly-disable-check-for-Qt5.patch +++ /dev/null @@ -1,25 +0,0 @@ -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(-) - -diff --git a/build/cmake/DefineOptions.cmake b/build/cmake/DefineOptions.cmake -index 62e240f..f8b4493 100644 ---- a/build/cmake/DefineOptions.cmake -+++ b/build/cmake/DefineOptions.cmake -@@ -52,9 +52,6 @@ CMAKE_DEPENDENT_OPTION(WITH_LIBEVENT "Build with libevent support" ON - find_package(Qt4 QUIET COMPONENTS QtCore QtNetwork) - CMAKE_DEPENDENT_OPTION(WITH_QT4 "Build with Qt4 support" ON - "QT4_FOUND" OFF) --find_package(Qt5 QUIET COMPONENTS Core Network) --CMAKE_DEPENDENT_OPTION(WITH_QT5 "Build with Qt5 support" ON -- "Qt5_FOUND" OFF) - 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) diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch deleted file mode 100644 index 182eacc0..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0001-THRIFT-3828-In-cmake-avoid-use-of-both-quoted-paths-.patch +++ /dev/null @@ -1,108 +0,0 @@ -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] 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 -the include path (include_directories() errors when given an empty -string). - -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 +- - test/cpp/CMakeLists.txt | 6 +++--- - tutorial/cpp/CMakeLists.txt | 2 +- - 4 files changed, 9 insertions(+), 9 deletions(-) - -diff --git a/lib/cpp/CMakeLists.txt b/lib/cpp/CMakeLists.txt -index 4c7caeb..a716ac3 100755 ---- a/lib/cpp/CMakeLists.txt -+++ b/lib/cpp/CMakeLists.txt -@@ -24,7 +24,7 @@ else() - find_package(Boost 1.53.0 REQUIRED) - endif() - --include_directories(SYSTEM "${Boost_INCLUDE_DIRS}") -+include_directories(${Boost_INCLUDE_DIRS}) - include_directories(src) - - # SYSLIBS contains libraries that need to be linked to all lib targets -@@ -104,7 +104,7 @@ if(OPENSSL_FOUND AND WITH_OPENSSL) - src/thrift/transport/TSSLSocket.cpp - src/thrift/transport/TSSLServerSocket.cpp - ) -- include_directories(SYSTEM "${OPENSSL_INCLUDE_DIR}") -+ include_directories(${OPENSSL_INCLUDE_DIR}) - list(APPEND SYSLIBS "${OPENSSL_LIBRARIES}") - endif() - -@@ -162,7 +162,7 @@ TARGET_LINK_LIBRARIES_THRIFT(thrift ${SYSLIBS}) - - if(WITH_LIBEVENT) - find_package(Libevent REQUIRED) # Libevent comes with CMake support form upstream -- include_directories(SYSTEM ${LIBEVENT_INCLUDE_DIRS}) -+ include_directories(${LIBEVENT_INCLUDE_DIRS}) - - ADD_LIBRARY_THRIFT(thriftnb ${thriftcppnb_SOURCES}) - TARGET_LINK_LIBRARIES_THRIFT(thriftnb ${SYSLIBS} ${LIBEVENT_LIBRARIES}) -@@ -171,7 +171,7 @@ endif() - - if(WITH_ZLIB) - find_package(ZLIB REQUIRED) -- include_directories(SYSTEM ${ZLIB_INCLUDE_DIRS}) -+ include_directories(${ZLIB_INCLUDE_DIRS}) - - ADD_LIBRARY_THRIFT(thriftz ${thriftcppz_SOURCES}) - TARGET_LINK_LIBRARIES_THRIFT(thriftz ${SYSLIBS} ${ZLIB_LIBRARIES}) -diff --git a/lib/cpp/test/CMakeLists.txt b/lib/cpp/test/CMakeLists.txt -index 5de9fc4..c956c38 100644 ---- a/lib/cpp/test/CMakeLists.txt -+++ b/lib/cpp/test/CMakeLists.txt -@@ -20,7 +20,7 @@ - # Find required packages - set(Boost_USE_STATIC_LIBS ON) # Force the use of static boost test framework - find_package(Boost 1.53.0 REQUIRED COMPONENTS chrono filesystem system thread unit_test_framework) --include_directories(SYSTEM "${Boost_INCLUDE_DIRS}") -+include_directories(${Boost_INCLUDE_DIRS}) - - #Make sure gen-cpp files can be included - include_directories("${CMAKE_CURRENT_BINARY_DIR}") -diff --git a/test/cpp/CMakeLists.txt b/test/cpp/CMakeLists.txt -index 2d75f2e..b1409de 100755 ---- a/test/cpp/CMakeLists.txt -+++ b/test/cpp/CMakeLists.txt -@@ -22,13 +22,13 @@ include(ThriftMacros) - - set(Boost_USE_STATIC_LIBS ON) - find_package(Boost 1.53.0 REQUIRED COMPONENTS program_options system filesystem) --include_directories(SYSTEM "${Boost_INCLUDE_DIRS}") -+include_directories(${Boost_INCLUDE_DIRS}) - - find_package(OpenSSL REQUIRED) --include_directories(SYSTEM "${OPENSSL_INCLUDE_DIR}") -+include_directories(${OPENSSL_INCLUDE_DIR}) - - find_package(Libevent REQUIRED) # Libevent comes with CMake support from upstream --include_directories(SYSTEM ${LIBEVENT_INCLUDE_DIRS}) -+include_directories(${LIBEVENT_INCLUDE_DIRS}) - - #Make sure gen-cpp files can be included - include_directories("${CMAKE_CURRENT_BINARY_DIR}") -diff --git a/tutorial/cpp/CMakeLists.txt b/tutorial/cpp/CMakeLists.txt -index 2b0c143..5ecae17 100644 ---- a/tutorial/cpp/CMakeLists.txt -+++ b/tutorial/cpp/CMakeLists.txt -@@ -18,7 +18,7 @@ - # - - find_package(Boost 1.53.0 REQUIRED) --include_directories(SYSTEM "${Boost_INCLUDE_DIRS}") -+include_directories(${Boost_INCLUDE_DIRS}) - - #Make sure gen-cpp files can be included - include_directories("${CMAKE_CURRENT_BINARY_DIR}") diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch deleted file mode 100644 index 37715c28..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0002-THRIFT-3831-in-test-cpp-explicitly-use-signed-char.patch +++ /dev/null @@ -1,38 +0,0 @@ -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] 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 - - 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 7c425a9..7145ebb 100644 ---- a/test/cpp/src/TestClient.cpp -+++ b/test/cpp/src/TestClient.cpp -@@ -381,7 +381,7 @@ int main(int argc, char** argv) { - * BINARY TEST - */ - printf("testBinary([-128..127]) = {"); -- const char bin_data[256] -+ const signed char bin_data[256] - = {-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, -@@ -402,7 +402,7 @@ int main(int argc, char** argv) { - 127}; - try { - string bin_result; -- testClient.testBinary(bin_result, string(bin_data, 256)); -+ testClient.testBinary(bin_result, string(reinterpret_cast<const char *>(bin_data), 256)); - if (bin_result.size() != 256) { - printf("}\n*** FAILED ***\n"); - printf("invalid length: %lu\n", bin_result.size()); diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch deleted file mode 100644 index 500cfab6..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0004-THRIFT-3207-enable-build-with-OpenSSL-1.1.0-series.patch +++ /dev/null @@ -1,41 +0,0 @@ -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/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0005-THRIFT-3878-Compile-error-in-TSSLSocket.cpp-with-new.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0005-THRIFT-3878-Compile-error-in-TSSLSocket.cpp-with-new.patch deleted file mode 100644 index f4482b10..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0005-THRIFT-3878-Compile-error-in-TSSLSocket.cpp-with-new.patch +++ /dev/null @@ -1,26 +0,0 @@ -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/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0006-THRIFT-3736-C++-library-build-fails-if-OpenSSL-does-.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0006-THRIFT-3736-C++-library-build-fails-if-OpenSSL-does-.patch deleted file mode 100644 index dfaa2fbd..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift-0.9.3/0006-THRIFT-3736-C++-library-build-fails-if-OpenSSL-does-.patch +++ /dev/null @@ -1,46 +0,0 @@ -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/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift/0001-DefineInstallationPaths.cmake-Define-libdir-in-terms.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift/0001-DefineInstallationPaths.cmake-Define-libdir-in-terms.patch new file mode 100644 index 00000000..485d7a4b --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift/0001-DefineInstallationPaths.cmake-Define-libdir-in-terms.patch @@ -0,0 +1,42 @@ +From a07e56e1a2e70a9b81eb0a65f345cf45a7a93a81 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Thu, 19 Dec 2019 21:56:23 -0800 +Subject: [PATCH] DefineInstallationPaths.cmake: Define libdir in terms of + LIB_SUFFIX + +Upstream-Status: Pending +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + build/cmake/DefineInstallationPaths.cmake | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/build/cmake/DefineInstallationPaths.cmake ++++ b/build/cmake/DefineInstallationPaths.cmake +@@ -22,11 +22,11 @@ + set(BIN_INSTALL_DIR "bin" CACHE PATH "The binary install dir (default: bin)") + set(LIB_INSTALL_DIR "lib${LIB_SUFFIX}" CACHE PATH "The library install dir (default: lib${LIB_SUFFIX})") + set(INCLUDE_INSTALL_DIR "include" CACHE PATH "The library install dir (default: include)") +-set(CMAKE_INSTALL_DIR "lib/cmake" CACHE PATH "The subdirectory to install cmake config files (default: cmake)") +-set(PKGCONFIG_INSTALL_DIR "lib/pkgconfig" CACHE PATH "The subdirectory to install pkgconfig config files (default: lib/pkgconfig)") ++set(CMAKE_INSTALL_DIR "lib${LIB_SUFFIX}/cmake" CACHE PATH "The subdirectory to install cmake config files (default: cmake)") ++set(PKGCONFIG_INSTALL_DIR "lib${LIB_SUFFIX}/pkgconfig" CACHE PATH "The subdirectory to install pkgconfig config files (default: lib/pkgconfig)") + set(DOC_INSTALL_DIR "share/doc" CACHE PATH "The subdirectory to install documentation files (default: share/doc)") + set(prefix "${CMAKE_INSTALL_PREFIX}") + set(exec_prefix "${CMAKE_INSTALL_PREFIX}/bin") +-set(libdir "${CMAKE_INSTALL_PREFIX}/lib") ++set(libdir "${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}") + set(includedir "${CMAKE_INSTALL_PREFIX}/include") + set(cmakedir "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DIR}") +--- a/build/cmake/DefineCMakeDefaults.cmake ++++ b/build/cmake/DefineCMakeDefaults.cmake +@@ -44,8 +44,8 @@ include(BuildType) + # top of the build tree rather than in hard-to-find leaf + # directories. This simplifies manual testing and the use of the build + # tree rather than installed thrift libraries. +-set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) +-set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) ++set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}) ++set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}) + set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) + + # diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.13.0.bb index 7ab74026..92bcb21b 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.9.3.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/thrift/thrift_0.13.0.bb @@ -3,26 +3,20 @@ DESCRIPTION = "A software framework, for scalable cross-language services devel HOMEPAGE = "https://thrift.apache.org/" LICENSE = "Apache-2.0" -LIC_FILES_CHKSUM = "file://LICENSE;md5=e4ed21f679b2aafef26eac82ab0c2cbf \ - file://NOTICE;md5=115f49498b66b494b0472658f2bfe80b" +LIC_FILES_CHKSUM = "file://LICENSE;md5=394465e125cffc0f133695ed43f14047 \ + file://NOTICE;md5=2659b43daca219f99a2f2626ea128f73" DEPENDS = "thrift-native boost flex-native bison-native openssl" -SRC_URI = "http://mirror.switch.ch/mirror/apache/dist/thrift/${PV}/${BPN}-${PV}.tar.gz \ - 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" -SRC_URI[sha256sum] = "b0740a070ac09adde04d43e852ce4c320564a292f26521c46b78e0641564969e" +SRC_URI = "https://www-eu.apache.org/dist/thrift//${PV}/${BPN}-${PV}.tar.gz \ + file://0001-DefineInstallationPaths.cmake-Define-libdir-in-terms.patch \ + " +SRC_URI[md5sum] = "38a27d391a2b03214b444cb13d5664f1" +SRC_URI[sha256sum] = "7ad348b88033af46ce49148097afe354d513c1fca7c607b59c33ebb6064b5179" BBCLASSEXTEND = "native nativesdk" -inherit pkgconfig cmake pythonnative +inherit pkgconfig cmake python3native export STAGING_INCDIR export STAGING_LIBDIR @@ -30,6 +24,7 @@ export BUILD_SYS export HOST_SYS EXTRA_OECMAKE = " \ + -DENABLE_PRECOMPILED_HEADERS=OFF \ -DBUILD_LIBRARIES=ON \ -DBUILD_COMPILER=ON \ -DBUILD_TESTING=OFF \ @@ -37,17 +32,19 @@ EXTRA_OECMAKE = " \ -DBUILD_TUTORIALS=OFF \ -DWITH_CPP=ON \ -DWITH_JAVA=OFF \ + -DWITH_PYTHON=OFF \ -DWITH_STATIC_LIB=ON \ -DWITH_SHARED_LIB=ON \ -DWITH_OPENSSL=ON \ -DWITH_QT4=OFF \ -DWITH_QT5=OFF \ + -DWITH_BOOST_FUNCTIONAL=OFF \ " -PACKAGECONFIG ??= "libevent glib python" -PACKAGECONFIG[libevent] = "-DWITH_LIBEVENT=ON,-DWITH_LIBEVENT=OFF,libevent," -PACKAGECONFIG[python] = "-DWITH_PYTHON=ON,-DWITH_PYTHON=OFF,python," -PACKAGECONFIG[glib] = "-DWITH_C_GLIB=ON,-DWITH_C_GLIB=OFF,glib-2.0 ," +PACKAGECONFIG ??= "libevent glib boost-smart-ptr" +PACKAGECONFIG[libevent] = "-DWITH_LIBEVENT=ON,-DWITH_LIBEVENT=OFF,libevent" +PACKAGECONFIG[glib] = "-DWITH_C_GLIB=ON,-DWITH_C_GLIB=OFF,glib-2.0" +PACKAGECONFIG[boost-smart-ptr] = "-DWITH_BOOST_SMART_PTR=ON,-DWITH_BOOST_SMART_PTR=OFF,boost" do_install_append () { ln -sf thrift ${D}/${bindir}/thrift-compiler @@ -56,8 +53,11 @@ do_install_append () { LEAD_SONAME = "libthrift.so.${PV}" # thrift packages -PACKAGE_BEFORE_PN = "${PN}-compiler lib${BPN}" -FILES_lib${BPN} = "${libdir}/*.so.*" +PACKAGE_BEFORE_PN = "${PN}-compiler lib${BPN} lib${BPN}z lib${BPN}nb lib${BPN}-c-glib" +FILES_lib${BPN} = "${libdir}/libthrift.so.*" +FILES_lib${BPN}z = "${libdir}/libthriftz.so.*" +FILES_lib${BPN}nb = "${libdir}/libthriftnb.so.*" +FILES_lib${BPN}-c-glib = "${libdir}/libthrift_c_glib.so.*" FILES_${PN}-compiler = "${bindir}/*" # The thrift packages just pulls in some default dependencies but is otherwise empty diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0001-Use-toolchain-from-environment-variables.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0001-Use-toolchain-from-environment-variables.patch new file mode 100644 index 00000000..9ee4a51f --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0001-Use-toolchain-from-environment-variables.patch @@ -0,0 +1,92 @@ +From 6b822b36739222d0c864249992b5d28e3ff4d948 Mon Sep 17 00:00:00 2001 +From: Adrian Friedli <adrian.friedli@husqvarnagroup.com> +Date: Mon, 3 Sep 2018 17:58:27 +0200 +Subject: [PATCH] Use toolchain from environment variables + +Upstream-Status: Submitted [https://github.com/Wi-FiTestSuite/Wi-FiTestSuite-Linux-DUT/pull/42] +Signed-off-by: Adrian Friedli <adrian.friedli@husqvarnagroup.com> +Signed-off-by: Ankit Navik <ankit.tarot@gmail.com> +--- + Makefile.inc | 7 ++++--- + WTGService/Makefile | 2 +- + console_src/Makefile | 2 +- + lib/Makefile | 6 +++--- + 4 files changed, 9 insertions(+), 8 deletions(-) + +diff --git a/Makefile.inc b/Makefile.inc +index b0edf5a..0094bdf 100644 +--- a/Makefile.inc ++++ b/Makefile.inc +@@ -13,14 +13,15 @@ + # NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE + # USE OR PERFORMANCE OF THIS SOFTWARE. + # +-CC = gcc ++CC ?= gcc ++AR ?= ar + LIB=lib + DUT=dut + CA=ca + UCC=ucc + CON=console_src + WTG=WTGService +-MAKE=make ++MAKE?=make + + # This is for WMM-PS + #for Ext TG +@@ -46,7 +47,7 @@ CFLAGS = -g -O2 -D_REENTRANT -Wall -I../inc + + DUTLIBS = ../lib/libwfa_dut.a -lpthread + CALIBS = ../lib/libwfa_ca.a -lpthread +-RANLIB = ranlib ++RANLIB ?= ranlib + + LIBWFA_NAME_DUT = libwfa_dut.a + LIBWFA_NAME_CA = libwfa_ca.a +diff --git a/WTGService/Makefile b/WTGService/Makefile +index 5312eb6..4855771 100644 +--- a/WTGService/Makefile ++++ b/WTGService/Makefile +@@ -13,7 +13,7 @@ + # NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE + # USE OR PERFORMANCE OF THIS SOFTWARE. + # +-CC=gcc ++CC?=gcc + CFLAGS= -Wall + LIB=-lpthread + +diff --git a/console_src/Makefile b/console_src/Makefile +index 8282283..d1098eb 100644 +--- a/console_src/Makefile ++++ b/console_src/Makefile +@@ -14,7 +14,7 @@ + # USE OR PERFORMANCE OF THIS SOFTWARE. + # + +-CC = gcc ++CC ?= gcc + CFLAGS = -g -DWFA_DEBUG -pthread + + TARGETS = wfa_con +diff --git a/lib/Makefile b/lib/Makefile +index ffcef94..299b8d6 100644 +--- a/lib/Makefile ++++ b/lib/Makefile +@@ -17,9 +17,9 @@ + include ../Makefile.inc + + all: ${LIB_OBJS} +- ar crv ${LIBWFA_NAME} $? +- ar crv ${LIBWFA_NAME_DUT} ${LIB_OBJS_DUT} +- ar crv ${LIBWFA_NAME_CA} ${LIB_OBJS_CA} ++ $(AR) crv ${LIBWFA_NAME} $? ++ $(AR) crv ${LIBWFA_NAME_DUT} ${LIB_OBJS_DUT} ++ $(AR) crv ${LIBWFA_NAME_CA} ${LIB_OBJS_CA} + ${RANLIB} ${LIBWFA_NAME} ${LIBWFA_NAME_DUT} ${LIBWFA_NAME_CA} + + wfa_tg.o: wfa_tg.c ../inc/wfa_agt.h ../inc/wfa_types.h ../inc/wfa_rsp.h ../inc/wfa_tlv.h ../inc/wfa_tg.h +-- +2.7.4 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0002-Add-missing-include-removes-unnedded-stuff-and-add-n.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0002-Add-missing-include-removes-unnedded-stuff-and-add-n.patch new file mode 100644 index 00000000..20fb6473 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0002-Add-missing-include-removes-unnedded-stuff-and-add-n.patch @@ -0,0 +1,45 @@ +From 451b162c903a1ef070a75dc18171620f3beef7b3 Mon Sep 17 00:00:00 2001 +From: Ankit Navik <ankit.tarot@gmail.com> +Date: Tue, 25 Dec 2018 00:36:59 +0530 +Subject: [PATCH 2/3] Add missing include, removes unnedded stuff and add non + glibc rpc + +Upstream-Status: Inappropriate [embedded specific] + +Signed-off-by: Reto Schneider <code@reto-schneider.ch> +Signed-off-by: Ankit Navik <ankit.tarot@gmail.com> +--- + Makefile | 2 +- + inc/wfa_tg.h | 3 +++ + 2 files changed, 4 insertions(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 2c41a17..5c4ad8c 100644 +--- a/Makefile ++++ b/Makefile +@@ -15,7 +15,7 @@ + # + include Makefile.inc + +-DIRS= ${LIB} ${DUT} ${CA} ${TC} ${WTG} ${CON} ++DIRS= ${LIB} ${DUT} ${CA} ${TC} + + all: + for i in ${DIRS}; do \ +diff --git a/inc/wfa_tg.h b/inc/wfa_tg.h +index 799bf9f..a1804dd 100644 +--- a/inc/wfa_tg.h ++++ b/inc/wfa_tg.h +@@ -24,6 +24,9 @@ + #ifndef _WFA_TG_H + #define _WFA_TG_H + ++#ifndef _WINDOWS ++#include <pthread.h> ++#endif + #include <sys/time.h> + + /* maximum number of streams to support */ +-- +2.7.4 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0003-fix-path-to-usr-sbin-for-script-and-make-script-for-.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0003-fix-path-to-usr-sbin-for-script-and-make-script-for-.patch new file mode 100644 index 00000000..a51302a0 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0003-fix-path-to-usr-sbin-for-script-and-make-script-for-.patch @@ -0,0 +1,58 @@ +From fc7b7106dd0d8d123f20cbd8d408637fbc315e17 Mon Sep 17 00:00:00 2001 +From: Ankit Navik <ankit.tarot@gmail.com> +Date: Tue, 25 Dec 2018 01:12:32 +0530 +Subject: [PATCH 3/3] fix path to /usr/sbin for script and make script for + generic shell + +Signed-off-by: Ankit Navik <ankit.tarot@gmail.com> +--- + lib/wfa_cs.c | 4 ++-- + scripts/dev_send_frame | 2 +- + scripts/sta_reset_parm | 2 +- + 3 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/lib/wfa_cs.c b/lib/wfa_cs.c +index 6b1f5a2..2a18533 100644 +--- a/lib/wfa_cs.c ++++ b/lib/wfa_cs.c +@@ -319,7 +319,7 @@ int wfaStaGetIpConfig(int len, BYTE *caCmdBuf, int *respLen, BYTE *respBuf) + /* + * check a script file (the current implementation specific) + */ +- ret = access("/usr/local/sbin/getipconfig.sh", F_OK); ++ ret = access("/usr/sbin/getipconfig.sh", F_OK); + if(ret == -1) + { + ipconfigResp->status = STATUS_ERROR; +@@ -2115,7 +2115,7 @@ int wfaStaPresetParams(int len, BYTE *caCmdBuf, int *respLen, BYTE *respBuf) + st = remove("/tmp/processid.txt"); + } + +- sprintf(cmdStr, "/usr/local/sbin/findprocess.sh %s /tmp/processid.txt\n", "wpa_supplicant"); ++ sprintf(cmdStr, "/usr/sbin/findprocess.sh %s /tmp/processid.txt\n", "wpa_supplicant"); + st = system(cmdStr); + + tmpfd = fopen("/tmp/processid.txt", "r+"); +diff --git a/scripts/dev_send_frame b/scripts/dev_send_frame +index 9e6afd3..3c37d61 100644 +--- a/scripts/dev_send_frame ++++ b/scripts/dev_send_frame +@@ -1,4 +1,4 @@ +-#!/bin/bash ++#!/usr/bin/env sh + + # + # Copyright (c) 2016 Wi-Fi Alliance +diff --git a/scripts/sta_reset_parm b/scripts/sta_reset_parm +index 2aff1f1..2c1c31e 100644 +--- a/scripts/sta_reset_parm ++++ b/scripts/sta_reset_parm +@@ -1,4 +1,4 @@ +-#!/bin/bash ++#!/usr/bin/env sh + + # + # Copyright (c) 2016 Wi-Fi Alliance +-- +2.7.4 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0004-run-ranlib-per-library-and-use-AR.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0004-run-ranlib-per-library-and-use-AR.patch new file mode 100644 index 00000000..40af4897 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/files/0004-run-ranlib-per-library-and-use-AR.patch @@ -0,0 +1,38 @@ +From cca2f9901fb4fdcdd49066fe434eae512964143f Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Sat, 9 Feb 2019 07:59:47 -0800 +Subject: [PATCH 4/4] run ranlib per library and use AR + +Use AR variable to invoke archiver instead of hardcoding, helps cross +compile + +compiler ranlib e.g. llvm-ranlib fails to operate on multiple archives +on single invocation + +fixes errors like +arm-yoe-linux-musleabi-llvm-ranlib: error: Exactly one archive should be specified. + +Upstream-Status: Submitted [https://github.com/Wi-FiTestSuite/Wi-FiTestSuite-Linux-DUT/pull/47] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + lib/Makefile | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/lib/Makefile b/lib/Makefile +index 299b8d6..5fca322 100644 +--- a/lib/Makefile ++++ b/lib/Makefile +@@ -20,7 +20,9 @@ all: ${LIB_OBJS} + $(AR) crv ${LIBWFA_NAME} $? + $(AR) crv ${LIBWFA_NAME_DUT} ${LIB_OBJS_DUT} + $(AR) crv ${LIBWFA_NAME_CA} ${LIB_OBJS_CA} +- ${RANLIB} ${LIBWFA_NAME} ${LIBWFA_NAME_DUT} ${LIBWFA_NAME_CA} ++ ${RANLIB} ${LIBWFA_NAME} ++ ${RANLIB} ${LIBWFA_NAME_DUT} ++ ${RANLIB} ${LIBWFA_NAME_CA} + + wfa_tg.o: wfa_tg.c ../inc/wfa_agt.h ../inc/wfa_types.h ../inc/wfa_rsp.h ../inc/wfa_tlv.h ../inc/wfa_tg.h + +-- +2.20.1 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/wifi-test-suite_git.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/wifi-test-suite_git.bb new file mode 100644 index 00000000..99cfb320 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wifi-test-suite/wifi-test-suite_git.bb @@ -0,0 +1,38 @@ +SUMMARY = "Wi-Fi Test Suite Linux Control Agent" +DESCRIPTION = "Wi-Fi Test Suite is a software platform originally developed \ +by Wi-Fi Alliance, the global non-profit industry association that brings you \ +Wi-Fi, to support certification program development and device certification." +HOMEPAGE = "https://www.wi-fi.org/certification/wi-fi-test-suite" +LICENSE = "ISC" +LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=0542427ed5c315ca34aa09ae7a85ed32" +SECTION = "test" + +S = "${WORKDIR}/git" +SRCREV = "f7a8d7ef7d1a831c1bb47de21fa083536ea2f3a9" +SRC_URI = "git://github.com/Wi-FiTestSuite/Wi-FiTestSuite-Linux-DUT.git \ + file://0001-Use-toolchain-from-environment-variables.patch \ + file://0002-Add-missing-include-removes-unnedded-stuff-and-add-n.patch \ + file://0003-fix-path-to-usr-sbin-for-script-and-make-script-for-.patch \ + file://0004-run-ranlib-per-library-and-use-AR.patch \ +" + +# to avoid host path QA error +CFLAGS += "-I${STAGING_INCDIR}/tirpc" +# Fix GNU HASH error +TARGET_CC_ARCH += "${LDFLAGS}" + +do_install () { + install -d ${D}${libdir} + install -m 0644 ${S}/lib/libwfa.a ${D}${libdir} + install -m 0644 ${S}/lib/libwfa_ca.a ${D}${libdir} + install -m 0644 ${S}/lib/libwfa_dut.a ${D}${libdir} + install -d ${D}${sbindir} + install -m 0755 ${S}/dut/wfa_dut ${D}${sbindir} + install -m 0755 ${S}/ca/wfa_ca ${D}${sbindir} + install -m 0755 ${S}/scripts/*.sh ${D}${sbindir} + install -m 0755 ${S}/scripts/arp_neigh_loop ${D}${sbindir} + install -m 0755 ${S}/scripts/dev_send_frame ${D}${sbindir} + install -m 0755 ${S}/scripts/sta_reset_parm ${D}${sbindir} +} + +RDEPENDS_${PN} = "wpa-supplicant" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial/musl-support.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial/musl-support.patch new file mode 100644 index 00000000..b5ad4823 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial/musl-support.patch @@ -0,0 +1,25 @@ +Drop support for glibc < 2.10, in master we are at 2.28 +in process get it working with musl as well. + +Upstream-Status: Inappropriate [No upstream] + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- a/wvmodemscan.cc ++++ b/wvmodemscan.cc +@@ -495,16 +495,8 @@ static int fileselect(const struct diren + // (no internal ISDN support) || !strncmp(e->d_name, "ttyI", 4); + } + +-#if defined(__GLIBC__) && __GLIBC_PREREQ(2, 10) + static int filesort(const dirent **e1, const dirent **e2) +-#else +-static int filesort(const void *_e1, const void *_e2) +-#endif + { +-#if !(defined(__GLIBC__) && __GLIBC_PREREQ(2, 10)) +- dirent const * const *e1 = (dirent const * const *)_e1; +- dirent const * const *e2 = (dirent const * const *)_e2; +-#endif + const char *p1, *p2; + int diff; + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb index 51542081..b985d39a 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvdial_1.61.bb @@ -11,18 +11,17 @@ RDEPENDS_${PN} = "ppp" SRC_URI = "http://${BPN}.googlecode.com/files/${BP}.tar.bz2 \ file://typo_pon.wvdial.1.patch \ + file://musl-support.patch \ " - SRC_URI[md5sum] = "37e9a2d664effe4efd44c0e1a20136de" SRC_URI[sha256sum] = "99906d9560cbdbc97e1855e7b0a7169f1e11983be3ac539140423f09debced82" +COMPATIBLE_HOST_libc-musl = "null" EXTRA_OEMAKE = "" export WVLINK="${LD}" PARALLEL_MAKE = "" -BUILD_CPPFLAGS += "-I${STAGING_INCDIR}/wvstreams" - do_configure() { sed -i 's/LDFLAGS+=-luniconf/LIBS+=-luniconf/' ${S}/Makefile } @@ -30,5 +29,3 @@ do_configure() { 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/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Fix-narrowing-conversion-error.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Fix-narrowing-conversion-error.patch new file mode 100644 index 00000000..fc9abd8e --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Fix-narrowing-conversion-error.patch @@ -0,0 +1,29 @@ +From c86c524f951f6e973473bfee76fd5366368b2cbc Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Wed, 25 Dec 2019 09:32:41 -0800 +Subject: [PATCH] Fix narrowing conversion error + +xplc/moduleloader.cc: In static member function 'static Module* Module::loadModule(const char*)': xplc/moduleloader.cc:67:14: error: narrowing conversion of '-1' from 'int' to 'unsigned int' [-Wnarrowing] 67 | case (int)-1: | ^ + +Upstream-Status: Pending +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + xplc/moduleloader.cc | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/xplc/moduleloader.cc b/xplc/moduleloader.cc +index 02dd9a4..c53f5d2 100644 +--- a/xplc/moduleloader.cc ++++ b/xplc/moduleloader.cc +@@ -62,7 +62,7 @@ Module* Module::loadModule(const char* modulename) { + return NULL; + } + +- switch(moduleinfo->version_major) { ++ switch((int)moduleinfo->version_major) { + #ifdef UNSTABLE + case -1: + /* nothing to do */ +-- +2.24.1 + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0002-wvtask-Dont-use-ucontext-on-non-glibc-systems.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0002-wvtask-Dont-use-ucontext-on-non-glibc-systems.patch deleted file mode 100644 index 232db9e6..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams/0002-wvtask-Dont-use-ucontext-on-non-glibc-systems.patch +++ /dev/null @@ -1,135 +0,0 @@ -From 0e054339c1422168a7f4a9dcf090268053a33b1f Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Thu, 20 Jul 2017 21:05:37 -0700 -Subject: [PATCH 2/5] wvtask: Dont use ucontext on non-glibc systems - -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - utils/wvtask.cc | 24 ++++++++++++++++++++++++ - 1 file changed, 24 insertions(+) - -diff --git a/utils/wvtask.cc b/utils/wvtask.cc -index cdcd544..c0bff7d 100644 ---- a/utils/wvtask.cc -+++ b/utils/wvtask.cc -@@ -199,7 +199,9 @@ WvTaskMan::WvTaskMan() - stacktop = (char *)alloca(0); - - context_return = 0; -+#ifdef __GLIBC__ - assert(getcontext(&get_stack_return) == 0); -+#endif - if (context_return == 0) - { - // initial setup - start the stackmaster() task (never returns!) -@@ -265,13 +267,17 @@ int WvTaskMan::run(WvTask &task, int val) - state = &old_task->mystate; - - context_return = 0; -+#ifdef __GLIBC__ - assert(getcontext(state) == 0); -+#endif - int newval = context_return; - if (newval == 0) - { - // saved the state, now run the task. - context_return = val; -+#ifdef __GLIBC__ - setcontext(&task.mystate); -+#endif - return -1; - } - else -@@ -319,13 +325,17 @@ int WvTaskMan::yield(int val) - #endif - - context_return = 0; -+#ifdef __GLIBC__ - assert(getcontext(¤t_task->mystate) == 0); -+#endif - int newval = context_return; - if (newval == 0) - { - // saved the task state; now yield to the toplevel. - context_return = val; -+#ifdef __GLIBC__ - setcontext(&toplevel); -+#endif - return -1; - } - else -@@ -341,7 +351,9 @@ int WvTaskMan::yield(int val) - void WvTaskMan::get_stack(WvTask &task, size_t size) - { - context_return = 0; -+#ifdef __GLIBC__ - assert(getcontext(&get_stack_return) == 0); -+#endif - if (context_return == 0) - { - assert(magic_number == -WVTASK_MAGIC); -@@ -371,7 +383,9 @@ void WvTaskMan::get_stack(WvTask &task, size_t size) - // initial setup - stack_target = &task; - context_return = size/1024 + (size%1024 > 0); -+#ifdef __GLIBC__ - setcontext(&stackmaster_task); -+#endif - } - else - { -@@ -409,7 +423,9 @@ void WvTaskMan::_stackmaster() - assert(magic_number == -WVTASK_MAGIC); - - context_return = 0; -+#ifdef __GLIBC__ - assert(getcontext(&stackmaster_task) == 0); -+#endif - val = context_return; - if (val == 0) - { -@@ -419,7 +435,9 @@ void WvTaskMan::_stackmaster() - // all current stack allocations) and go back to get_stack - // (or the constructor, if that's what called us) - context_return = 1; -+#ifdef __GLIBC__ - setcontext(&get_stack_return); -+#endif - } - else - { -@@ -474,7 +492,9 @@ void WvTaskMan::do_task() - - // back here from longjmp; someone wants stack space. - context_return = 0; -+#ifdef __GLIBC__ - assert(getcontext(&task->mystate) == 0); -+#endif - if (context_return == 0) - { - // done the setjmp; that means the target task now has -@@ -510,7 +530,9 @@ void WvTaskMan::do_task() - } - else - { -+#ifdef __GLIBC__ - assert(getcontext(&task->func_call) == 0); -+#endif - task->func_call.uc_stack.ss_size = task->stacksize; - task->func_call.uc_stack.ss_sp = task->stack; - task->func_call.uc_stack.ss_flags = 0; -@@ -521,9 +543,11 @@ void WvTaskMan::do_task() - (void (*)(void))call_func, 1, task); - - context_return = 0; -+#ifdef __GLIBC__ - assert(getcontext(&task->func_return) == 0); - if (context_return == 0) - setcontext(&task->func_call); -+#endif - } - - // the task's function terminated. --- -2.13.3 - diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb index b9f62da7..20becaf5 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb @@ -15,7 +15,6 @@ SRC_URI = "http://${BPN}.googlecode.com/files/${BP}.tar.gz \ file://gcc-6.patch \ file://argp.patch \ file://0001-Check-for-limits.h-during-configure.patch \ - file://0002-wvtask-Dont-use-ucontext-on-non-glibc-systems.patch \ file://0003-wvtask-Check-for-HAVE_LIBC_STACK_END-only-on-glibc-s.patch \ file://0004-wvcrash-Replace-use-of-basename-API.patch \ file://0005-check-for-libexecinfo-during-configure.patch \ @@ -23,11 +22,14 @@ SRC_URI = "http://${BPN}.googlecode.com/files/${BP}.tar.gz \ file://0002-wvrules.mk-Use-_DEFAULT_SOURCE.patch \ file://openssl-buildfix.patch \ file://0001-Forward-port-to-OpenSSL-1.1.x.patch \ + file://0001-Fix-narrowing-conversion-error.patch \ " SRC_URI[md5sum] = "2760dac31a43d452a19a3147bfde571c" SRC_URI[sha256sum] = "8403f5fbf83aa9ac0c6ce15d97fd85607488152aa84e007b7d0621b8ebc07633" +COMPATIBLE_HOST_libc-musl = "null" + inherit autotools-brokensep pkgconfig TARGET_CFLAGS_append = " -fno-tree-dce -fno-optimize-sibling-calls" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix/zabbix-agent.service b/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix/zabbix-agent.service index b18a96f8..56e50642 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix/zabbix-agent.service +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix/zabbix-agent.service @@ -3,9 +3,8 @@ Description=Zabbix Monitor Agent After=syslog.target network.target [Service] -Type=oneshot -ExecStart=@SBINDIR@/zabbix_agentd -RemainAfterExit=yes +Type=simple +ExecStart=@SBINDIR@/zabbix_agentd -f User=zabbix [Install] diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix_3.0.9.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix_4.4.6.bb index bab5a6ae..0e0ddd57 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix_3.0.9.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/zabbix/zabbix_4.4.6.bb @@ -19,7 +19,7 @@ HOMEPAGE = "http://www.zabbix.com/" SECTION = "Applications/Internet" LICENSE = "GPLv2+" LIC_FILES_CHKSUM = "file://COPYING;md5=300e938ad303147fede2294ed78fe02e" -DEPENDS = "openldap virtual/libiconv" +DEPENDS = "libevent libpcre openldap virtual/libiconv zlib" PACKAGE_ARCH = "${MACHINE_ARCH}" @@ -28,8 +28,8 @@ SRC_URI = "http://jaist.dl.sourceforge.net/project/zabbix/ZABBIX%20Latest%20Stab file://zabbix-agent.service \ " -SRC_URI[md5sum] = "489d21b464277c0d412155c7e5611a8f" -SRC_URI[sha256sum] = "4445f26c025009681c29c9b350aa6c4ee7b124ddcaf1609ae36c55997bcb8cf2" +SRC_URI[md5sum] = "e666539220be93b1af38e40f5fbb1f79" +SRC_URI[sha256sum] = "22bb28e667424ad4688f47732853f4241df0e78a7607727b043d704ba726ae0e" inherit autotools-brokensep linux-kernel-base pkgconfig systemd useradd @@ -51,12 +51,15 @@ EXTRA_OECONF = " \ --enable-ipv6 \ --with-net-snmp \ --with-ldap=${STAGING_EXECPREFIXDIR} \ - --with-jabber \ --with-unixodbc \ --with-ssh2 \ --with-sqlite3 \ + --with-zlib \ + --with-libpthread \ + --with-libevent \ + --with-libpcre \ " -CFLAGS_append = " -lldap -llber" +CFLAGS_append = " -lldap -llber -pthread" do_configure_prepend() { export KERNEL_VERSION="${KERNEL_VERSION}" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb index 9aff59c6..0b66970a 100644 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/cppzmq_git.bb @@ -4,8 +4,8 @@ LICENSE = "MIT" LIC_FILES_CHKSUM = "file://LICENSE;md5=db174eaf7b55a34a7c89551197f66e94" DEPENDS = "zeromq" -SRCREV = "6aa3ab686e916cb0e62df7fa7d12e0b13ae9fae6" -PV = "4.2.3+git${SRCPV}" +SRCREV = "8d5c9a88988dcbebb72939ca0939d432230ffde1" +PV = "4.6.0" SRC_URI = "git://github.com/zeromq/cppzmq.git" @@ -13,6 +13,8 @@ S = "${WORKDIR}/git" inherit cmake +EXTRA_OECMAKE = "-DCPPZMQ_BUILD_TESTS=OFF" + PACKAGES = "${PN}-dev" RDEPENDS_${PN}-dev = "zeromq-dev" diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/czmq_4.2.0.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/czmq_4.2.0.bb new file mode 100644 index 00000000..7c9a33e8 --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/czmq_4.2.0.bb @@ -0,0 +1,32 @@ +DESCRIPTION = "High-level C binding for 0MQ" +HOMEPAGE = "http://czmq.zeromq.org/" +LICENSE = "MPL-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=9741c346eef56131163e13b9db1241b3" +DEPENDS = "zeromq" + +SRC_URI = "https://github.com/zeromq/czmq/releases/download/v${PV}/czmq-${PV}.tar.gz" + +SRC_URI[md5sum] = "7e09997db6ac3b25e8ed104053040722" +SRC_URI[sha256sum] = "cfab29c2b3cc8a845749758a51e1dd5f5160c1ef57e2a41ea96e4c2dcc8feceb" + +UPSTREAM_CHECK_URI = "https://github.com/zeromq/${BPN}/releases" + +inherit cmake + +PACKAGES = "lib${BPN} lib${BPN}-dev lib${BPN}-staticdev ${PN} ${PN}-dbg" + +FILES_${PN} = "${bindir}/*" +FILES_lib${BPN} = "${libdir}/*.so.*" +FILES_lib${BPN}-dev = "${libdir}/*.so ${libdir}/pkgconfig ${includedir} ${datadir}/cmake" +FILES_lib${BPN}-staticdev = "${libdir}/lib*.a" + +RDEPENDS_lib${BPN}-dev = "zeromq-dev" + +PACKAGECONFIG ??= "lz4 uuid curl ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" +PACKAGECONFIG[lz4] = ",-DCMAKE_DISABLE_FIND_PACKAGE_lz4=TRUE,lz4" +PACKAGECONFIG[uuid] = ",-DCMAKE_DISABLE_FIND_PACKAGE_uuid=TRUE,util-linux" +PACKAGECONFIG[curl] = ",-DCMAKE_DISABLE_FIND_PACKAGE_libcurl=TRUE,curl" +PACKAGECONFIG[systemd] = ",-DCMAKE_DISABLE_FIND_PACKAGE_systemd=TRUE,systemd" + +BBCLASSEXTEND = "nativesdk" + diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/files/0001-CMakeLists-txt-Avoid-host-specific-path-to-libsodium.patch b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/files/0001-CMakeLists-txt-Avoid-host-specific-path-to-libsodium.patch new file mode 100644 index 00000000..eb3dee4d --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/files/0001-CMakeLists-txt-Avoid-host-specific-path-to-libsodium.patch @@ -0,0 +1,39 @@ +From: Niko Mauno <niko.mauno@vaisala.com> +Date: Wed Apr 22 09:00:00 2020 +0300 +Subject: CMakeLists.txt: Avoid host-specific path to libsodium + +Avoid propagating full build host specific path to generated +ZeroMQTargets.cmake when building with libsodium, which changes the +content in generated ZeroMQTargets.cmake files followingly: + + -INTERFACE_LINK_LIBRARIES "-lpthread;/build/host/specific/path/to/zeromq/4.3.2-r0/recipe-sysroot/usr/lib/libsodium.so;-lrt" + +INTERFACE_LINK_LIBRARIES "-lpthread;-lsodium;-lrt" + +This change mitigates an issue stemming from reuse of build artifacts +where the path to libsodium.so does not match exactly between two +different build hosts. + +Upstream-Status: Pending + +Signed-off-by: Niko Mauno <niko.mauno@vaisala.com> + +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1210,7 +1210,7 @@ + target_link_libraries(libzmq ${OPTIONAL_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT}) + + if(SODIUM_FOUND) +- target_link_libraries(libzmq ${SODIUM_LIBRARIES}) ++ target_link_libraries(libzmq -lsodium) + # On Solaris, libsodium depends on libssp + if(${CMAKE_SYSTEM_NAME} MATCHES "SunOS") + target_link_libraries(libzmq ssp) +@@ -1240,7 +1240,7 @@ + target_link_libraries(libzmq-static ${OPTIONAL_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT}) + + if(SODIUM_FOUND) +- target_link_libraries(libzmq-static ${SODIUM_LIBRARIES}) ++ target_link_libraries(libzmq-static -lsodium) + # On Solaris, libsodium depends on libssp + if(${CMAKE_SYSTEM_NAME} MATCHES "SunOS") + target_link_libraries(libzmq-static ssp) diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/zeromq_4.2.5.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/zeromq_4.2.5.bb deleted file mode 100644 index 356348b4..00000000 --- a/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/zeromq_4.2.5.bb +++ /dev/null @@ -1,32 +0,0 @@ -DESCRIPTION = "ZeroMQ looks like an embeddable networking library but acts like a concurrency framework" -HOMEPAGE = "http://www.zeromq.org" -LICENSE = "LGPLv3+" -LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=d5311495d952062e0e4fbba39cbf3de1" - -PACKAGECONFIG ??= "libsodium" -PACKAGECONFIG[libsodium] = "--with-libsodium, --without-libsodium, libsodium" - -SRC_URI = "http://github.com/zeromq/libzmq/releases/download/v${PV}/zeromq-${PV}.tar.gz \ - file://run-ptest \ -" -SRC_URI[md5sum] = "a1c95b34384257e986842f4d006957b8" -SRC_URI[sha256sum] = "cc9090ba35713d59bb2f7d7965f877036c49c5558ea0c290b0dcc6f2a17e489f" - -S = "${WORKDIR}/zeromq-${PV}" - -#Uncomment to choose polling system manually. valid values are kqueue, epoll, devpoll, poll or select -#EXTRA_OECONF += "--with-poller=kqueue" -#CFLAGS_append = " -O0" -#CXXFLAGS_append = " -O0" - -inherit autotools ptest pkgconfig - -do_compile_ptest () { - echo 'buildtest-TESTS: $(check_PROGRAMS)' >> ${B}/Makefile - oe_runmake buildtest-TESTS -} - -do_install_ptest () { - install -d ${D}${PTEST_PATH}/tests - install -m 0755 ${B}/tests/.libs/test_* ${D}${PTEST_PATH}/tests -} diff --git a/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/zeromq_4.3.2.bb b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/zeromq_4.3.2.bb new file mode 100644 index 00000000..02a4c04f --- /dev/null +++ b/external/meta-openembedded/meta-oe/recipes-connectivity/zeromq/zeromq_4.3.2.bb @@ -0,0 +1,29 @@ +DESCRIPTION = "ZeroMQ looks like an embeddable networking library but acts like a concurrency framework" +HOMEPAGE = "http://www.zeromq.org" +LICENSE = "LGPLv3+" +LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=d5311495d952062e0e4fbba39cbf3de1" + +PACKAGECONFIG ??= "libsodium" +PACKAGECONFIG[libsodium] = "-DWITH_LIBSODIUM=ON,-DWITH_LIBSODIUM=OFF, libsodium" + +SRC_URI = "http://github.com/zeromq/libzmq/releases/download/v${PV}/zeromq-${PV}.tar.gz \ + file://0001-CMakeLists-txt-Avoid-host-specific-path-to-libsodium.patch \ + file://run-ptest \ +" +SRC_URI[md5sum] = "2047e917c2cc93505e2579bcba67a573" +SRC_URI[sha256sum] = "ebd7b5c830d6428956b67a0454a7f8cbed1de74b3b01e5c33c5378e22740f763" + +UPSTREAM_CHECK_URI = "https://github.com/${BPN}/libzmq/releases" + +inherit cmake ptest pkgconfig + +EXTRA_OECMAKE = "${@bb.utils.contains('PTEST_ENABLED', '1', '-DBUILD_TESTS=ON', '-DBUILD_TESTS=OFF', d)} \ + -DCMAKE_SKIP_RPATH=ON \ +" + +do_install_ptest () { + install -d ${D}${PTEST_PATH}/tests + install -m 0755 ${B}/bin/test_* ${D}${PTEST_PATH}/tests +} + +FILES_${PN}-doc += "${datadir}/zmq/*.txt" |