Date   

[meta-oe][PATCH] polkit: update patches for musl compilation

Marta Rybczynska
 

Update the patch to make netgroup support optional to fit the commit
merged upstream [1], update the other patch depending on one of the
changes.

Without this update, a compilation using duktape with musl fails with:
| ../../../polkit-0.119/src/polkitbackend/polkitbackendduktapeauthority.c: In function 'js_polkit_user_is_in_netgroup':
| ../../../polkit-0.119/src/polkitbackend/polkitbackendduktapeauthority.c:1039:7: warning: implicit declaration of function 'innetgr' [-Wimplicit-function-declaration]
| 1039 | if (innetgr (netgroup,
| | ^~~~~~~

The main patch has been split in two, to apply the duktape part only when duktape is
applied.

[1] https://gitlab.freedesktop.org/polkit/polkit/-/commit/b57deee8178190a7ecc75290fa13cf7daabc2c66

Signed-off-by: Marta Rybczynska <marta.rybczynska@...>
---
...ded-support-for-duktape-as-JS-engine.patch | 20 ++--
...0004-Make-netgroup-support-optional.patch} | 103 +++++++++---------
...ke-netgroup-support-optional-duktape.patch | 34 ++++++
.../recipes-extended/polkit/polkit_0.119.bb | 4 +-
4 files changed, 98 insertions(+), 63 deletions(-)
rename meta-oe/recipes-extended/polkit/polkit/{0003-make-netgroup-support-optional.patch => 0004-Make-netgroup-support-optional.patch} (74%)
create mode 100644 meta-oe/recipes-extended/polkit/polkit/0005-Make-netgroup-support-optional-duktape.patch

diff --git a/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch b/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
index e44e4f6e4..b8562f8ce 100644
--- a/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
+++ b/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
@@ -1,15 +1,18 @@
-From eaecfb21e1bca42e99321cc731e21dbfc1ea0d0c Mon Sep 17 00:00:00 2001
+From 4af72493cb380ab5ce0dd7c5bcd25a8b5457d770 Mon Sep 17 00:00:00 2001
From: Gustavo Lima Chaves <limachaves@...>
Date: Tue, 25 Jan 2022 09:43:21 +0000
-Subject: [PATCH 3/3] Added support for duktape as JS engine
+Subject: [PATCH] Added support for duktape as JS engine

Original author: Wu Xiaotian (@yetist)
Resurrection author, runaway-killer author: Gustavo Lima Chaves (@limachaves)

Signed-off-by: Mikko Rapeli <mikko.rapeli@...>

+Upstream-Status: Backport [c7fc4e1b61f0fd82fc697c19c604af7e9fb291a2]
+Dropped change to .gitlab-ci.yml and adapted configure.ac due to other
+patches in meta-oe.
+
---
- .gitlab-ci.yml | 1 +
buildutil/ax_pthread.m4 | 522 ++++++++
configure.ac | 34 +-
docs/man/polkit.xml | 4 +-
@@ -23,16 +26,12 @@ Signed-off-by: Mikko Rapeli <mikko.rapeli@...>
.../polkitbackendjsauthority.cpp | 721 +----------
.../etc/polkit-1/rules.d/10-testing.rules | 6 +-
.../test-polkitbackendjsauthority.c | 2 +-
- 14 files changed, 2399 insertions(+), 678 deletions(-)
+ 13 files changed, 2398 insertions(+), 678 deletions(-)
create mode 100644 buildutil/ax_pthread.m4
create mode 100644 src/polkitbackend/polkitbackendcommon.c
create mode 100644 src/polkitbackend/polkitbackendcommon.h
create mode 100644 src/polkitbackend/polkitbackendduktapeauthority.c

-Upstream-Status: Backport [c7fc4e1b61f0fd82fc697c19c604af7e9fb291a2]
-Dropped change to .gitlab-ci.yml and adapted configure.ac due to other
-patches in meta-oe.
-
diff --git a/buildutil/ax_pthread.m4 b/buildutil/ax_pthread.m4
new file mode 100644
index 0000000..9f35d13
@@ -603,7 +602,7 @@ index b625743..bbf4768 100644
+CC="$PTHREAD_CC"
+AC_CHECK_FUNCS([pthread_condattr_setclock])
+
- AC_CHECK_FUNCS(clearenv fdatasync setnetgrent)
+ AC_CHECK_FUNCS(clearenv fdatasync)

if test "x$GCC" = "xyes"; then
@@ -581,6 +598,13 @@ echo "
@@ -3458,6 +3457,3 @@ index f97e0e0..2103b17 100644
},

{
---
-2.20.1
-
diff --git a/meta-oe/recipes-extended/polkit/polkit/0003-make-netgroup-support-optional.patch b/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch
similarity index 74%
rename from meta-oe/recipes-extended/polkit/polkit/0003-make-netgroup-support-optional.patch
rename to meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch
index 1a268f2d0..fa273d450 100644
--- a/meta-oe/recipes-extended/polkit/polkit/0003-make-netgroup-support-optional.patch
+++ b/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch
@@ -1,36 +1,43 @@
-From 0c1debb380fee7f5b2bc62406e45856dc9c9e1a1 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@...>
-Date: Wed, 22 May 2019 13:18:55 -0700
-Subject: [PATCH] make netgroup support optional
+From 7ef2621ab7adcedc099ed39acfb73c6fa835cbc3 Mon Sep 17 00:00:00 2001
+From: "A. Wilcox" <AWilcox@...>
+Date: Sun, 15 May 2022 05:04:10 +0000
+Subject: [PATCH] Make netgroup support optional

-On at least Linux/musl and Linux/uclibc, netgroup
-support is not available. PolKit fails to compile on these systems
-for that reason.
+On at least Linux/musl and Linux/uclibc, netgroup support is not
+available. PolKit fails to compile on these systems for that reason.

This change makes netgroup support conditional on the presence of the
setnetgrent(3) function which is required for the support to work. If
that function is not available on the system, an error will be returned
to the administrator if unix-netgroup: is specified in configuration.

-Fixes bug 50145.
+(sam: rebased for Meson and Duktape.)

-Closes polkit/polkit#14.
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/issues/14
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/issues/163
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/merge_requests/52
Signed-off-by: A. Wilcox <AWilcox@...>
-Signed-off-by: Khem Raj <raj.khem@...>
+
+Ported back the change in configure.ac (upstream removed autotools
+support).
+
+Upstream-Status: Backport [https://gitlab.freedesktop.org/polkit/polkit/-/commit/b57deee8178190a7ecc75290fa13cf7daabc2c66]
+Signed-off-by: Marta Rybczynska <marta.rybczynska@...>

---
- configure.ac | 2 +-
- src/polkit/polkitidentity.c | 16 ++++++++++++++++
- src/polkit/polkitunixnetgroup.c | 3 +++
- .../polkitbackendinteractiveauthority.c | 14 ++++++++------
- src/polkitbackend/polkitbackendjsauthority.cpp | 3 +++
- test/polkit/polkitidentitytest.c | 9 ++++++++-
- test/polkit/polkitunixnetgrouptest.c | 3 +++
- .../test-polkitbackendjsauthority.c | 2 ++
- 8 files changed, 44 insertions(+), 8 deletions(-)
+ configure.ac | 2 +-
+ meson.build | 1 +
+ src/polkit/polkitidentity.c | 17 +++++++++++++++++
+ src/polkit/polkitunixnetgroup.c | 3 +++
+ .../polkitbackendinteractiveauthority.c | 14 ++++++++------
+ src/polkitbackend/polkitbackendjsauthority.cpp | 2 ++
+ test/polkit/polkitidentitytest.c | 8 +++++++-
+ test/polkit/polkitunixnetgrouptest.c | 2 ++
+ .../test-polkitbackendjsauthority.c | 2 ++
+ 9 files changed, 43 insertions(+), 8 deletions(-)

diff --git a/configure.ac b/configure.ac
-index b625743..d807086 100644
+index 59858df..5a7fc11 100644
--- a/configure.ac
+++ b/configure.ac
@@ -100,7 +100,7 @@ AC_CHECK_LIB(expat,XML_ParserCreate,[EXPAT_LIBS="-lexpat"],
@@ -42,8 +49,20 @@ index b625743..d807086 100644

if test "x$GCC" = "xyes"; then
LDFLAGS="-Wl,--as-needed $LDFLAGS"
+diff --git a/meson.build b/meson.build
+index 733bbff..d840926 100644
+--- a/meson.build
++++ b/meson.build
+@@ -82,6 +82,7 @@ config_h.set('_GNU_SOURCE', true)
+ check_functions = [
+ 'clearenv',
+ 'fdatasync',
++ 'setnetgrent',
+ ]
+
+ foreach func: check_functions
diff --git a/src/polkit/polkitidentity.c b/src/polkit/polkitidentity.c
-index 3aa1f7f..10e9c17 100644
+index 3aa1f7f..793f17d 100644
--- a/src/polkit/polkitidentity.c
+++ b/src/polkit/polkitidentity.c
@@ -182,7 +182,15 @@ polkit_identity_from_string (const gchar *str,
@@ -62,7 +81,7 @@ index 3aa1f7f..10e9c17 100644
}

if (identity == NULL && (error != NULL && *error == NULL))
-@@ -344,6 +352,13 @@ polkit_identity_new_for_gvariant (GVariant *variant,
+@@ -344,6 +352,14 @@ polkit_identity_new_for_gvariant (GVariant *variant,
GVariant *v;
const char *name;

@@ -73,10 +92,11 @@ index 3aa1f7f..10e9c17 100644
+ "Netgroups are not available on this machine");
+ goto out;
+#else
++
v = lookup_asv (details_gvariant, "name", G_VARIANT_TYPE_STRING, error);
if (v == NULL)
{
-@@ -353,6 +368,7 @@ polkit_identity_new_for_gvariant (GVariant *variant,
+@@ -353,6 +369,7 @@ polkit_identity_new_for_gvariant (GVariant *variant,
name = g_variant_get_string (v, NULL);
ret = polkit_unix_netgroup_new (name);
g_variant_unref (v);
@@ -144,10 +164,10 @@ index 056d9a8..36c2f3d 100644
}

diff --git a/src/polkitbackend/polkitbackendjsauthority.cpp b/src/polkitbackend/polkitbackendjsauthority.cpp
-index ca17108..41d8d5c 100644
+index 5027815..bcb040c 100644
--- a/src/polkitbackend/polkitbackendjsauthority.cpp
+++ b/src/polkitbackend/polkitbackendjsauthority.cpp
-@@ -1520,6 +1520,7 @@ js_polkit_user_is_in_netgroup (JSContext *cx,
+@@ -1524,6 +1524,7 @@ js_polkit_user_is_in_netgroup (JSContext *cx,

JS::CallArgs args = JS::CallArgsFromVp (argc, vp);

@@ -155,28 +175,19 @@ index ca17108..41d8d5c 100644
JS::RootedString usrstr (authority->priv->cx);
usrstr = args[0].toString();
user = JS_EncodeStringToUTF8 (cx, usrstr);
-@@ -1535,6 +1536,8 @@ js_polkit_user_is_in_netgroup (JSContext *cx,
+@@ -1538,6 +1539,7 @@ js_polkit_user_is_in_netgroup (JSContext *cx,
+ {
is_in_netgroup = true;
}
-
+#endif
-+
+
ret = true;

- args.rval ().setBoolean (is_in_netgroup);
diff --git a/test/polkit/polkitidentitytest.c b/test/polkit/polkitidentitytest.c
-index e91967b..e829aaa 100644
+index e91967b..2635c4c 100644
--- a/test/polkit/polkitidentitytest.c
+++ b/test/polkit/polkitidentitytest.c
-@@ -19,6 +19,7 @@
- * Author: Nikki VonHollen <vonhollen@...>
- */
-
-+#include "config.h"
- #include "glib.h"
- #include <polkit/polkit.h>
- #include <polkit/polkitprivate.h>
-@@ -145,11 +146,15 @@ struct ComparisonTestData comparison_test_data [] = {
+@@ -145,11 +145,15 @@ struct ComparisonTestData comparison_test_data [] = {
{"unix-group:root", "unix-group:jane", FALSE},
{"unix-group:jane", "unix-group:jane", TRUE},

@@ -192,7 +203,7 @@ index e91967b..e829aaa 100644

{NULL},
};
-@@ -181,11 +186,13 @@ main (int argc, char *argv[])
+@@ -181,11 +185,13 @@ main (int argc, char *argv[])
g_test_add_data_func ("/PolkitIdentity/group_string_2", "unix-group:jane", test_string);
g_test_add_data_func ("/PolkitIdentity/group_string_3", "unix-group:users", test_string);

@@ -208,18 +219,10 @@ index e91967b..e829aaa 100644
add_comparison_tests ();

diff --git a/test/polkit/polkitunixnetgrouptest.c b/test/polkit/polkitunixnetgrouptest.c
-index 3701ba1..e3352eb 100644
+index 3701ba1..e1d211e 100644
--- a/test/polkit/polkitunixnetgrouptest.c
+++ b/test/polkit/polkitunixnetgrouptest.c
-@@ -19,6 +19,7 @@
- * Author: Nikki VonHollen <vonhollen@...>
- */
-
-+#include "config.h"
- #include "glib.h"
- #include <polkit/polkit.h>
- #include <string.h>
-@@ -69,7 +70,9 @@ int
+@@ -69,7 +69,9 @@ int
main (int argc, char *argv[])
{
g_test_init (&argc, &argv, NULL);
diff --git a/meta-oe/recipes-extended/polkit/polkit/0005-Make-netgroup-support-optional-duktape.patch b/meta-oe/recipes-extended/polkit/polkit/0005-Make-netgroup-support-optional-duktape.patch
new file mode 100644
index 000000000..12988ad94
--- /dev/null
+++ b/meta-oe/recipes-extended/polkit/polkit/0005-Make-netgroup-support-optional-duktape.patch
@@ -0,0 +1,34 @@
+From 792f8e2151c120ec51b50a4098e4f9642409cbec Mon Sep 17 00:00:00 2001
+From: Marta Rybczynska <rybczynska@...>
+Date: Fri, 29 Jul 2022 11:52:59 +0200
+Subject: [PATCH] Make netgroup support optional
+
+This patch adds a fragment of the netgroup patch to apply on the duktape-related
+code. This change is needed to compile with duktape+musl.
+
+Upstream-Status: Backport [https://gitlab.freedesktop.org/polkit/polkit/-/commit/b57deee8178190a7ecc75290fa13cf7daabc2c66]
+Signed-off-by: Marta Rybczynska <martarybczynska@...>
+---
+ src/polkitbackend/polkitbackendduktapeauthority.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/polkitbackend/polkitbackendduktapeauthority.c b/src/polkitbackend/polkitbackendduktapeauthority.c
+index c89dbcf..58a5936 100644
+--- a/src/polkitbackend/polkitbackendduktapeauthority.c
++++ b/src/polkitbackend/polkitbackendduktapeauthority.c
+@@ -1036,6 +1036,7 @@ js_polkit_user_is_in_netgroup (duk_context *cx)
+ user = duk_require_string (cx, 0);
+ netgroup = duk_require_string (cx, 1);
+
++#ifdef HAVE_SETNETGRENT
+ if (innetgr (netgroup,
+ NULL, /* host */
+ user,
+@@ -1043,6 +1044,7 @@ js_polkit_user_is_in_netgroup (duk_context *cx)
+ {
+ is_in_netgroup = TRUE;
+ }
++#endif
+
+ duk_push_boolean (cx, is_in_netgroup);
+ return 1;
diff --git a/meta-oe/recipes-extended/polkit/polkit_0.119.bb b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
index bf160053d..941c269a3 100644
--- a/meta-oe/recipes-extended/polkit/polkit_0.119.bb
+++ b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
@@ -34,14 +34,16 @@ MOZJS_PATCHES = "\
file://0003-jsauthority-ensure-to-call-JS_Init-and-JS_ShutDown-e.patch \
"
DUKTAPE_PATCHES = "file://0003-Added-support-for-duktape-as-JS-engine.patch"
+DUKTAPE_NG_PATCHES = "file://0005-Make-netgroup-support-optional-duktape.patch"
PAM_SRC_URI = "file://polkit-1_pam.patch"
SRC_URI = "http://www.freedesktop.org/software/polkit/releases/polkit-${PV}.tar.gz \
${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
${@bb.utils.contains('PACKAGECONFIG', 'mozjs', '${MOZJS_PATCHES}', '', d)} \
${@bb.utils.contains('PACKAGECONFIG', 'duktape', '${DUKTAPE_PATCHES}', '', d)} \
- file://0003-make-netgroup-support-optional.patch \
file://0001-pkexec-local-privilege-escalation-CVE-2021-4034.patch \
file://0002-CVE-2021-4115-GHSL-2021-077-fix.patch \
+ file://0004-Make-netgroup-support-optional.patch \
+ ${@bb.utils.contains('PACKAGECONFIG', 'duktape', '${DUKTAPE_NG_PATCHES}', '', d)} \
"
SRC_URI[sha256sum] = "c8579fdb86e94295404211285fee0722ad04893f0213e571bd75c00972fd1f5c"

--
2.33.0


Re: [oe-core][RFC PATCH 1/2] pipewire: fix build

Carlos Rafael Giani
 

It is my impression that libsdl2 is built natively for QEMU, and for nothing else, which means that having pipewire-nativesdk would not be necessary..?


On 21.05.22 10:03, Markus Volk wrote:

I didn't have a specific use case. I was just trying to build libsdl2 identical for target and native. And since libsdl2 can be built for nativesdk, the consequence would be that pipewire-nativesdk is needed to be built as well.

Am 21.05.22 um 08:58 schrieb Scott Murray:
On Fri, 20 May 2022, Markus Volk wrote:

-after updating to poky master i get issues picking the right udev provider
-add a backport patch to fix libsdl2 build with pipewire enabled
-allow native/nativesdk build
[snip]

I'm curious what your usecase is for native/nativesdk?  There's no
preprocessor or similiar tools in pipewire that I'm aware of.

Scott





Re: [meta-oe][ 1/1] fluentbit Upgrade to 1.3.5 -> 1.9.6

Khem Raj
 

Hi Paulo


On Thu, Jul 28, 2022 at 10:03 AM Paulo Neves <ptsneves@...> wrote:

Signed-off-by: Paulo Neves <ptsneves@...>
---
...t-Do-not-use-private-makefile-target.patch | 68 +++++++++++++++
...nit-install-location-with-SYSTEM_DIR.patch | 28 -------
...caused-by-using-flb_free-instead-of-.patch | 43 ----------
...-ppc-Fix-signature-for-co_create-API.patch | 38 ---------
...-not-hardcode-compilation-directorie.patch | 26 ++++++
...GV-caused-by-using-flb_free-instead-.patch | 82 -------------------
...0003-mbedtls-Do-not-overwrite-CFLAGS.patch | 25 ++++++
.../fluentbit/fluentbit/builtin-nan.patch | 27 ------
.../cross-build-init-system-detection.patch | 38 ---------
...{fluentbit_1.3.5.bb => fluentbit_1.9.6.bb} | 44 +++++-----
10 files changed, 139 insertions(+), 280 deletions(-)
create mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch
create mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch
create mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch
rename meta-oe/recipes-extended/fluentbit/{fluentbit_1.3.5.bb => fluentbit_1.9.6.bb} (53%)

diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch
new file mode 100644
index 000000000..0a80a92ed
--- /dev/null
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch
@@ -0,0 +1,68 @@
+From 6a704ab7bf69cd5d6970b3a7d3ae7798b26027c1 Mon Sep 17 00:00:00 2001
+From: Paulo Neves <ptsneves@...>
+Date: Thu, 28 Jul 2022 11:28:41 +0200
+Subject: [PATCH] CMakeLists.txt Do not use private makefile $< target
+
+$< is a private detail from the Makefile generated by CMakefile and
+are not under control or to be used at the CMakeLists level. In 3.20
+that private generation changed pre-requisite targets[1] and now logs
+contain the path compiler_depend.ts instead of the actual file.
+---
+ CMakeLists.txt | 6 +-----
+ lib/chunkio/CMakeLists.txt | 7 +------
+ lib/cmetrics/CMakeLists.txt | 7 +------
+ 3 files changed, 3 insertions(+), 17 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 3dba5a8..d94b988 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -46,11 +46,7 @@ else()
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall")
+ endif()
+
+-if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$(subst ${CMAKE_SOURCE_DIR}/,,$(abspath $<))\"'")
+-else()
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+-endif()
++set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+
+ if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv7l")
+ set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} -latomic")
+diff --git a/lib/chunkio/CMakeLists.txt b/lib/chunkio/CMakeLists.txt
+index bbe1f39..809ea93 100644
+--- a/lib/chunkio/CMakeLists.txt
++++ b/lib/chunkio/CMakeLists.txt
+@@ -14,12 +14,7 @@ else()
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall ")
+ endif()
+
+-# Set __FILENAME__
+-if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$(subst ${CMAKE_SOURCE_DIR}/,,$(abspath $<))\"'")
+-else()
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+-endif()
++set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+
+ include(cmake/macros.cmake)
+
+diff --git a/lib/cmetrics/CMakeLists.txt b/lib/cmetrics/CMakeLists.txt
+index 60e8774..e3d6149 100644
+--- a/lib/cmetrics/CMakeLists.txt
++++ b/lib/cmetrics/CMakeLists.txt
+@@ -34,12 +34,7 @@ set(CMT_VERSION_MINOR 3)
+ set(CMT_VERSION_PATCH 5)
+ set(CMT_VERSION_STR "${CMT_VERSION_MAJOR}.${CMT_VERSION_MINOR}.${CMT_VERSION_PATCH}")
+
+-# Define __FILENAME__ consistently across Operating Systems
+-if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$(subst ${CMAKE_SOURCE_DIR}/,,$(abspath $<))\"'")
+-else()
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+-endif()
++set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+
+ # Configuration options
+ option(CMT_DEV "Enable development mode" No)
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch
deleted file mode 100644
index bf4cda08f..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 5571f949fa2048b79c197b5b10a11ecb1891cbe9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@...>
-Date: Sat, 23 Apr 2022 08:24:34 -0700
-Subject: [PATCH] Control sytemd unit install location with SYSTEM_DIR
-
-This helps building when usrmerge is on
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@...>
----
- src/CMakeLists.txt | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
---- a/src/CMakeLists.txt
-+++ b/src/CMakeLists.txt
-@@ -323,7 +323,11 @@ if(FLB_BINARY)
- "${PROJECT_SOURCE_DIR}/init/systemd.in"
- ${FLB_SYSTEMD_SCRIPT}
- )
-- install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION /lib/systemd/system)
-+ if(SYSTEMD_DIR)
-+ install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION ${SYSTEMD_DIR})
-+ else()
-+ install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION /lib/systemd/system)
-+ endif()
- install(DIRECTORY DESTINATION ${FLB_INSTALL_CONFDIR})
- elseif(FLB_UPSTART)
- set(FLB_UPSTART_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.conf")
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch
deleted file mode 100644
index a6ff5991c..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 3d7390c89c2205d1eed0384be0bb65adb675e60d Mon Sep 17 00:00:00 2001
-From: Ramon Fried <ramon@...>
-Date: Tue, 9 Feb 2021 18:59:59 +0200
-Subject: [PATCH] bin: fix SIGSEGV caused by using flb_free instead of
- mk_mem_free
-
-Upstream-Status: Accepted
-Signed-off-by: Ramon Fried <ramon@...>
----
- src/fluent-bit.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/src/fluent-bit.c b/src/fluent-bit.c
-index c0c73b4..989cfde 100644
---- a/src/fluent-bit.c
-+++ b/src/fluent-bit.c
-@@ -289,7 +289,7 @@ static int input_set_property(struct flb_input_instance *in, char *kv)
- in->p->name, key);
- }
-
-- flb_free(key);
-+ mk_mem_free(key);
- return ret;
- }
-
-@@ -314,7 +314,7 @@ static int output_set_property(struct flb_output_instance *out, char *kv)
- }
-
- ret = flb_output_set_property(out, key, value);
-- flb_free(key);
-+ mk_mem_free(key);
- return ret;
- }
-
-@@ -340,7 +340,7 @@ static int filter_set_property(struct flb_filter_instance *filter, char *kv)
- }
-
- ret = flb_filter_set_property(filter, key, value);
-- flb_free(key);
-+ mk_mem_free(key);
- return ret;
- }
-
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch
deleted file mode 100644
index 1f36c657e..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From be4032079c931704f52e29f5da5c01cde24ac842 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@...>
-Date: Thu, 16 Jan 2020 10:44:58 -0800
-Subject: [PATCH] ppc: Fix signature for co_create API
-
-Upstream-Status: Submitted [https://github.com/fluent/fluent-bit/pull/1886]
-Signed-off-by: Khem Raj <raj.khem@...>
----
- lib/flb_libco/ppc.c | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/lib/flb_libco/ppc.c b/lib/flb_libco/ppc.c
-index e6536d56..533256b3 100644
---- a/lib/flb_libco/ppc.c
-+++ b/lib/flb_libco/ppc.c
-@@ -279,7 +279,9 @@ static uint32_t* co_create_(unsigned size, uintptr_t entry) {
- return t;
- }
-
--cothread_t co_create(unsigned int size, void (*entry_)(void)) {
-+cothread_t co_create(unsigned int size, void (*entry_)(void),
-+ size_t *out_size) {
-+
- uintptr_t entry = (uintptr_t)entry_;
- uint32_t* t = 0;
-
-@@ -325,7 +327,7 @@ cothread_t co_create(unsigned int size, void (*entry_)(void)) {
- t[10] = (uint32_t)(sp >> shift >> shift);
- t[11] = (uint32_t)sp;
- }
--
-+ *out_size = size;
- return t;
- }
-
---
-2.25.0
-
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch
new file mode 100644
index 000000000..4358b2a51
--- /dev/null
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch
@@ -0,0 +1,26 @@
+From 71dab751a27a2e582b711de22873065dd28f4b65 Mon Sep 17 00:00:00 2001
+From: Paulo Neves <ptsneves@...>
+Date: Thu, 28 Jul 2022 11:42:31 +0200
+Subject: [PATCH] flb_info.h.in: Do not hardcode compilation directories
+
+Including the source dir in the header makes the header not
+reproducible and contaminates it with host builder paths. Instead
+make it take CMAKE_DEBUG_SRCDIR that can be set to a known
+reproducible value
+---
+ include/fluent-bit/flb_info.h.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/fluent-bit/flb_info.h.in b/include/fluent-bit/flb_info.h.in
+index a89485c..2579afc 100644
+--- a/include/fluent-bit/flb_info.h.in
++++ b/include/fluent-bit/flb_info.h.in
+@@ -23,7 +23,7 @@
+ #define STR_HELPER(s) #s
+ #define STR(s) STR_HELPER(s)
+
+-#define FLB_SOURCE_DIR "@CMAKE_SOURCE_DIR@"
++#define FLB_SOURCE_DIR "@CMAKE_DEBUG_SRCDIR@"
+
+ /* General flags set by CMakeLists.txt */
+ @FLB_BUILD_FLAGS@
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch
deleted file mode 100644
index 91675dfc6..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From 7c3b1dfb174312594d3317c24ed71c60398f653f Mon Sep 17 00:00:00 2001
-From: Ramon Fried <ramon@...>
-Date: Wed, 10 Feb 2021 04:23:36 +0200
-Subject: [PATCH] parser: Fix SIGSEGV caused by using flb_free instead of
- mk_mem_free
-
-Upstream-Status: Backport (fix only for 1.3.5)
-Signed-off-by: Ramon Fried <ramon@...>
----
- src/flb_parser.c | 28 ++++++++++++++--------------
- 1 file changed, 14 insertions(+), 14 deletions(-)
-
-diff --git a/src/flb_parser.c b/src/flb_parser.c
-index d35c568..7c20e12 100644
---- a/src/flb_parser.c
-+++ b/src/flb_parser.c
-@@ -490,7 +490,7 @@ int flb_parser_conf_file(const char *file, struct flb_config *config)
- MK_RCONF_STR);
- if (str) {
- time_keep = flb_utils_bool(str);
-- flb_free(str);
-+ mk_mem_free(str);
- }
- else {
- time_keep = FLB_FALSE;
-@@ -522,23 +522,23 @@ int flb_parser_conf_file(const char *file, struct flb_config *config)
-
- flb_debug("[parser] new parser registered: %s", name);
-
-- flb_free(name);
-- flb_free(format);
-+ mk_mem_free(name);
-+ mk_mem_free(format);
-
- if (regex) {
-- flb_free(regex);
-+ mk_mem_free(regex);
- }
- if (time_fmt) {
-- flb_free(time_fmt);
-+ mk_mem_free(time_fmt);
- }
- if (time_key) {
-- flb_free(time_key);
-+ mk_mem_free(time_key);
- }
- if (time_offset) {
-- flb_free(time_offset);
-+ mk_mem_free(time_offset);
- }
- if (types_str) {
-- flb_free(types_str);
-+ mk_mem_free(types_str);
- }
-
- decoders = NULL;
-@@ -548,19 +548,19 @@ int flb_parser_conf_file(const char *file, struct flb_config *config)
- return 0;
-
- fconf_error:
-- flb_free(name);
-- flb_free(format);
-+ mk_mem_free(name);
-+ mk_mem_free(format);
- if (regex) {
-- flb_free(regex);
-+ mk_mem_free(regex);
- }
- if (time_fmt) {
-- flb_free(time_fmt);
-+ mk_mem_free(time_fmt);
- }
- if (time_key) {
-- flb_free(time_key);
-+ mk_mem_free(time_key);
- }
- if (types_str) {
-- flb_free(types_str);
-+ mk_mem_free(types_str);
- }
- if (decoders) {
- flb_parser_decoder_list_destroy(decoders);
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch
new file mode 100644
index 000000000..0611af9ec
--- /dev/null
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch
@@ -0,0 +1,25 @@
+From 8486b912281ae85db0c9fc05bb546f16872e114c Mon Sep 17 00:00:00 2001
+From: Paulo Neves <ptsneves@...>
+Date: Thu, 28 Jul 2022 14:37:18 +0200
+Subject: [PATCH] mbedtls: Do not overwrite CFLAGS
+
+bitbake passes CFLAGS that are often in conflict with the ones set
+in mbedtls' CMakeLists.txt. Such conflicts are the inability to use
+FORTIFY_SOURCE=2 except in release mode
+---
+ lib/mbedtls-2.28.0/CMakeLists.txt | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/lib/mbedtls-2.28.0/CMakeLists.txt b/lib/mbedtls-2.28.0/CMakeLists.txt
+index d76bddc..e717846 100644
+--- a/lib/mbedtls-2.28.0/CMakeLists.txt
++++ b/lib/mbedtls-2.28.0/CMakeLists.txt
+@@ -204,8 +204,6 @@ if(CMAKE_COMPILER_IS_GNU)
+ if (GCC_VERSION VERSION_GREATER 7.0 OR GCC_VERSION VERSION_EQUAL 7.0)
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wformat-overflow=2 -Wformat-truncation")
+ endif()
+- set(CMAKE_C_FLAGS_RELEASE "-O2")
+- set(CMAKE_C_FLAGS_DEBUG "-O0 -g3")
+ set(CMAKE_C_FLAGS_COVERAGE "-O0 -g3 --coverage")
+ set(CMAKE_C_FLAGS_ASAN "-fsanitize=address -fno-common -fsanitize=undefined -fno-sanitize-recover=all -O3")
+ set(CMAKE_C_FLAGS_ASANDBG "-fsanitize=address -fno-common -fsanitize=undefined -fno-sanitize-recover=all -O1 -g3 -fno-omit-frame-pointer -fno-optimize-sibling-calls")
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch
deleted file mode 100644
index 8ffc3be3e..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-help complier to use intrinsics, clang in few cases e.g. aarch64 can not
-and then requires linking with libm, its the only function needed from libm then
-its good to avoid needing it.
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@...>
-
---- a/include/fluent-bit/stream_processor/flb_sp_timeseries.h
-+++ b/include/fluent-bit/stream_processor/flb_sp_timeseries.h
-@@ -207,7 +207,7 @@ void cb_forecast_calc(struct timeseries
- result = b0 + b1 * (val->f64 + *forecast->latest_x);
- break;
- default:
-- result = nan("");
-+ result = __builtin_nan("");
- break;
- }
-
-@@ -283,7 +283,7 @@ void cb_forecast_r_calc(struct timeserie
- result = ((val->i64 - b0) / b1) - *forecast->latest_x;
- break;
- default:
-- result = nan("");
-+ result = __builtin_nan("");
- break;
- }
-
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch
deleted file mode 100644
index d3822fc8d..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-Define CMake variables to indicate init system for target
-incase of cross compile, detecting systemd support based on
-host directory structure is not right thing to do
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.kheem@...>
-
---- a/src/CMakeLists.txt
-+++ b/src/CMakeLists.txt
-@@ -317,7 +317,7 @@ if(FLB_BINARY)
- install(TARGETS fluent-bit-bin RUNTIME DESTINATION ${FLB_INSTALL_BINDIR})
-
- # Detect init system, install upstart, systemd or init.d script
-- if(IS_DIRECTORY /lib/systemd/system)
-+ if(FLB_SYSTEMD)
- set(FLB_SYSTEMD_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.service")
- configure_file(
- "${PROJECT_SOURCE_DIR}/init/systemd.in"
-@@ -325,7 +325,7 @@ if(FLB_BINARY)
- )
- install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION /lib/systemd/system)
- install(DIRECTORY DESTINATION ${FLB_INSTALL_CONFDIR})
-- elseif(IS_DIRECTORY /usr/share/upstart)
-+ elseif(FLB_UPSTART)
- set(FLB_UPSTART_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.conf")
- configure_file(
- "${PROJECT_SOURCE_DIR}/init/upstart.in"
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -70,6 +70,8 @@ option(FLB_RECORD_ACCESSOR "Enable re
- option(FLB_SYSTEM_STRPTIME "Use strptime in system libc" Yes)
- option(FLB_STATIC_CONF "Build binary using static configuration")
- option(FLB_STREAM_PROCESSOR "Enable Stream Processor" Yes)
-+option(FLB_SYSTEMD "Enable systemd init system" No)
-+option(FLB_UPSTART "Enable upstart init system" No)
- option(FLB_CORO_STACK_SIZE "Set coroutine stack size")
-
- # Metrics: Experimental Feature, disabled by default on 0.12 series
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit_1.3.5.bb b/meta-oe/recipes-extended/fluentbit/fluentbit_1.9.6.bb
similarity index 53%
rename from meta-oe/recipes-extended/fluentbit/fluentbit_1.3.5.bb
rename to meta-oe/recipes-extended/fluentbit/fluentbit_1.9.6.bb
index b231cc287..1ff62767d 100644
--- a/meta-oe/recipes-extended/fluentbit/fluentbit_1.3.5.bb
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit_1.9.6.bb
@@ -11,25 +11,28 @@ LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://LICENSE;md5=2ee41112a44fe7014dce33e26468ba93"
SECTION = "net"

-SRC_URI = "http://fluentbit.io/releases/1.3/fluent-bit-${PV}.tar.gz \
+PR = "r0"
We don't need to set PR in recipe anymore

+PV = "1.9.6"
We don't need PV either since it's in the recipe name already.

+
+SRC_URI = "https://releases.fluentbit.io/1.9/source-${PV}.tar.gz;subdir=fluent-bit-${PV} \
+ file://0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch \
+ file://0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch \
+ file://0003-mbedtls-Do-not-overwrite-CFLAGS.patch \
file://jemalloc.patch \
- file://cross-build-init-system-detection.patch \
- file://builtin-nan.patch \
- file://0001-ppc-Fix-signature-for-co_create-API.patch \
- file://0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch \
- file://0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch \
- file://0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch \
does this work without patch with usrmerge distro feature on ?

"
-SRC_URI[md5sum] = "6eae6dfd0a874e5dd270c36e9c68f747"
-SRC_URI[sha256sum] = "e037c76c89269c8dc4027a08e442fefd2751b0f1e0f9c38f9a4b12d781a9c789"
+SRC_URI[md5sum] = "ad65bb3ca55d203a467a63426e17bfae"
we don't need md5sum anymore.

+SRC_URI[sha256sum] = "5ef7dd97e10936269fe5f4e5d3ebf16559333066f7d6757ba12464a9d6186570"

S = "${WORKDIR}/fluent-bit-${PV}"
-DEPENDS = "zlib bison-native flex-native"
+DEPENDS = "zlib bison-native flex-native openssl"
DEPENDS += "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
-
+PACKAGECONFIG[yaml] = "-DFLB_CONFIG_YAML=On,-DFLB_CONFIG_YAML=Off, yaml,"
+PACKAGECONFIG[kafka] = "-DFLB_OUT_KAFKA=On,-DFLB_OUT_KAFKA=Off,librdkafka"
+PACKAGECONFIG[examples] = "-DFLB_EXAMPLES=On,-DFLB_EXAMPLES=Off"
+PACKAGECONFIG[jemalloc] = "-DFLB_JEMALLOC=On,-DFLB_JEMALLOC=Off,jemalloc"
DEPENDS:append:libc-musl = " fts "

-INSANE_SKIP:${PN}-dev += "dev-elf"
+PACKAGECONFIG ?= "yaml"
There is no recipe providing yaml in core or meta-oe, perhaps you
meant libyaml maybe ?


LTO = ""

@@ -40,13 +43,13 @@ OECMAKE_GENERATOR ?= "Unix Makefiles"
# ========================

# Host related setup
-EXTRA_OECMAKE += "-DGNU_HOST=${HOST_SYS} -DFLB_ALL=ON -DFLB_TD=1"
+EXTRA_OECMAKE += "-DGNU_HOST=${HOST_SYS} -DFLB_TD=1"

# Disable LuaJIT and filter_lua support
EXTRA_OECMAKE += "-DFLB_LUAJIT=Off -DFLB_FILTER_LUA=Off "

# Disable Library and examples
-EXTRA_OECMAKE += "-DFLB_SHARED_LIB=Off -DFLB_EXAMPLES=Off "
+EXTRA_OECMAKE += "-DFLB_SHARED_LIB=Off"

# Enable systemd iff systemd is in DISTRO_FEATURES
EXTRA_OECMAKE += "${@bb.utils.contains('DISTRO_FEATURES','systemd','-DFLB_SYSTEMD=On -DSYSTEMD_DIR=${systemd_system_unitdir}','-DFLB_SYSTEMD=Off',d)}"
@@ -54,16 +57,9 @@ EXTRA_OECMAKE += "${@bb.utils.contains('DISTRO_FEATURES','systemd','-DFLB_SYSTEM
EXTRA_OECMAKE:append:riscv64 = " -DFLB_DEPS='atomic'"
EXTRA_OECMAKE:append:riscv32 = " -DFLB_DEPS='atomic'"

-# Kafka Output plugin (disabled by default): note that when
-# enabling Kafka output plugin, the backend library librdkafka
-# requires 'openssl' as a dependency.
-#
-# DEPENDS += "openssl "
-# EXTRA_OECMAKE += "-DFLB_OUT_KAFKA=On "
-
inherit cmake systemd

-CFLAGS += "-fcommon"
-
SYSTEMD_SERVICE:${PN} = "td-agent-bit.service"
-TARGET_CC_ARCH:append = " ${SELECTED_OPTIMIZATION}"
+
+EXTRA_OECMAKE += "-DCMAKE_DEBUG_SRCDIR=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}/"
+TARGET_CC_ARCH += " ${SELECTED_OPTIMIZATION}"
--
2.25.1




Re: [meta-oe][kirkstone][PATCH] polkit: update patches for musl compilation

Khem Raj
 

On Thu, Jul 28, 2022 at 11:04 AM Marta Rybczynska <rybczynska@...> wrote:

Update the patch to make netgroup support optional to fit the commit
merged upstream [1], update the other patch depending on one of the
changes.

Without this update, a compilation with musl fails with:
| ../../../polkit-0.119/src/polkitbackend/polkitbackendduktapeauthority.c: In function 'js_polkit_user_is_in_netgroup':
| ../../../polkit-0.119/src/polkitbackend/polkitbackendduktapeauthority.c:1039:7: warning: implicit declaration of function 'innetgr' [-Wimplicit-function-declaration]
| 1039 | if (innetgr (netgroup,
| | ^~~~~~~

[1] https://gitlab.freedesktop.org/polkit/polkit/-/commit/b57deee8178190a7ecc75290fa13cf7daabc2c66
this is needed on master too I guess. Can you rebase on latest
master-next and resend for master inclusion.

Signed-off-by: Marta Rybczynska <marta.rybczynska@...>
---
...ded-support-for-duktape-as-JS-engine.patch | 2 +-
.../0004-Make-netgroup-support-optional.patch | 276 ++++++++++++++++++
.../recipes-extended/polkit/polkit_0.119.bb | 2 +-
3 files changed, 278 insertions(+), 2 deletions(-)
create mode 100644 meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch

diff --git a/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch b/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
index e44e4f6e4..21190a8e5 100644
--- a/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
+++ b/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
@@ -603,7 +603,7 @@ index b625743..bbf4768 100644
+CC="$PTHREAD_CC"
+AC_CHECK_FUNCS([pthread_condattr_setclock])
+
- AC_CHECK_FUNCS(clearenv fdatasync setnetgrent)
+ AC_CHECK_FUNCS(clearenv fdatasync)

if test "x$GCC" = "xyes"; then
@@ -581,6 +598,13 @@ echo "
diff --git a/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch b/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch
new file mode 100644
index 000000000..3a16b1474
--- /dev/null
+++ b/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch
@@ -0,0 +1,276 @@
+From 6d80df97117b0918cb9192c7d58b55aed1779ecb Mon Sep 17 00:00:00 2001
+From: "A. Wilcox" <AWilcox@...>
+Date: Sun, 15 May 2022 05:04:10 +0000
+Subject: [PATCH] Make netgroup support optional
+
+On at least Linux/musl and Linux/uclibc, netgroup support is not
+available. PolKit fails to compile on these systems for that reason.
+
+This change makes netgroup support conditional on the presence of the
+setnetgrent(3) function which is required for the support to work. If
+that function is not available on the system, an error will be returned
+to the administrator if unix-netgroup: is specified in configuration.
+
+(sam: rebased for Meson and Duktape.)
+
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/issues/14
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/issues/163
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/merge_requests/52
+Signed-off-by: A. Wilcox <AWilcox@...>
+
+Ported back the change in configure.ac (upstream removed autotools
+support).
+
+Upstream-Status: Backport [https://gitlab.freedesktop.org/polkit/polkit/-/commit/b57deee8178190a7ecc75290fa13cf7daabc2c66]
+Signed-off-by: Marta Rybczynska <marta.rybczynska@...>
+
+---
+ configure.ac | 2 +-
+ meson.build | 1 +
+ src/polkit/polkitidentity.c | 17 +++++++++++++++++
+ src/polkit/polkitunixnetgroup.c | 3 +++
+ .../polkitbackendduktapeauthority.c | 4 ++--
+ .../polkitbackendinteractiveauthority.c | 14 ++++++++------
+ src/polkitbackend/polkitbackendjsauthority.cpp | 2 ++
+ test/polkit/polkitidentitytest.c | 8 +++++++-
+ test/polkit/polkitunixnetgrouptest.c | 2 ++
+ .../test-polkitbackendjsauthority.c | 2 ++
+ 10 files changed, 45 insertions(+), 10 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index bbf4768..f636ec5 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -117,7 +117,7 @@ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+ CC="$PTHREAD_CC"
+ AC_CHECK_FUNCS([pthread_condattr_setclock])
+
+-AC_CHECK_FUNCS(clearenv fdatasync)
++AC_CHECK_FUNCS(clearenv fdatasync setnetgrent)
+
+ if test "x$GCC" = "xyes"; then
+ LDFLAGS="-Wl,--as-needed $LDFLAGS"
+diff --git a/meson.build b/meson.build
+index 7506231..2d9d67a 100644
+--- a/meson.build
++++ b/meson.build
+@@ -82,6 +82,7 @@ config_h.set('_GNU_SOURCE', true)
+ check_functions = [
+ 'clearenv',
+ 'fdatasync',
++ 'setnetgrent',
+ ]
+
+ foreach func: check_functions
+diff --git a/src/polkit/polkitidentity.c b/src/polkit/polkitidentity.c
+index 3aa1f7f..793f17d 100644
+--- a/src/polkit/polkitidentity.c
++++ b/src/polkit/polkitidentity.c
+@@ -182,7 +182,15 @@ polkit_identity_from_string (const gchar *str,
+ }
+ else if (g_str_has_prefix (str, "unix-netgroup:"))
+ {
++#ifndef HAVE_SETNETGRENT
++ g_set_error (error,
++ POLKIT_ERROR,
++ POLKIT_ERROR_FAILED,
++ "Netgroups are not available on this machine ('%s')",
++ str);
++#else
+ identity = polkit_unix_netgroup_new (str + sizeof "unix-netgroup:" - 1);
++#endif
+ }
+
+ if (identity == NULL && (error != NULL && *error == NULL))
+@@ -344,6 +352,14 @@ polkit_identity_new_for_gvariant (GVariant *variant,
+ GVariant *v;
+ const char *name;
+
++#ifndef HAVE_SETNETGRENT
++ g_set_error (error,
++ POLKIT_ERROR,
++ POLKIT_ERROR_FAILED,
++ "Netgroups are not available on this machine");
++ goto out;
++#else
++
+ v = lookup_asv (details_gvariant, "name", G_VARIANT_TYPE_STRING, error);
+ if (v == NULL)
+ {
+@@ -353,6 +369,7 @@ polkit_identity_new_for_gvariant (GVariant *variant,
+ name = g_variant_get_string (v, NULL);
+ ret = polkit_unix_netgroup_new (name);
+ g_variant_unref (v);
++#endif
+ }
+ else
+ {
+diff --git a/src/polkit/polkitunixnetgroup.c b/src/polkit/polkitunixnetgroup.c
+index 8a2b369..83f8d4a 100644
+--- a/src/polkit/polkitunixnetgroup.c
++++ b/src/polkit/polkitunixnetgroup.c
+@@ -194,6 +194,9 @@ polkit_unix_netgroup_set_name (PolkitUnixNetgroup *group,
+ PolkitIdentity *
+ polkit_unix_netgroup_new (const gchar *name)
+ {
++#ifndef HAVE_SETNETGRENT
++ g_assert_not_reached();
++#endif
+ g_return_val_if_fail (name != NULL, NULL);
+ return POLKIT_IDENTITY (g_object_new (POLKIT_TYPE_UNIX_NETGROUP,
+ "name", name,
+diff --git a/src/polkitbackend/polkitbackendduktapeauthority.c b/src/polkitbackend/polkitbackendduktapeauthority.c
+index c89dbcf..f4b4304 100644
+--- a/src/polkitbackend/polkitbackendduktapeauthority.c
++++ b/src/polkitbackend/polkitbackendduktapeauthority.c
+@@ -1035,7 +1035,7 @@ js_polkit_user_is_in_netgroup (duk_context *cx)
+
+ user = duk_require_string (cx, 0);
+ netgroup = duk_require_string (cx, 1);
+-
++#ifdef HAVE_SETNETGRENT
+ if (innetgr (netgroup,
+ NULL, /* host */
+ user,
+@@ -1043,7 +1043,7 @@ js_polkit_user_is_in_netgroup (duk_context *cx)
+ {
+ is_in_netgroup = TRUE;
+ }
+-
++#endif
+ duk_push_boolean (cx, is_in_netgroup);
+ return 1;
+ }
+diff --git a/src/polkitbackend/polkitbackendinteractiveauthority.c b/src/polkitbackend/polkitbackendinteractiveauthority.c
+index 056d9a8..36c2f3d 100644
+--- a/src/polkitbackend/polkitbackendinteractiveauthority.c
++++ b/src/polkitbackend/polkitbackendinteractiveauthority.c
+@@ -2233,25 +2233,26 @@ get_users_in_net_group (PolkitIdentity *group,
+ GList *ret;
+
+ ret = NULL;
++#ifdef HAVE_SETNETGRENT
+ name = polkit_unix_netgroup_get_name (POLKIT_UNIX_NETGROUP (group));
+
+-#ifdef HAVE_SETNETGRENT_RETURN
++# ifdef HAVE_SETNETGRENT_RETURN
+ if (setnetgrent (name) == 0)
+ {
+ g_warning ("Error looking up net group with name %s: %s", name, g_strerror (errno));
+ goto out;
+ }
+-#else
++# else
+ setnetgrent (name);
+-#endif
++# endif /* HAVE_SETNETGRENT_RETURN */
+
+ for (;;)
+ {
+-#if defined(HAVE_NETBSD) || defined(HAVE_OPENBSD)
++# if defined(HAVE_NETBSD) || defined(HAVE_OPENBSD)
+ const char *hostname, *username, *domainname;
+-#else
++# else
+ char *hostname, *username, *domainname;
+-#endif
++# endif /* defined(HAVE_NETBSD) || defined(HAVE_OPENBSD) */
+ PolkitIdentity *user;
+ GError *error = NULL;
+
+@@ -2282,6 +2283,7 @@ get_users_in_net_group (PolkitIdentity *group,
+
+ out:
+ endnetgrent ();
++#endif /* HAVE_SETNETGRENT */
+ return ret;
+ }
+
+diff --git a/src/polkitbackend/polkitbackendjsauthority.cpp b/src/polkitbackend/polkitbackendjsauthority.cpp
+index 11e91c0..9ee0391 100644
+--- a/src/polkitbackend/polkitbackendjsauthority.cpp
++++ b/src/polkitbackend/polkitbackendjsauthority.cpp
+@@ -1291,6 +1291,7 @@ js_polkit_user_is_in_netgroup (JSContext *cx,
+
+ JS::CallArgs args = JS::CallArgsFromVp (argc, vp);
+
++#ifdef HAVE_SETNETGRENT
+ JS::RootedString usrstr (authority->priv->cx);
+ usrstr = args[0].toString();
+ user = JS_EncodeStringToUTF8 (cx, usrstr);
+@@ -1305,6 +1306,7 @@ js_polkit_user_is_in_netgroup (JSContext *cx,
+ {
+ is_in_netgroup = true;
+ }
++#endif
+
+ ret = true;
+
+diff --git a/test/polkit/polkitidentitytest.c b/test/polkit/polkitidentitytest.c
+index e91967b..2635c4c 100644
+--- a/test/polkit/polkitidentitytest.c
++++ b/test/polkit/polkitidentitytest.c
+@@ -145,11 +145,15 @@ struct ComparisonTestData comparison_test_data [] = {
+ {"unix-group:root", "unix-group:jane", FALSE},
+ {"unix-group:jane", "unix-group:jane", TRUE},
+
++#ifdef HAVE_SETNETGRENT
+ {"unix-netgroup:foo", "unix-netgroup:foo", TRUE},
+ {"unix-netgroup:foo", "unix-netgroup:bar", FALSE},
++#endif
+
+ {"unix-user:root", "unix-group:root", FALSE},
++#ifdef HAVE_SETNETGRENT
+ {"unix-user:jane", "unix-netgroup:foo", FALSE},
++#endif
+
+ {NULL},
+ };
+@@ -181,11 +185,13 @@ main (int argc, char *argv[])
+ g_test_add_data_func ("/PolkitIdentity/group_string_2", "unix-group:jane", test_string);
+ g_test_add_data_func ("/PolkitIdentity/group_string_3", "unix-group:users", test_string);
+
++#ifdef HAVE_SETNETGRENT
+ g_test_add_data_func ("/PolkitIdentity/netgroup_string", "unix-netgroup:foo", test_string);
++ g_test_add_data_func ("/PolkitIdentity/netgroup_gvariant", "unix-netgroup:foo", test_gvariant);
++#endif
+
+ g_test_add_data_func ("/PolkitIdentity/user_gvariant", "unix-user:root", test_gvariant);
+ g_test_add_data_func ("/PolkitIdentity/group_gvariant", "unix-group:root", test_gvariant);
+- g_test_add_data_func ("/PolkitIdentity/netgroup_gvariant", "unix-netgroup:foo", test_gvariant);
+
+ add_comparison_tests ();
+
+diff --git a/test/polkit/polkitunixnetgrouptest.c b/test/polkit/polkitunixnetgrouptest.c
+index 3701ba1..e1d211e 100644
+--- a/test/polkit/polkitunixnetgrouptest.c
++++ b/test/polkit/polkitunixnetgrouptest.c
+@@ -69,7 +69,9 @@ int
+ main (int argc, char *argv[])
+ {
+ g_test_init (&argc, &argv, NULL);
++#ifdef HAVE_SETNETGRENT
+ g_test_add_func ("/PolkitUnixNetgroup/new", test_new);
+ g_test_add_func ("/PolkitUnixNetgroup/set_name", test_set_name);
++#endif
+ return g_test_run ();
+ }
+diff --git a/test/polkitbackend/test-polkitbackendjsauthority.c b/test/polkitbackend/test-polkitbackendjsauthority.c
+index 2103b17..b187a2f 100644
+--- a/test/polkitbackend/test-polkitbackendjsauthority.c
++++ b/test/polkitbackend/test-polkitbackendjsauthority.c
+@@ -137,12 +137,14 @@ test_get_admin_identities (void)
+ "unix-group:users"
+ }
+ },
++#ifdef HAVE_SETNETGRENT
+ {
+ "net.company.action3",
+ {
+ "unix-netgroup:foo"
+ }
+ },
++#endif
+ };
+ guint n;
+
diff --git a/meta-oe/recipes-extended/polkit/polkit_0.119.bb b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
index 66bbf735f..773148fdd 100644
--- a/meta-oe/recipes-extended/polkit/polkit_0.119.bb
+++ b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
@@ -24,10 +24,10 @@ PACKAGECONFIG[consolekit] = ",,,consolekit"
PAM_SRC_URI = "file://polkit-1_pam.patch"
SRC_URI = "http://www.freedesktop.org/software/polkit/releases/polkit-${PV}.tar.gz \
${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
- file://0003-make-netgroup-support-optional.patch \
file://0001-pkexec-local-privilege-escalation-CVE-2021-4034.patch \
file://0002-CVE-2021-4115-GHSL-2021-077-fix.patch \
file://0003-Added-support-for-duktape-as-JS-engine.patch \
+ file://0004-Make-netgroup-support-optional.patch \
"
SRC_URI[sha256sum] = "c8579fdb86e94295404211285fee0722ad04893f0213e571bd75c00972fd1f5c"

--
2.33.0


[meta-oe][kirkstone][PATCH] polkit: update patches for musl compilation

Marta Rybczynska
 

Update the patch to make netgroup support optional to fit the commit
merged upstream [1], update the other patch depending on one of the
changes.

Without this update, a compilation with musl fails with:
| ../../../polkit-0.119/src/polkitbackend/polkitbackendduktapeauthority.c: In function 'js_polkit_user_is_in_netgroup':
| ../../../polkit-0.119/src/polkitbackend/polkitbackendduktapeauthority.c:1039:7: warning: implicit declaration of function 'innetgr' [-Wimplicit-function-declaration]
| 1039 | if (innetgr (netgroup,
| | ^~~~~~~

[1] https://gitlab.freedesktop.org/polkit/polkit/-/commit/b57deee8178190a7ecc75290fa13cf7daabc2c66

Signed-off-by: Marta Rybczynska <marta.rybczynska@...>
---
...ded-support-for-duktape-as-JS-engine.patch | 2 +-
.../0004-Make-netgroup-support-optional.patch | 276 ++++++++++++++++++
.../recipes-extended/polkit/polkit_0.119.bb | 2 +-
3 files changed, 278 insertions(+), 2 deletions(-)
create mode 100644 meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch

diff --git a/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch b/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
index e44e4f6e4..21190a8e5 100644
--- a/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
+++ b/meta-oe/recipes-extended/polkit/polkit/0003-Added-support-for-duktape-as-JS-engine.patch
@@ -603,7 +603,7 @@ index b625743..bbf4768 100644
+CC="$PTHREAD_CC"
+AC_CHECK_FUNCS([pthread_condattr_setclock])
+
- AC_CHECK_FUNCS(clearenv fdatasync setnetgrent)
+ AC_CHECK_FUNCS(clearenv fdatasync)

if test "x$GCC" = "xyes"; then
@@ -581,6 +598,13 @@ echo "
diff --git a/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch b/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch
new file mode 100644
index 000000000..3a16b1474
--- /dev/null
+++ b/meta-oe/recipes-extended/polkit/polkit/0004-Make-netgroup-support-optional.patch
@@ -0,0 +1,276 @@
+From 6d80df97117b0918cb9192c7d58b55aed1779ecb Mon Sep 17 00:00:00 2001
+From: "A. Wilcox" <AWilcox@...>
+Date: Sun, 15 May 2022 05:04:10 +0000
+Subject: [PATCH] Make netgroup support optional
+
+On at least Linux/musl and Linux/uclibc, netgroup support is not
+available. PolKit fails to compile on these systems for that reason.
+
+This change makes netgroup support conditional on the presence of the
+setnetgrent(3) function which is required for the support to work. If
+that function is not available on the system, an error will be returned
+to the administrator if unix-netgroup: is specified in configuration.
+
+(sam: rebased for Meson and Duktape.)
+
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/issues/14
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/issues/163
+Closes: https://gitlab.freedesktop.org/polkit/polkit/-/merge_requests/52
+Signed-off-by: A. Wilcox <AWilcox@...>
+
+Ported back the change in configure.ac (upstream removed autotools
+support).
+
+Upstream-Status: Backport [https://gitlab.freedesktop.org/polkit/polkit/-/commit/b57deee8178190a7ecc75290fa13cf7daabc2c66]
+Signed-off-by: Marta Rybczynska <marta.rybczynska@...>
+
+---
+ configure.ac | 2 +-
+ meson.build | 1 +
+ src/polkit/polkitidentity.c | 17 +++++++++++++++++
+ src/polkit/polkitunixnetgroup.c | 3 +++
+ .../polkitbackendduktapeauthority.c | 4 ++--
+ .../polkitbackendinteractiveauthority.c | 14 ++++++++------
+ src/polkitbackend/polkitbackendjsauthority.cpp | 2 ++
+ test/polkit/polkitidentitytest.c | 8 +++++++-
+ test/polkit/polkitunixnetgrouptest.c | 2 ++
+ .../test-polkitbackendjsauthority.c | 2 ++
+ 10 files changed, 45 insertions(+), 10 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index bbf4768..f636ec5 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -117,7 +117,7 @@ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+ CC="$PTHREAD_CC"
+ AC_CHECK_FUNCS([pthread_condattr_setclock])
+
+-AC_CHECK_FUNCS(clearenv fdatasync)
++AC_CHECK_FUNCS(clearenv fdatasync setnetgrent)
+
+ if test "x$GCC" = "xyes"; then
+ LDFLAGS="-Wl,--as-needed $LDFLAGS"
+diff --git a/meson.build b/meson.build
+index 7506231..2d9d67a 100644
+--- a/meson.build
++++ b/meson.build
+@@ -82,6 +82,7 @@ config_h.set('_GNU_SOURCE', true)
+ check_functions = [
+ 'clearenv',
+ 'fdatasync',
++ 'setnetgrent',
+ ]
+
+ foreach func: check_functions
+diff --git a/src/polkit/polkitidentity.c b/src/polkit/polkitidentity.c
+index 3aa1f7f..793f17d 100644
+--- a/src/polkit/polkitidentity.c
++++ b/src/polkit/polkitidentity.c
+@@ -182,7 +182,15 @@ polkit_identity_from_string (const gchar *str,
+ }
+ else if (g_str_has_prefix (str, "unix-netgroup:"))
+ {
++#ifndef HAVE_SETNETGRENT
++ g_set_error (error,
++ POLKIT_ERROR,
++ POLKIT_ERROR_FAILED,
++ "Netgroups are not available on this machine ('%s')",
++ str);
++#else
+ identity = polkit_unix_netgroup_new (str + sizeof "unix-netgroup:" - 1);
++#endif
+ }
+
+ if (identity == NULL && (error != NULL && *error == NULL))
+@@ -344,6 +352,14 @@ polkit_identity_new_for_gvariant (GVariant *variant,
+ GVariant *v;
+ const char *name;
+
++#ifndef HAVE_SETNETGRENT
++ g_set_error (error,
++ POLKIT_ERROR,
++ POLKIT_ERROR_FAILED,
++ "Netgroups are not available on this machine");
++ goto out;
++#else
++
+ v = lookup_asv (details_gvariant, "name", G_VARIANT_TYPE_STRING, error);
+ if (v == NULL)
+ {
+@@ -353,6 +369,7 @@ polkit_identity_new_for_gvariant (GVariant *variant,
+ name = g_variant_get_string (v, NULL);
+ ret = polkit_unix_netgroup_new (name);
+ g_variant_unref (v);
++#endif
+ }
+ else
+ {
+diff --git a/src/polkit/polkitunixnetgroup.c b/src/polkit/polkitunixnetgroup.c
+index 8a2b369..83f8d4a 100644
+--- a/src/polkit/polkitunixnetgroup.c
++++ b/src/polkit/polkitunixnetgroup.c
+@@ -194,6 +194,9 @@ polkit_unix_netgroup_set_name (PolkitUnixNetgroup *group,
+ PolkitIdentity *
+ polkit_unix_netgroup_new (const gchar *name)
+ {
++#ifndef HAVE_SETNETGRENT
++ g_assert_not_reached();
++#endif
+ g_return_val_if_fail (name != NULL, NULL);
+ return POLKIT_IDENTITY (g_object_new (POLKIT_TYPE_UNIX_NETGROUP,
+ "name", name,
+diff --git a/src/polkitbackend/polkitbackendduktapeauthority.c b/src/polkitbackend/polkitbackendduktapeauthority.c
+index c89dbcf..f4b4304 100644
+--- a/src/polkitbackend/polkitbackendduktapeauthority.c
++++ b/src/polkitbackend/polkitbackendduktapeauthority.c
+@@ -1035,7 +1035,7 @@ js_polkit_user_is_in_netgroup (duk_context *cx)
+
+ user = duk_require_string (cx, 0);
+ netgroup = duk_require_string (cx, 1);
+-
++#ifdef HAVE_SETNETGRENT
+ if (innetgr (netgroup,
+ NULL, /* host */
+ user,
+@@ -1043,7 +1043,7 @@ js_polkit_user_is_in_netgroup (duk_context *cx)
+ {
+ is_in_netgroup = TRUE;
+ }
+-
++#endif
+ duk_push_boolean (cx, is_in_netgroup);
+ return 1;
+ }
+diff --git a/src/polkitbackend/polkitbackendinteractiveauthority.c b/src/polkitbackend/polkitbackendinteractiveauthority.c
+index 056d9a8..36c2f3d 100644
+--- a/src/polkitbackend/polkitbackendinteractiveauthority.c
++++ b/src/polkitbackend/polkitbackendinteractiveauthority.c
+@@ -2233,25 +2233,26 @@ get_users_in_net_group (PolkitIdentity *group,
+ GList *ret;
+
+ ret = NULL;
++#ifdef HAVE_SETNETGRENT
+ name = polkit_unix_netgroup_get_name (POLKIT_UNIX_NETGROUP (group));
+
+-#ifdef HAVE_SETNETGRENT_RETURN
++# ifdef HAVE_SETNETGRENT_RETURN
+ if (setnetgrent (name) == 0)
+ {
+ g_warning ("Error looking up net group with name %s: %s", name, g_strerror (errno));
+ goto out;
+ }
+-#else
++# else
+ setnetgrent (name);
+-#endif
++# endif /* HAVE_SETNETGRENT_RETURN */
+
+ for (;;)
+ {
+-#if defined(HAVE_NETBSD) || defined(HAVE_OPENBSD)
++# if defined(HAVE_NETBSD) || defined(HAVE_OPENBSD)
+ const char *hostname, *username, *domainname;
+-#else
++# else
+ char *hostname, *username, *domainname;
+-#endif
++# endif /* defined(HAVE_NETBSD) || defined(HAVE_OPENBSD) */
+ PolkitIdentity *user;
+ GError *error = NULL;
+
+@@ -2282,6 +2283,7 @@ get_users_in_net_group (PolkitIdentity *group,
+
+ out:
+ endnetgrent ();
++#endif /* HAVE_SETNETGRENT */
+ return ret;
+ }
+
+diff --git a/src/polkitbackend/polkitbackendjsauthority.cpp b/src/polkitbackend/polkitbackendjsauthority.cpp
+index 11e91c0..9ee0391 100644
+--- a/src/polkitbackend/polkitbackendjsauthority.cpp
++++ b/src/polkitbackend/polkitbackendjsauthority.cpp
+@@ -1291,6 +1291,7 @@ js_polkit_user_is_in_netgroup (JSContext *cx,
+
+ JS::CallArgs args = JS::CallArgsFromVp (argc, vp);
+
++#ifdef HAVE_SETNETGRENT
+ JS::RootedString usrstr (authority->priv->cx);
+ usrstr = args[0].toString();
+ user = JS_EncodeStringToUTF8 (cx, usrstr);
+@@ -1305,6 +1306,7 @@ js_polkit_user_is_in_netgroup (JSContext *cx,
+ {
+ is_in_netgroup = true;
+ }
++#endif
+
+ ret = true;
+
+diff --git a/test/polkit/polkitidentitytest.c b/test/polkit/polkitidentitytest.c
+index e91967b..2635c4c 100644
+--- a/test/polkit/polkitidentitytest.c
++++ b/test/polkit/polkitidentitytest.c
+@@ -145,11 +145,15 @@ struct ComparisonTestData comparison_test_data [] = {
+ {"unix-group:root", "unix-group:jane", FALSE},
+ {"unix-group:jane", "unix-group:jane", TRUE},
+
++#ifdef HAVE_SETNETGRENT
+ {"unix-netgroup:foo", "unix-netgroup:foo", TRUE},
+ {"unix-netgroup:foo", "unix-netgroup:bar", FALSE},
++#endif
+
+ {"unix-user:root", "unix-group:root", FALSE},
++#ifdef HAVE_SETNETGRENT
+ {"unix-user:jane", "unix-netgroup:foo", FALSE},
++#endif
+
+ {NULL},
+ };
+@@ -181,11 +185,13 @@ main (int argc, char *argv[])
+ g_test_add_data_func ("/PolkitIdentity/group_string_2", "unix-group:jane", test_string);
+ g_test_add_data_func ("/PolkitIdentity/group_string_3", "unix-group:users", test_string);
+
++#ifdef HAVE_SETNETGRENT
+ g_test_add_data_func ("/PolkitIdentity/netgroup_string", "unix-netgroup:foo", test_string);
++ g_test_add_data_func ("/PolkitIdentity/netgroup_gvariant", "unix-netgroup:foo", test_gvariant);
++#endif
+
+ g_test_add_data_func ("/PolkitIdentity/user_gvariant", "unix-user:root", test_gvariant);
+ g_test_add_data_func ("/PolkitIdentity/group_gvariant", "unix-group:root", test_gvariant);
+- g_test_add_data_func ("/PolkitIdentity/netgroup_gvariant", "unix-netgroup:foo", test_gvariant);
+
+ add_comparison_tests ();
+
+diff --git a/test/polkit/polkitunixnetgrouptest.c b/test/polkit/polkitunixnetgrouptest.c
+index 3701ba1..e1d211e 100644
+--- a/test/polkit/polkitunixnetgrouptest.c
++++ b/test/polkit/polkitunixnetgrouptest.c
+@@ -69,7 +69,9 @@ int
+ main (int argc, char *argv[])
+ {
+ g_test_init (&argc, &argv, NULL);
++#ifdef HAVE_SETNETGRENT
+ g_test_add_func ("/PolkitUnixNetgroup/new", test_new);
+ g_test_add_func ("/PolkitUnixNetgroup/set_name", test_set_name);
++#endif
+ return g_test_run ();
+ }
+diff --git a/test/polkitbackend/test-polkitbackendjsauthority.c b/test/polkitbackend/test-polkitbackendjsauthority.c
+index 2103b17..b187a2f 100644
+--- a/test/polkitbackend/test-polkitbackendjsauthority.c
++++ b/test/polkitbackend/test-polkitbackendjsauthority.c
+@@ -137,12 +137,14 @@ test_get_admin_identities (void)
+ "unix-group:users"
+ }
+ },
++#ifdef HAVE_SETNETGRENT
+ {
+ "net.company.action3",
+ {
+ "unix-netgroup:foo"
+ }
+ },
++#endif
+ };
+ guint n;
+
diff --git a/meta-oe/recipes-extended/polkit/polkit_0.119.bb b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
index 66bbf735f..773148fdd 100644
--- a/meta-oe/recipes-extended/polkit/polkit_0.119.bb
+++ b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
@@ -24,10 +24,10 @@ PACKAGECONFIG[consolekit] = ",,,consolekit"
PAM_SRC_URI = "file://polkit-1_pam.patch"
SRC_URI = "http://www.freedesktop.org/software/polkit/releases/polkit-${PV}.tar.gz \
${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \
- file://0003-make-netgroup-support-optional.patch \
file://0001-pkexec-local-privilege-escalation-CVE-2021-4034.patch \
file://0002-CVE-2021-4115-GHSL-2021-077-fix.patch \
file://0003-Added-support-for-duktape-as-JS-engine.patch \
+ file://0004-Make-netgroup-support-optional.patch \
"
SRC_URI[sha256sum] = "c8579fdb86e94295404211285fee0722ad04893f0213e571bd75c00972fd1f5c"

--
2.33.0


[meta-oe][ 1/1] fluentbit Upgrade to 1.3.5 -> 1.9.6

Paulo Neves
 

Signed-off-by: Paulo Neves <ptsneves@...>
---
...t-Do-not-use-private-makefile-target.patch | 68 +++++++++++++++
...nit-install-location-with-SYSTEM_DIR.patch | 28 -------
...caused-by-using-flb_free-instead-of-.patch | 43 ----------
...-ppc-Fix-signature-for-co_create-API.patch | 38 ---------
...-not-hardcode-compilation-directorie.patch | 26 ++++++
...GV-caused-by-using-flb_free-instead-.patch | 82 -------------------
...0003-mbedtls-Do-not-overwrite-CFLAGS.patch | 25 ++++++
.../fluentbit/fluentbit/builtin-nan.patch | 27 ------
.../cross-build-init-system-detection.patch | 38 ---------
...{fluentbit_1.3.5.bb => fluentbit_1.9.6.bb} | 44 +++++-----
10 files changed, 139 insertions(+), 280 deletions(-)
create mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch
create mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch
create mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch
delete mode 100644 meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch
rename meta-oe/recipes-extended/fluentbit/{fluentbit_1.3.5.bb => fluentbit_1.9.6.bb} (53%)

diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch
new file mode 100644
index 000000000..0a80a92ed
--- /dev/null
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch
@@ -0,0 +1,68 @@
+From 6a704ab7bf69cd5d6970b3a7d3ae7798b26027c1 Mon Sep 17 00:00:00 2001
+From: Paulo Neves <ptsneves@...>
+Date: Thu, 28 Jul 2022 11:28:41 +0200
+Subject: [PATCH] CMakeLists.txt Do not use private makefile $< target
+
+$< is a private detail from the Makefile generated by CMakefile and
+are not under control or to be used at the CMakeLists level. In 3.20
+that private generation changed pre-requisite targets[1] and now logs
+contain the path compiler_depend.ts instead of the actual file.
+---
+ CMakeLists.txt | 6 +-----
+ lib/chunkio/CMakeLists.txt | 7 +------
+ lib/cmetrics/CMakeLists.txt | 7 +------
+ 3 files changed, 3 insertions(+), 17 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 3dba5a8..d94b988 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -46,11 +46,7 @@ else()
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall")
+ endif()
+
+-if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$(subst ${CMAKE_SOURCE_DIR}/,,$(abspath $<))\"'")
+-else()
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+-endif()
++set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+
+ if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "armv7l")
+ set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} -latomic")
+diff --git a/lib/chunkio/CMakeLists.txt b/lib/chunkio/CMakeLists.txt
+index bbe1f39..809ea93 100644
+--- a/lib/chunkio/CMakeLists.txt
++++ b/lib/chunkio/CMakeLists.txt
+@@ -14,12 +14,7 @@ else()
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall ")
+ endif()
+
+-# Set __FILENAME__
+-if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$(subst ${CMAKE_SOURCE_DIR}/,,$(abspath $<))\"'")
+-else()
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+-endif()
++set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+
+ include(cmake/macros.cmake)
+
+diff --git a/lib/cmetrics/CMakeLists.txt b/lib/cmetrics/CMakeLists.txt
+index 60e8774..e3d6149 100644
+--- a/lib/cmetrics/CMakeLists.txt
++++ b/lib/cmetrics/CMakeLists.txt
+@@ -34,12 +34,7 @@ set(CMT_VERSION_MINOR 3)
+ set(CMT_VERSION_PATCH 5)
+ set(CMT_VERSION_STR "${CMT_VERSION_MAJOR}.${CMT_VERSION_MINOR}.${CMT_VERSION_PATCH}")
+
+-# Define __FILENAME__ consistently across Operating Systems
+-if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Windows")
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$(subst ${CMAKE_SOURCE_DIR}/,,$(abspath $<))\"'")
+-else()
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+-endif()
++set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__")
+
+ # Configuration options
+ option(CMT_DEV "Enable development mode" No)
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch
deleted file mode 100644
index bf4cda08f..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 5571f949fa2048b79c197b5b10a11ecb1891cbe9 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@...>
-Date: Sat, 23 Apr 2022 08:24:34 -0700
-Subject: [PATCH] Control sytemd unit install location with SYSTEM_DIR
-
-This helps building when usrmerge is on
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@...>
----
- src/CMakeLists.txt | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
---- a/src/CMakeLists.txt
-+++ b/src/CMakeLists.txt
-@@ -323,7 +323,11 @@ if(FLB_BINARY)
- "${PROJECT_SOURCE_DIR}/init/systemd.in"
- ${FLB_SYSTEMD_SCRIPT}
- )
-- install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION /lib/systemd/system)
-+ if(SYSTEMD_DIR)
-+ install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION ${SYSTEMD_DIR})
-+ else()
-+ install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION /lib/systemd/system)
-+ endif()
- install(DIRECTORY DESTINATION ${FLB_INSTALL_CONFDIR})
- elseif(FLB_UPSTART)
- set(FLB_UPSTART_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.conf")
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch
deleted file mode 100644
index a6ff5991c..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 3d7390c89c2205d1eed0384be0bb65adb675e60d Mon Sep 17 00:00:00 2001
-From: Ramon Fried <ramon@...>
-Date: Tue, 9 Feb 2021 18:59:59 +0200
-Subject: [PATCH] bin: fix SIGSEGV caused by using flb_free instead of
- mk_mem_free
-
-Upstream-Status: Accepted
-Signed-off-by: Ramon Fried <ramon@...>
----
- src/fluent-bit.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/src/fluent-bit.c b/src/fluent-bit.c
-index c0c73b4..989cfde 100644
---- a/src/fluent-bit.c
-+++ b/src/fluent-bit.c
-@@ -289,7 +289,7 @@ static int input_set_property(struct flb_input_instance *in, char *kv)
- in->p->name, key);
- }
-
-- flb_free(key);
-+ mk_mem_free(key);
- return ret;
- }
-
-@@ -314,7 +314,7 @@ static int output_set_property(struct flb_output_instance *out, char *kv)
- }
-
- ret = flb_output_set_property(out, key, value);
-- flb_free(key);
-+ mk_mem_free(key);
- return ret;
- }
-
-@@ -340,7 +340,7 @@ static int filter_set_property(struct flb_filter_instance *filter, char *kv)
- }
-
- ret = flb_filter_set_property(filter, key, value);
-- flb_free(key);
-+ mk_mem_free(key);
- return ret;
- }
-
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch
deleted file mode 100644
index 1f36c657e..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-ppc-Fix-signature-for-co_create-API.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From be4032079c931704f52e29f5da5c01cde24ac842 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@...>
-Date: Thu, 16 Jan 2020 10:44:58 -0800
-Subject: [PATCH] ppc: Fix signature for co_create API
-
-Upstream-Status: Submitted [https://github.com/fluent/fluent-bit/pull/1886]
-Signed-off-by: Khem Raj <raj.khem@...>
----
- lib/flb_libco/ppc.c | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/lib/flb_libco/ppc.c b/lib/flb_libco/ppc.c
-index e6536d56..533256b3 100644
---- a/lib/flb_libco/ppc.c
-+++ b/lib/flb_libco/ppc.c
-@@ -279,7 +279,9 @@ static uint32_t* co_create_(unsigned size, uintptr_t entry) {
- return t;
- }
-
--cothread_t co_create(unsigned int size, void (*entry_)(void)) {
-+cothread_t co_create(unsigned int size, void (*entry_)(void),
-+ size_t *out_size) {
-+
- uintptr_t entry = (uintptr_t)entry_;
- uint32_t* t = 0;
-
-@@ -325,7 +327,7 @@ cothread_t co_create(unsigned int size, void (*entry_)(void)) {
- t[10] = (uint32_t)(sp >> shift >> shift);
- t[11] = (uint32_t)sp;
- }
--
-+ *out_size = size;
- return t;
- }
-
---
-2.25.0
-
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch
new file mode 100644
index 000000000..4358b2a51
--- /dev/null
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch
@@ -0,0 +1,26 @@
+From 71dab751a27a2e582b711de22873065dd28f4b65 Mon Sep 17 00:00:00 2001
+From: Paulo Neves <ptsneves@...>
+Date: Thu, 28 Jul 2022 11:42:31 +0200
+Subject: [PATCH] flb_info.h.in: Do not hardcode compilation directories
+
+Including the source dir in the header makes the header not
+reproducible and contaminates it with host builder paths. Instead
+make it take CMAKE_DEBUG_SRCDIR that can be set to a known
+reproducible value
+---
+ include/fluent-bit/flb_info.h.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/fluent-bit/flb_info.h.in b/include/fluent-bit/flb_info.h.in
+index a89485c..2579afc 100644
+--- a/include/fluent-bit/flb_info.h.in
++++ b/include/fluent-bit/flb_info.h.in
+@@ -23,7 +23,7 @@
+ #define STR_HELPER(s) #s
+ #define STR(s) STR_HELPER(s)
+
+-#define FLB_SOURCE_DIR "@CMAKE_SOURCE_DIR@"
++#define FLB_SOURCE_DIR "@CMAKE_DEBUG_SRCDIR@"
+
+ /* General flags set by CMakeLists.txt */
+ @FLB_BUILD_FLAGS@
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch
deleted file mode 100644
index 91675dfc6..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From 7c3b1dfb174312594d3317c24ed71c60398f653f Mon Sep 17 00:00:00 2001
-From: Ramon Fried <ramon@...>
-Date: Wed, 10 Feb 2021 04:23:36 +0200
-Subject: [PATCH] parser: Fix SIGSEGV caused by using flb_free instead of
- mk_mem_free
-
-Upstream-Status: Backport (fix only for 1.3.5)
-Signed-off-by: Ramon Fried <ramon@...>
----
- src/flb_parser.c | 28 ++++++++++++++--------------
- 1 file changed, 14 insertions(+), 14 deletions(-)
-
-diff --git a/src/flb_parser.c b/src/flb_parser.c
-index d35c568..7c20e12 100644
---- a/src/flb_parser.c
-+++ b/src/flb_parser.c
-@@ -490,7 +490,7 @@ int flb_parser_conf_file(const char *file, struct flb_config *config)
- MK_RCONF_STR);
- if (str) {
- time_keep = flb_utils_bool(str);
-- flb_free(str);
-+ mk_mem_free(str);
- }
- else {
- time_keep = FLB_FALSE;
-@@ -522,23 +522,23 @@ int flb_parser_conf_file(const char *file, struct flb_config *config)
-
- flb_debug("[parser] new parser registered: %s", name);
-
-- flb_free(name);
-- flb_free(format);
-+ mk_mem_free(name);
-+ mk_mem_free(format);
-
- if (regex) {
-- flb_free(regex);
-+ mk_mem_free(regex);
- }
- if (time_fmt) {
-- flb_free(time_fmt);
-+ mk_mem_free(time_fmt);
- }
- if (time_key) {
-- flb_free(time_key);
-+ mk_mem_free(time_key);
- }
- if (time_offset) {
-- flb_free(time_offset);
-+ mk_mem_free(time_offset);
- }
- if (types_str) {
-- flb_free(types_str);
-+ mk_mem_free(types_str);
- }
-
- decoders = NULL;
-@@ -548,19 +548,19 @@ int flb_parser_conf_file(const char *file, struct flb_config *config)
- return 0;
-
- fconf_error:
-- flb_free(name);
-- flb_free(format);
-+ mk_mem_free(name);
-+ mk_mem_free(format);
- if (regex) {
-- flb_free(regex);
-+ mk_mem_free(regex);
- }
- if (time_fmt) {
-- flb_free(time_fmt);
-+ mk_mem_free(time_fmt);
- }
- if (time_key) {
-- flb_free(time_key);
-+ mk_mem_free(time_key);
- }
- if (types_str) {
-- flb_free(types_str);
-+ mk_mem_free(types_str);
- }
- if (decoders) {
- flb_parser_decoder_list_destroy(decoders);
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch
new file mode 100644
index 000000000..0611af9ec
--- /dev/null
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0003-mbedtls-Do-not-overwrite-CFLAGS.patch
@@ -0,0 +1,25 @@
+From 8486b912281ae85db0c9fc05bb546f16872e114c Mon Sep 17 00:00:00 2001
+From: Paulo Neves <ptsneves@...>
+Date: Thu, 28 Jul 2022 14:37:18 +0200
+Subject: [PATCH] mbedtls: Do not overwrite CFLAGS
+
+bitbake passes CFLAGS that are often in conflict with the ones set
+in mbedtls' CMakeLists.txt. Such conflicts are the inability to use
+FORTIFY_SOURCE=2 except in release mode
+---
+ lib/mbedtls-2.28.0/CMakeLists.txt | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/lib/mbedtls-2.28.0/CMakeLists.txt b/lib/mbedtls-2.28.0/CMakeLists.txt
+index d76bddc..e717846 100644
+--- a/lib/mbedtls-2.28.0/CMakeLists.txt
++++ b/lib/mbedtls-2.28.0/CMakeLists.txt
+@@ -204,8 +204,6 @@ if(CMAKE_COMPILER_IS_GNU)
+ if (GCC_VERSION VERSION_GREATER 7.0 OR GCC_VERSION VERSION_EQUAL 7.0)
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wformat-overflow=2 -Wformat-truncation")
+ endif()
+- set(CMAKE_C_FLAGS_RELEASE "-O2")
+- set(CMAKE_C_FLAGS_DEBUG "-O0 -g3")
+ set(CMAKE_C_FLAGS_COVERAGE "-O0 -g3 --coverage")
+ set(CMAKE_C_FLAGS_ASAN "-fsanitize=address -fno-common -fsanitize=undefined -fno-sanitize-recover=all -O3")
+ set(CMAKE_C_FLAGS_ASANDBG "-fsanitize=address -fno-common -fsanitize=undefined -fno-sanitize-recover=all -O1 -g3 -fno-omit-frame-pointer -fno-optimize-sibling-calls")
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch
deleted file mode 100644
index 8ffc3be3e..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/builtin-nan.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-help complier to use intrinsics, clang in few cases e.g. aarch64 can not
-and then requires linking with libm, its the only function needed from libm then
-its good to avoid needing it.
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@...>
-
---- a/include/fluent-bit/stream_processor/flb_sp_timeseries.h
-+++ b/include/fluent-bit/stream_processor/flb_sp_timeseries.h
-@@ -207,7 +207,7 @@ void cb_forecast_calc(struct timeseries
- result = b0 + b1 * (val->f64 + *forecast->latest_x);
- break;
- default:
-- result = nan("");
-+ result = __builtin_nan("");
- break;
- }
-
-@@ -283,7 +283,7 @@ void cb_forecast_r_calc(struct timeserie
- result = ((val->i64 - b0) / b1) - *forecast->latest_x;
- break;
- default:
-- result = nan("");
-+ result = __builtin_nan("");
- break;
- }
-
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch
deleted file mode 100644
index d3822fc8d..000000000
--- a/meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-Define CMake variables to indicate init system for target
-incase of cross compile, detecting systemd support based on
-host directory structure is not right thing to do
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.kheem@...>
-
---- a/src/CMakeLists.txt
-+++ b/src/CMakeLists.txt
-@@ -317,7 +317,7 @@ if(FLB_BINARY)
- install(TARGETS fluent-bit-bin RUNTIME DESTINATION ${FLB_INSTALL_BINDIR})
-
- # Detect init system, install upstart, systemd or init.d script
-- if(IS_DIRECTORY /lib/systemd/system)
-+ if(FLB_SYSTEMD)
- set(FLB_SYSTEMD_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.service")
- configure_file(
- "${PROJECT_SOURCE_DIR}/init/systemd.in"
-@@ -325,7 +325,7 @@ if(FLB_BINARY)
- )
- install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION /lib/systemd/system)
- install(DIRECTORY DESTINATION ${FLB_INSTALL_CONFDIR})
-- elseif(IS_DIRECTORY /usr/share/upstart)
-+ elseif(FLB_UPSTART)
- set(FLB_UPSTART_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.conf")
- configure_file(
- "${PROJECT_SOURCE_DIR}/init/upstart.in"
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -70,6 +70,8 @@ option(FLB_RECORD_ACCESSOR "Enable re
- option(FLB_SYSTEM_STRPTIME "Use strptime in system libc" Yes)
- option(FLB_STATIC_CONF "Build binary using static configuration")
- option(FLB_STREAM_PROCESSOR "Enable Stream Processor" Yes)
-+option(FLB_SYSTEMD "Enable systemd init system" No)
-+option(FLB_UPSTART "Enable upstart init system" No)
- option(FLB_CORO_STACK_SIZE "Set coroutine stack size")
-
- # Metrics: Experimental Feature, disabled by default on 0.12 series
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit_1.3.5.bb b/meta-oe/recipes-extended/fluentbit/fluentbit_1.9.6.bb
similarity index 53%
rename from meta-oe/recipes-extended/fluentbit/fluentbit_1.3.5.bb
rename to meta-oe/recipes-extended/fluentbit/fluentbit_1.9.6.bb
index b231cc287..1ff62767d 100644
--- a/meta-oe/recipes-extended/fluentbit/fluentbit_1.3.5.bb
+++ b/meta-oe/recipes-extended/fluentbit/fluentbit_1.9.6.bb
@@ -11,25 +11,28 @@ LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://LICENSE;md5=2ee41112a44fe7014dce33e26468ba93"
SECTION = "net"

-SRC_URI = "http://fluentbit.io/releases/1.3/fluent-bit-${PV}.tar.gz \
+PR = "r0"
+PV = "1.9.6"
+
+SRC_URI = "https://releases.fluentbit.io/1.9/source-${PV}.tar.gz;subdir=fluent-bit-${PV} \
+ file://0001-CMakeLists.txt-Do-not-use-private-makefile-target.patch \
+ file://0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch \
+ file://0003-mbedtls-Do-not-overwrite-CFLAGS.patch \
file://jemalloc.patch \
- file://cross-build-init-system-detection.patch \
- file://builtin-nan.patch \
- file://0001-ppc-Fix-signature-for-co_create-API.patch \
- file://0001-bin-fix-SIGSEGV-caused-by-using-flb_free-instead-of-.patch \
- file://0002-parser-Fix-SIGSEGV-caused-by-using-flb_free-instead-.patch \
- file://0001-Control-sytemd-unit-install-location-with-SYSTEM_DIR.patch \
"
-SRC_URI[md5sum] = "6eae6dfd0a874e5dd270c36e9c68f747"
-SRC_URI[sha256sum] = "e037c76c89269c8dc4027a08e442fefd2751b0f1e0f9c38f9a4b12d781a9c789"
+SRC_URI[md5sum] = "ad65bb3ca55d203a467a63426e17bfae"
+SRC_URI[sha256sum] = "5ef7dd97e10936269fe5f4e5d3ebf16559333066f7d6757ba12464a9d6186570"

S = "${WORKDIR}/fluent-bit-${PV}"
-DEPENDS = "zlib bison-native flex-native"
+DEPENDS = "zlib bison-native flex-native openssl"
DEPENDS += "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
-
+PACKAGECONFIG[yaml] = "-DFLB_CONFIG_YAML=On,-DFLB_CONFIG_YAML=Off, yaml,"
+PACKAGECONFIG[kafka] = "-DFLB_OUT_KAFKA=On,-DFLB_OUT_KAFKA=Off,librdkafka"
+PACKAGECONFIG[examples] = "-DFLB_EXAMPLES=On,-DFLB_EXAMPLES=Off"
+PACKAGECONFIG[jemalloc] = "-DFLB_JEMALLOC=On,-DFLB_JEMALLOC=Off,jemalloc"
DEPENDS:append:libc-musl = " fts "

-INSANE_SKIP:${PN}-dev += "dev-elf"
+PACKAGECONFIG ?= "yaml"

LTO = ""

@@ -40,13 +43,13 @@ OECMAKE_GENERATOR ?= "Unix Makefiles"
# ========================

# Host related setup
-EXTRA_OECMAKE += "-DGNU_HOST=${HOST_SYS} -DFLB_ALL=ON -DFLB_TD=1"
+EXTRA_OECMAKE += "-DGNU_HOST=${HOST_SYS} -DFLB_TD=1"

# Disable LuaJIT and filter_lua support
EXTRA_OECMAKE += "-DFLB_LUAJIT=Off -DFLB_FILTER_LUA=Off "

# Disable Library and examples
-EXTRA_OECMAKE += "-DFLB_SHARED_LIB=Off -DFLB_EXAMPLES=Off "
+EXTRA_OECMAKE += "-DFLB_SHARED_LIB=Off"

# Enable systemd iff systemd is in DISTRO_FEATURES
EXTRA_OECMAKE += "${@bb.utils.contains('DISTRO_FEATURES','systemd','-DFLB_SYSTEMD=On -DSYSTEMD_DIR=${systemd_system_unitdir}','-DFLB_SYSTEMD=Off',d)}"
@@ -54,16 +57,9 @@ EXTRA_OECMAKE += "${@bb.utils.contains('DISTRO_FEATURES','systemd','-DFLB_SYSTEM
EXTRA_OECMAKE:append:riscv64 = " -DFLB_DEPS='atomic'"
EXTRA_OECMAKE:append:riscv32 = " -DFLB_DEPS='atomic'"

-# Kafka Output plugin (disabled by default): note that when
-# enabling Kafka output plugin, the backend library librdkafka
-# requires 'openssl' as a dependency.
-#
-# DEPENDS += "openssl "
-# EXTRA_OECMAKE += "-DFLB_OUT_KAFKA=On "
-
inherit cmake systemd

-CFLAGS += "-fcommon"
-
SYSTEMD_SERVICE:${PN} = "td-agent-bit.service"
-TARGET_CC_ARCH:append = " ${SELECTED_OPTIMIZATION}"
+
+EXTRA_OECMAKE += "-DCMAKE_DEBUG_SRCDIR=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}/"
+TARGET_CC_ARCH += " ${SELECTED_OPTIMIZATION}"
--
2.25.1


[meta-oe][master][kirkstone][PATCH] polkit: Add --shell /bin/nologin to polkitd user

akash hadke
 

polkitd user has default access to /bin/sh, add --shell /bin/nologin
to remove default access to /bin/sh and avoid login through it.

Signed-off-by: Akash Hadke <akash.hadke@...>
---
meta-oe/recipes-extended/polkit/polkit_0.119.bb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta-oe/recipes-extended/polkit/polkit_0.119.bb b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
index bf160053d9..4ce5f0e045 100644
--- a/meta-oe/recipes-extended/polkit/polkit_0.119.bb
+++ b/meta-oe/recipes-extended/polkit/polkit_0.119.bb
@@ -71,7 +71,7 @@ FILES:${PN}:append = " \
FILES:${PN}-examples = "${bindir}/*example*"

USERADD_PACKAGES = "${PN}"
-USERADD_PARAM:${PN} = "--system --no-create-home --user-group --home-dir ${sysconfdir}/${BPN}-1 polkitd"
+USERADD_PARAM:${PN} = "--system --no-create-home --user-group --home-dir ${sysconfdir}/${BPN}-1 --shell /bin/nologin polkitd"

SYSTEMD_SERVICE:${PN} = "${BPN}.service"
SYSTEMD_AUTO_ENABLE = "disable"
--
2.17.1


Re: [yocto] [meta-zephyr][PATCH v2] zephyr-kernel-src: bump the v3 version to v3.1.0

Naveen Saini
 

-----Original Message-----
From: yocto@... <yocto@...> On
Behalf Of Jon Mason
Sent: Tuesday, July 26, 2022 10:45 PM
To: Bartosz Golaszewski <brgl@...>
Cc: Saini, Naveen Kumar <naveen.kumar.saini@...>; Eilís Ní
Fhlannagáin <elizabeth.flanagan@...>;
yocto@...; openembedded-
devel@...; Bartosz Golaszewski
<bartosz.golaszewski@...>
Subject: Re: [yocto] [meta-zephyr][PATCH v2] zephyr-kernel-src: bump the
v3 version to v3.1.0

On Tue, Jul 26, 2022 at 02:45:10PM +0200, Bartosz Golaszewski wrote:
From: Bartosz Golaszewski <bartosz.golaszewski@...>

This upgrades the 3.x series to using v3.1.0.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@...>
---
- add a rebased version of the toolchain patch for v3.1
intel-x86-64 machine isn't happy
It looks like it's not able to find stdint.h

https://gitlab.com/jonmason00/meta-zephyr/-/jobs/2771910955


... 0001-2.7-cmake-add-yocto-toolchain.patch} | 0
.../0001-3.1-cmake-add-yocto-toolchain.patch | 63 +++++++++++++++
.../zephyr-kernel/zephyr-kernel-src-2.7.2.inc | 7 +-
.../zephyr-kernel/zephyr-kernel-src-3.0.0.inc | 70 -----------------
.../zephyr-kernel/zephyr-kernel-src-3.1.0.inc | 76 +++++++++++++++++++
.../zephyr-kernel/zephyr-kernel-src.inc | 5 +-
6 files changed, 146 insertions(+), 75 deletions(-) rename
meta-zephyr-core/recipes-kernel/zephyr-kernel/files/{0001-cmake-add-
yo
cto-toolchain.patch => 0001-2.7-cmake-add-yocto-toolchain.patch}
(100%) create mode 100644
meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-3.1-cmake-add
-yocto-toolchain.patch delete mode 100644
meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-3.0.0.
inc create mode 100644
meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-3.1.0.
inc

diff --git
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-cmake-add-
y
octo-toolchain.patch
b/meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-2.7-cmake-a
dd-yocto-toolchain.patch
similarity index 100%
rename from
meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-cmake-add-
yoc
to-toolchain.patch rename to
meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-2.7-cmake-add
-yocto-toolchain.patch diff --git
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-3.1-cmake-a
dd-yocto-toolchain.patch
b/meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-3.1-cmake-a
dd-yocto-toolchain.patch
new file mode 100644
index 0000000..a16eabf
--- /dev/null
+++ b/meta-zephyr-core/recipes-kernel/zephyr-kernel/files/0001-3.1-cma
+++ ke-add-yocto-toolchain.patch
@@ -0,0 +1,63 @@
+From 39f1dd116d00b6c2135c4ccd216341dcd2f2917e Mon Sep 17 00:00:00
+2001
+From: Naveen Saini <naveen.kumar.saini@...>
+Date: Tue, 26 Jul 2022 14:12:18 +0200
+Subject: [PATCH] cmake: add yocto toolchain
+
+Upstream status: inappropriate [OE specific]
+
+Signed-off-by: Naveen Saini <naveen.kumar.saini@...>
+---
+ cmake/compiler/gcc/target.cmake | 7 -------
+ cmake/toolchain/yocto/generic.cmake | 13 +++++++++++++
+cmake/toolchain/yocto/target.cmake | 1 +
+ 3 files changed, 14 insertions(+), 7 deletions(-) create mode
+100644 cmake/toolchain/yocto/generic.cmake
+ create mode 100644 cmake/toolchain/yocto/target.cmake
+
+diff --git a/cmake/compiler/gcc/target.cmake
+b/cmake/compiler/gcc/target.cmake index 014447e67e..b510f47d59
100644
+--- a/cmake/compiler/gcc/target.cmake
++++ b/cmake/compiler/gcc/target.cmake
+@@ -94,13 +94,6 @@ execute_process(
+ OUTPUT_STRIP_TRAILING_WHITESPACE
+ )
+
+-assert_exists(LIBGCC_FILE_NAME)
+-
+-get_filename_component(LIBGCC_DIR ${LIBGCC_FILE_NAME}
DIRECTORY)
+-
+-assert_exists(LIBGCC_DIR)
+-
+-LIST(APPEND LIB_INCLUDE_DIR "-L\"${LIBGCC_DIR}\"") LIST(APPEND
+TOOLCHAIN_LIBS gcc)
+
+ # For CMake to be able to test if a compiler flag is supported by
+the diff --git a/cmake/toolchain/yocto/generic.cmake
+b/cmake/toolchain/yocto/generic.cmake
+new file mode 100644
+index 0000000000..45e5777e2a
+--- /dev/null
++++ b/cmake/toolchain/yocto/generic.cmake
+@@ -0,0 +1,13 @@
++set(COMPILER gcc)
++set(LINKER ld)
++set(BINTOOLS gnu)
++
++set(ZEPHYR_SYSROOT ${ZEPHYR_SYSROOT}) set(SYSROOT_DIR
++${ZEPHYR_SYSROOT}) set(LIBC_LIBRARY_DIR "\"${SYSROOT_DIR}\"/")
++set(LIBC_INCLUDE_DIR ${SYSROOT_DIR}/include) LIST(APPEND
++TOOLCHAIN_LIBS gcc)
++
++LIST(APPEND LIB_INCLUDE_DIR "-L\"${STAGING_LIBDIR}\"")
++
++set(TOOLCHAIN_LIBS gcc)
+diff --git a/cmake/toolchain/yocto/target.cmake
+b/cmake/toolchain/yocto/target.cmake
+new file mode 100644
+index 0000000000..9881313609
+--- /dev/null
++++ b/cmake/toolchain/yocto/target.cmake
+@@ -0,0 +1 @@
++# SPDX-License-Identifier: Apache-2.0
+--
+2.34.1
+
diff --git
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-2.7.
2.inc
b/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-2.7.
2.inc
index 7a4da21..537a565 100644
---
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-2.7.
2.inc
+++ b/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-
+++ 2.7.2.inc
@@ -62,4 +62,9 @@ SRCREV_tfm =
"c74be3890c9d975976fde1b1a3b2f5742bec34c0"
ZEPHYR_BRANCH = "v2.7-branch"
PV = "2.7.2+git${SRCPV}"

-SRC_URI:append = " file://dtc.patch"
+SRC_URI:append = " \
+ file://dtc.patch \
+ file://0001-x86-fix-efi-binary-generation-issue-in-cross-compila.patch \
+ file://0001-2.7-cmake-add-yocto-toolchain.patch \
+
+git://github.com/zephyrproject-
rtos/hal_cypress.git;protocol=https;nobranch=1;destsuffix=git/modules/hal/
cypress;name=cypress \ "
diff --git
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-3.0.
0.inc
b/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-3.0.
0.inc
deleted file mode 100644
index 64594a0..0000000
---
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-3.0.
0.inc
+++ /dev/null
@@ -1,70 +0,0 @@
-SRCREV_FORMAT = "default_cmsis"
-
-#
-# Generated with:
-#
-# #!/usr/bin/python3
-#
-# import yaml
-# import sys
-#
-# if __name__ == "__main__":
-# with open(sys.argv[1], "r") as fd:
-# data = yaml.safe_load(fd)
-#
-# for project in data["manifest"]["projects"]:
-# print("SRCREV_{} = \"{}\"".format(project["name"],
project["revision"]))
-#
-
-SRCREV_default = "4f8d78ceeb436e82f528511998515f6fc137c6cd"
-SRCREV_canopennode = "1052dae561497bef901f931ef75e117c9224aecd"
-SRCREV_civetweb = "094aeb41bb93e9199d24d665ee43e9e05d6d7b1c"
-SRCREV_cmsis = "b0612c97c1401feeb4160add6462c3627fe90fc7"
-SRCREV_edtt = "1fc2e6f7d2a01a01074456f2ef2ccf1f3df7fac1"
-SRCREV_fatfs = "09a9d913c61dccbb8ff92d8943b452c614ac5292"
-SRCREV_fff = "6ce5ba26486e93d5b7696a3e23f0585932c14b16"
-SRCREV_altera = "23c1c1dd7a0c1cc9a399509d1819375847c95b97"
-SRCREV_atmel = "9f78f520f6cbb997e5b44fe8ab17dd5bf2448095"
-SRCREV_cypress = "81a059f21435bc7e315bccd720da5a9b615bbb50"
-SRCREV_espressif = "bcd7565ffa390d5774dc2fbe71a002faa9a7d082"
-SRCREV_gigadevice = "242a7f4be7a3136606c7a65169775f7ef85ad444"
-SRCREV_infineon = "f1fa8241f8786198ba41155413243de36ed878a5"
-SRCREV_microchip = "870d05e6a64ea9548da6b907058b03c8c9420826"
-SRCREV_nordic = "a42b016d7c7610489f5f8c79773fedc05ba352ee"
-SRCREV_nuvoton = "b4d31f33238713a568e23618845702fadd67386f"
-SRCREV_nxp = "9629f15fd80169cc9669e3fbb1260467c3aeb175"
-SRCREV_openisa = "40d049f69c50b58ea20473bee14cf93f518bf262"
-SRCREV_quicklogic = "b3a66fe6d04d87fd1533a5c8de51d0599fcd08d0"
-SRCREV_rpi_pico = "191f5ba46fda49523cdaaef27583d1c875ba2c36"
-SRCREV_silabs = "be39d4eebeddac6e18e9c0c3ba1b31ad1e82eaed"
-SRCREV_st = "575de9d461aa6f430cf62c58a053675377e700f3"
-SRCREV_stm32 = "300109f80730cb2477bfcc706a6602b9870336b3"
-SRCREV_telink = "ffcfd6282aa213f1dc0848dbca6279b098f6b143"
-SRCREV_ti = "1992a4c536554c4f409c36896eda6abdc414d277"
-SRCREV_xtensa = "0e577021bb66e644afd067cd9f7c71ab11b62b3d"
-SRCREV_libmetal = "f237c9d420a51cc43bc37d744e41191ad613f348"
-SRCREV_littlefs = "33509ed9c3d369cdb9d909cd40c5eea8f64a902c"
-SRCREV_loramac-node = "12019623bbad9eb54fe51066847a7cbd4b4eac57"
-SRCREV_lvgl = "783c1f78c8e39751fe89d0883c8bce7336f55e94"
-SRCREV_lz4 = "8e303c264fc21c2116dc612658003a22e933124d"
-SRCREV_mbedtls = "3e3e58a92de76069730c63e0d524f40fea948a61"
-SRCREV_mcuboot = "89936c338e46f43cb177a8b928cd80b90f3ace8f"
-SRCREV_mipi-sys-t = "d9da086b11cda494d85f4d8a9829f505c2d5e380"
-SRCREV_nanopb = "d148bd26718e4c10414f07a7eb1bd24c62e56c5d"
-SRCREV_net-tools = "f49bd1354616fae4093bf36e5eaee43c51a55127"
-SRCREV_nrf_hw_models =
"b8cea37dbdc8fc58cc14b4e19fa850877a9da520"
-SRCREV_open-amp = "cfd050ff38a9d028dc211690b2ec35971128e45e"
-SRCREV_openthread = "b7aa7686d3f4e326bd25abc234b209159977c26d"
-SRCREV_segger = "3a52ab222133193802d3c3b4d21730b9b1f1d2f6"
-SRCREV_sof = "500d77e0ac84ac2c969e0d4b2142cca192e893bc"
-SRCREV_tflite-micro = "9156d050927012da87079064db59d07f03b8baf6"
-SRCREV_tinycbor = "40daca97b478989884bffb5226e9ab73ca54b8c4"
-SRCREV_tinycrypt = "3e9a49d2672ec01435ffbf0d788db6d95ef28de0"
-SRCREV_TraceRecorderSource =
"e8ca3b6a83d19b2fc4738a0d9607190436e5e452"
-SRCREV_trusted-firmware-m =
"5d32c3e64b3d589548e881eeeeb37d84944c90af"
-SRCREV_tf-m-tests = "52814181f0fde6d1422fac204d42cde30c62e40e"
-SRCREV_psa-arch-tests = "0aab24602cbef30f6422e7ef1066a8473073e586"
-SRCREV_zscilib = "12bfe3f0a9fcbfe3edab7eabc9678b6c62875d34"
-
-ZEPHYR_BRANCH = "v3.0-branch"
-PV = "3.0.0+git${SRCPV}"
diff --git
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-3.1.
0.inc
b/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-3.1.
0.inc
new file mode 100644
index 0000000..f38d7f9
--- /dev/null
+++ b/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src-
+++ 3.1.0.inc
@@ -0,0 +1,76 @@
+SRCREV_FORMAT = "default_cmsis"
+
+#
+# Generated with:
+#
+# #!/usr/bin/python3
+#
+# import yaml
+# import sys
+#
+# if __name__ == "__main__":
+# with open(sys.argv[1], "r") as fd:
+# data = yaml.safe_load(fd)
+#
+# for project in data["manifest"]["projects"]:
+# print("SRCREV_{} = \"{}\"".format(project["name"],
project["revision"]))
+#
+
+SRCREV_default = "2ddd73feafd3316af2c547c34d6969bea637d5c6"
+SRCREV_canopennode = "53d3415c14d60f8f4bfca54bfbc5d5a667d7e724"
+SRCREV_chre = "0edfe2c2ec656afb910cfab8ed59a5ffd59b87c8"
+SRCREV_civetweb = "094aeb41bb93e9199d24d665ee43e9e05d6d7b1c"
+SRCREV_cmsis = "5f86244bad4ad5a590e084f0e72ba7a1416c2edf"
+SRCREV_edtt = "1ea61a390d2bfcf3b2ecdba8f8b0b98dfdffbd11"
+SRCREV_fatfs = "a30531af3a95a9a3ea7d771ea8a578ebfed45514"
+SRCREV_fff = "6ce5ba26486e93d5b7696a3e23f0585932c14b16"
+SRCREV_altera = "0d225ddd314379b32355a00fb669eacf911e750d"
+SRCREV_atmel = "78c5567c05b6b434dd7d98f49156319df4217bac"
+SRCREV_espressif = "df85671c5d0405c0747c2939c8dfe808b7e4cf38"
+SRCREV_gigadevice = "63a72ca90b7e0d7257211ddc5c79e8c0b940371b"
+SRCREV_infineon = "4af06965f57ba1e7d170e6a97d24c33785543a8c"
+SRCREV_microchip = "5d079f1683a00b801373bbbbf5d181d4e33b30d5"
+SRCREV_nordic = "a85bb3676d61d1ae202088e0d3fec556056b2c9e"
+SRCREV_nuvoton = "b4d31f33238713a568e23618845702fadd67386f"
+SRCREV_nxp = "2302a1e94f5bc00ce59db4e249b688ad2e959f58"
+SRCREV_openisa = "40d049f69c50b58ea20473bee14cf93f518bf262"
+SRCREV_quicklogic = "b3a66fe6d04d87fd1533a5c8de51d0599fcd08d0"
+SRCREV_rpi_pico = "191f5ba46fda49523cdaaef27583d1c875ba2c36"
+SRCREV_silabs = "be39d4eebeddac6e18e9c0c3ba1b31ad1e82eaed"
+SRCREV_st = "52a522ca4a8a9ec1e9bb5bb514e1ab6f102863fe"
+SRCREV_stm32 = "51b373cd3455b8c2b9babbf6ff41918116a442ac"
+SRCREV_telink = "ffcfd6282aa213f1dc0848dbca6279b098f6b143"
+SRCREV_ti = "905a5d4134899630071f9383aadaaf266e8f8cd2"
+SRCREV_xtensa = "0e577021bb66e644afd067cd9f7c71ab11b62b3d"
+SRCREV_libmetal = "850a3c3fd5bc655987021dc9106d8e8cd0f7e061"
+SRCREV_liblc3codec = "3951cf1b71ff3be086c9b9b595e473e12301337c"
+SRCREV_littlefs = "652f2c5646e79b881e6f3099686ad3b7af9e216c"
+SRCREV_loramac-node =
"12019623bbad9eb54fe51066847a7cbd4b4eac57"
+SRCREV_lvgl = "df717ac87a9fd80246cc8df24554475e59bda21f"
+SRCREV_lz4 = "8e303c264fc21c2116dc612658003a22e933124d"
+SRCREV_mbedtls = "7fed49c9b9f983ad6416986661ef637459723bcb"
+SRCREV_mcuboot = "e58ea98aec6e5539c5f872a98059e461d0155bbb"
+SRCREV_mipi-sys-t = "a5163c1800a5243f8b05d84c942da008df4cb666"
+SRCREV_nanopb = "d148bd26718e4c10414f07a7eb1bd24c62e56c5d"
+SRCREV_net-tools = "f49bd1354616fae4093bf36e5eaee43c51a55127"
+SRCREV_nrf_hw_models =
"b8cea37dbdc8fc58cc14b4e19fa850877a9da520"
+SRCREV_open-amp = "8d53544871e1f300c478224faca6be8384ab0d04"
+SRCREV_openthread = "e2a765599aa0379d0f72f0149a9cbafec070c12d"
+SRCREV_segger = "3a52ab222133193802d3c3b4d21730b9b1f1d2f6"
+SRCREV_sof = "2efc3ea41c0074c6dab5f376fafaa26f52c25c75"
+SRCREV_tflite-micro = "9156d050927012da87079064db59d07f03b8baf6"
+SRCREV_tinycbor = "9e1f34bc08123aaad7666d3652aaa839e8178b3b"
+SRCREV_tinycrypt = "3e9a49d2672ec01435ffbf0d788db6d95ef28de0"
+SRCREV_TraceRecorderSource =
"e8ca3b6a83d19b2fc4738a0d9607190436e5e452"
+SRCREV_trusted-firmware-m =
"7c53a6e76130a85303f83b15d868a92fdcd5f5be"
+SRCREV_tf-m-tests = "c99a86b295c4887520da9d8402566d7f225c974e"
+SRCREV_psa-arch-tests = "a81f9da287569f169d60026916952641b233faa8"
+SRCREV_zcbor = "882c489a7d9fdfff31d27666914a78a9eb6976d7"
+SRCREV_zscilib = "fc979a8dcb74169c69b02835927bff8f070d6325"
+
+ZEPHYR_BRANCH = "v3.1-branch"
+PV = "3.1.0+git${SRCPV}"
+
+SRC_URI += " \
+ file://0001-3.1-cmake-add-yocto-toolchain.patch \ "
[Naveen] Patch 0001-x86-fix-efi-binary-generation-issue-in-cross-compila.patch is also required for v3.1.0. It needs rebasing too.
I will sent v3 with the fix.

diff --git
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src.inc
b/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src.inc
index bf9ceaf..e9b35c9 100644
---
a/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src.inc
+++ b/meta-zephyr-core/recipes-kernel/zephyr-kernel/zephyr-kernel-src.
+++ inc
@@ -19,7 +19,6 @@ SRC_URI = "\
git://github.com/zephyrproject-
rtos/fatfs.git;protocol=https;nobranch=1;destsuffix=git/modules/fs/fatfs;na
me=fatfs \
git://github.com/zephyrproject-
rtos/hal_altera.git;protocol=https;nobranch=1;destsuffix=git/modules/hal/al
tera;name=altera \
git://github.com/zephyrproject-
rtos/hal_atmel.git;protocol=https;nobranch=1;destsuffix=git/modules/hal/a
tmel;name=atmel \
- git://github.com/zephyrproject-
rtos/hal_cypress.git;protocol=https;nobranch=1;destsuffix=git/modules/hal/
cypress;name=cypress \
git://github.com/zephyrproject-
rtos/hal_espressif.git;protocol=https;nobranch=1;destsuffix=git/modules/ha
l/espressif;name=espressif \
git://github.com/zephyrproject-
rtos/hal_infineon.git;protocol=https;nobranch=1;destsuffix=git/modules/hal
/infineon;name=infineon \

git://github.com/zephyrproject-
rtos/hal_microchip.git;protocol=https;nobranch=1;destsuffix=git/modules/h
al/microchip;name=microchip \ @@ -52,11 +51,9 @@ SRC_URI = "\
git://github.com/zephyrproject-
rtos/hal_telink.git;protocol=https;nobranch=1;destsuffix=git/modules/hal/t
elink;name=telink \
git://github.com/zephyrproject-
rtos/lz4.git;protocol=https;nobranch=1;destsuffix=git/modules/lib/lz4;name
=lz4 \
git://github.com/zephyrproject-rtos/tflite-
micro.git;protocol=https;nobranch=1;destsuffix=git/modules/lib/tflite-
micro;name=tflite-micro \
- file://0001-cmake-add-yocto-toolchain.patch \
- file://0001-x86-fix-efi-binary-generation-issue-in-cross-compila.patch \
"
S = "${WORKDIR}/git"

# Default to a stable version
-PREFERRED_VERSION_zephyr-kernel ??= "3.0.0"
+PREFERRED_VERSION_zephyr-kernel ??= "3.1.0"
include zephyr-kernel-src-${PREFERRED_VERSION_zephyr-kernel}.inc
--
2.34.1


Re: [meta-python][PATCH v1] python3-pystemd: Upgrade 0.8.0 -> 0.10.0:

Johannes Schneider
 

>> -SRC_URI[md5sum] = "f993739eca645749f18d4ccfd4a0fbf3"
>> -SRC_URI[sha256sum] = "cac2e42043ab28d43adf33dab493c6a3cf8a99794f824ae8af6d9cd6458b9972"
>> +SRC_URI[md5sum] = "c8c7337d21a0e9a2e62d1708caf4bdbe"
>
>We dont need md5sums for SRC_URI anymore

ACK, removed with PATCH v2

From: Khem Raj <raj.khem@...>
Sent: Wednesday, July 27, 2022 17:07
To: SCHNEIDER Johannes <johannes.schneider@...>; openembedded-devel@... <openembedded-devel@...>
Subject: Re: [oe] [meta-python][PATCH v1] python3-pystemd: Upgrade 0.8.0 -> 0.10.0:
 
[You don't often get email from raj.khem@.... Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]

This email is not from Hexagon’s Office 365 instance. Please be careful while clicking links, opening attachments, or replying to this email.


On 7/27/22 5:45 AM, Johannes Schneider via lists.openembedded.org wrote:
> most important fix: version 0.8.0 errors out on dbus-lib interaction,
> which is fixed with the most recent commit
>
> 505e2b5 (tag: v.0.10.0) add interactive_authorization options for buses
> 2d90700 pystemd: add copyright boilerplate to typing stubs
> 5b95888 pystemd: update branch name in github workflow
> 16817d2 Add type stub for pystemd.run
> 410fd77 (tag: v.0.9.0) update changelog for 0.9.0
> 71aae43 GetProcesses() - info about systemd version (#59)
> fcafd08 Also include .pxd and .pxi in the source distribution
> 475cd2f also support 3.9
> ea98275 some formatting options and start pystemd 0.9 development
> eb7d225 pystemd: update install instructions in README
> 6fdf2c8 Daily `arc lint --take BLACK`
> 50e61b7 add a LIBSYSTEMD_VERSION macro for gating new functions (#58)
>
> Signed-off-by: Johannes Schneider <johannes.schneider@...>
> ---
>   .../{python3-pystemd_0.8.0.bb => python3-pystemd_0.10.0.bb} | 6 +++---
>   1 file changed, 3 insertions(+), 3 deletions(-)
>   rename meta-python/recipes-devtools/python/{python3-pystemd_0.8.0.bb => python3-pystemd_0.10.0.bb} (61%)
>
> diff --git a/meta-python/recipes-devtools/python/python3-pystemd_0.8.0.bb b/meta-python/recipes-devtools/python/python3-pystemd_0.10.0.bb
> similarity index 61%
> rename from meta-python/recipes-devtools/python/python3-pystemd_0.8.0.bb
> rename to meta-python/recipes-devtools/python/python3-pystemd_0.10.0.bb
> index 0056a794f..0b8216e87 100644
> --- a/meta-python/recipes-devtools/python/python3-pystemd_0.8.0.bb
> +++ b/meta-python/recipes-devtools/python/python3-pystemd_0.10.0.bb
> @@ -2,13 +2,13 @@ SUMMARY = "Python bindings for interacting with systemd over DBus"
>   LICENSE = "LGPL-2.1-only"
>   LIC_FILES_CHKSUM = "file://LICENSE;md5=4fbd65380cdd255951079008b364516c"
>
> -SRC_URI[md5sum] = "f993739eca645749f18d4ccfd4a0fbf3"
> -SRC_URI[sha256sum] = "cac2e42043ab28d43adf33dab493c6a3cf8a99794f824ae8af6d9cd6458b9972"
> +SRC_URI[md5sum] = "c8c7337d21a0e9a2e62d1708caf4bdbe"

We dont need md5sums for SRC_URI anymore

> +SRC_URI[sha256sum] = "d74a814bfda01085db1a8ad90be3cb27daf23a51ab6b03e7e29ec811fa2ae859"
>
>   DEPENDS = "systemd"
>   RDEPENDS:${PN} += "python3-xml python3-pprint"
>   REQUIRED_DISTRO_FEATURES = "systemd"
>
> -inherit pypi setuptools3 features_check
> +inherit pypi setuptools3 features_check pkgconfig
>
>   BBCLASSEXTEND = "native"
>
>
>
>
>


[meta-python][PATCH v2] python3-pystemd: Upgrade 0.8.0 -> 0.10.0:

Johannes Schneider
 

most important fix: version 0.8.0 errors out on dbus-lib interaction,
which is fixed with the most recent commit

505e2b5 (tag: v.0.10.0) add interactive_authorization options for buses
2d90700 pystemd: add copyright boilerplate to typing stubs
5b95888 pystemd: update branch name in github workflow
16817d2 Add type stub for pystemd.run
410fd77 (tag: v.0.9.0) update changelog for 0.9.0
71aae43 GetProcesses() - info about systemd version (#59)
fcafd08 Also include .pxd and .pxi in the source distribution
475cd2f also support 3.9
ea98275 some formatting options and start pystemd 0.9 development
eb7d225 pystemd: update install instructions in README
6fdf2c8 Daily `arc lint --take BLACK`
50e61b7 add a LIBSYSTEMD_VERSION macro for gating new functions (#58)

Signed-off-by: Johannes Schneider <johannes.schneider@...>
---
.../{python3-pystemd_0.8.0.bb => python3-pystemd_0.10.0.bb} | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
rename meta-python/recipes-devtools/python/{python3-pystemd_0.8.0.bb => python3-pystemd_0.10.0.bb} (62%)

diff --git a/meta-python/recipes-devtools/python/python3-pystemd_0.8.0.bb b/meta-python/recipes-devtools/python/python3-pystemd_0.10.0.bb
similarity index 62%
rename from meta-python/recipes-devtools/python/python3-pystemd_0.8.0.bb
rename to meta-python/recipes-devtools/python/python3-pystemd_0.10.0.bb
index 0056a794f..da263fe94 100644
--- a/meta-python/recipes-devtools/python/python3-pystemd_0.8.0.bb
+++ b/meta-python/recipes-devtools/python/python3-pystemd_0.10.0.bb
@@ -2,13 +2,12 @@ SUMMARY = "Python bindings for interacting with systemd over DBus"
LICENSE = "LGPL-2.1-only"
LIC_FILES_CHKSUM = "file://LICENSE;md5=4fbd65380cdd255951079008b364516c"

-SRC_URI[md5sum] = "f993739eca645749f18d4ccfd4a0fbf3"
-SRC_URI[sha256sum] = "cac2e42043ab28d43adf33dab493c6a3cf8a99794f824ae8af6d9cd6458b9972"
+SRC_URI[sha256sum] = "d74a814bfda01085db1a8ad90be3cb27daf23a51ab6b03e7e29ec811fa2ae859"

DEPENDS = "systemd"
RDEPENDS:${PN} += "python3-xml python3-pprint"
REQUIRED_DISTRO_FEATURES = "systemd"

-inherit pypi setuptools3 features_check
+inherit pypi setuptools3 features_check pkgconfig

BBCLASSEXTEND = "native"
--
2.25.1


Re: [meta-python] [PATCH] python3-pyaudio: upgrade 0.2.11 -> 0.2.12

Khem Raj
 

This fails to build with musl see

https://errors.yoctoproject.org/Errors/Details/663060/

On Wed, Jul 27, 2022 at 6:10 AM xuhuan.fnst@...
<xuhuan.fnst@...> wrote:

From: Xu Huan <xuhuan.fnst@...>

License-Update: license check file changed to LICENSE.txt

Changelog:
==========
modernizing the Microsoft Windows build process
the use paFramesPerBufferUnspecified as the default frames per buffer
the patch that uses the system's preferred encoding
the patches that skip unit tests that require audio hardware
fixes and suggestions to the documentation
fixes to the website documentation

Signed-off-by: Xu Huan <xuhuan.fnst@...>
---
.../{python3-pyaudio_0.2.11.bb => python3-pyaudio_0.2.12.bb} | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
rename meta-python/recipes-devtools/python/{python3-pyaudio_0.2.11.bb => python3-pyaudio_0.2.12.bb} (54%)

diff --git a/meta-python/recipes-devtools/python/python3-pyaudio_0.2.11.bb b/meta-python/recipes-devtools/python/python3-pyaudio_0.2.12.bb
similarity index 54%
rename from meta-python/recipes-devtools/python/python3-pyaudio_0.2.11.bb
rename to meta-python/recipes-devtools/python/python3-pyaudio_0.2.12.bb
index 802ca35100..ae5fcae4ac 100644
--- a/meta-python/recipes-devtools/python/python3-pyaudio_0.2.11.bb
+++ b/meta-python/recipes-devtools/python/python3-pyaudio_0.2.12.bb
@@ -1,12 +1,11 @@
SUMMARY = "PyAudio provides Python bindings for PortAudio, the cross-platform audio I/O library"
SECTION = "devel/python"
LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://README;md5=288793c2b9b05bd67abbd2a8f5d144f7"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=7c3152b432b96d6dc4a1cb35397da9ec"

PYPI_PACKAGE = "PyAudio"

-SRC_URI[md5sum] = "7e4c88139284033f67b4336c74eda3b8"
-SRC_URI[sha256sum] = "93bfde30e0b64e63a46f2fd77e85c41fd51182a4a3413d9edfaf9ffaa26efb74"
+SRC_URI[sha256sum] = "55ddf5db72bc537bba5f5dbca3ab9f0222ee5b842bda83978eab0b7b8f60fb9e"

inherit pypi setuptools3

--
2.25.1




[meta-python] [PATCH] python3-xmlschema: upgrade 1.11.3 -> 2.0.1

wangmy
 

Changelog:
==========
Remove warnings during the build of the package using package_data specs in setup.py
Fix decoding with process_namespaces=False and xsi:type in XML instance
Refactor DataElement.get(), restore DataElement.set() (issue #314)
Add map_attribute_names argument to DataElementConverter

Signed-off-by: Wang Mingyu <wangmy@...>
---
.../{python3-xmlschema_1.11.3.bb => python3-xmlschema_2.0.1.bb} | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-xmlschema_1.11.3.bb => python3-xmlschema_2.0.1.bb} (84%)

diff --git a/meta-python/recipes-devtools/python/python3-xmlschema_1.11.3.bb b/meta-python/recipes-devtools/python/python3-xmlschema_2.0.1.bb
similarity index 84%
rename from meta-python/recipes-devtools/python/python3-xmlschema_1.11.3.bb
rename to meta-python/recipes-devtools/python/python3-xmlschema_2.0.1.bb
index 7837bc8a4a..68148b7b5c 100644
--- a/meta-python/recipes-devtools/python/python3-xmlschema_1.11.3.bb
+++ b/meta-python/recipes-devtools/python/python3-xmlschema_2.0.1.bb
@@ -3,7 +3,7 @@ HOMEPAGE = "https://github.com/sissaschool/xmlschema"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://LICENSE;md5=47489cb18c469474afeb259ed1d4832f"

-SRC_URI[sha256sum] = "28a135028f7ab1e0c934fc0c6717a66b2dc5f166d123dfe6ce61afc671ad113f"
+SRC_URI[sha256sum] = "1460ba451b4084d4edd031b564f460f5c11b14b20764ce1f64691f8c69e1194d"

PYPI_PACKAGE = "xmlschema"
inherit pypi setuptools3
--
2.25.1


[PATCH] [oe] [meta-python] [PATCH] python3-werkzeug: upgrade 2.1.2 -> 2.2.0

wangmy
 

Add dependence python3-markupsafe

Changelog:
==========
- Deprecated get_script_name, get_query_string, peek_path_info, pop_path_info,
and extract_path_info. #2461
- Remove previously deprecated code. #2461
- Add MarkupSafe as a dependency and use it to escape values when rendering
HTML. #2419
- Added the werkzeug.debug.preserve_context mechanism for restoring
context-local data for a request when running code in the debug console.
- Fix compatibility with Python 3.11 by ensuring that end_lineno and
end_col_offset are present on AST nodes. #2425
- Add a new faster matching router based on a state machine. #2433
- Names within options headers are always converted to lowercase. This matches
RFC 6266 that the case is not relevant. #2442
- AnyConverter validates the value passed for it when building URLs. #2388
- The debugger shows enhanced error locations in tracebacks in Python 3.11. #2407
- Added Sans-IO is_resource_modified and parse_cookie functions based on WSGI versions.
- Added Sans-IO get_content_length function. #2415

Signed-off-by: Wang Mingyu <wangmy@...>
---
.../{python3-werkzeug_2.1.2.bb => python3-werkzeug_2.2.0.bb} | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-werkzeug_2.1.2.bb => python3-werkzeug_2.2.0.bb} (90%)

diff --git a/meta-python/recipes-devtools/python/python3-werkzeug_2.1.2.bb b/meta-python/recipes-devtools/python/python3-werkzeug_2.2.0.bb
similarity index 90%
rename from meta-python/recipes-devtools/python/python3-werkzeug_2.1.2.bb
rename to meta-python/recipes-devtools/python/python3-werkzeug_2.2.0.bb
index 74796d8962..c9e3b0de40 100644
--- a/meta-python/recipes-devtools/python/python3-werkzeug_2.1.2.bb
+++ b/meta-python/recipes-devtools/python/python3-werkzeug_2.2.0.bb
@@ -12,7 +12,7 @@ LIC_FILES_CHKSUM = "file://LICENSE.rst;md5=5dc88300786f1c214c1e9827a5229462"

PYPI_PACKAGE = "Werkzeug"

-SRC_URI[sha256sum] = "1ce08e8093ed67d638d63879fd1ba3735817f7a80de3674d293f5984f25fb6e6"
+SRC_URI[sha256sum] = "fe8bcdcef40275ed915fc734c2527a39d705b57a716d4f09e790296abbd16a7f"

inherit pypi setuptools3

@@ -36,4 +36,5 @@ RDEPENDS:${PN} += " \
${PYTHON_PN}-unixadmin \
${PYTHON_PN}-misc \
${PYTHON_PN}-profile \
+ ${PYTHON_PN}-markupsafe \
"
--
2.25.1


[PATCH] [oe] [meta-python] [PATCH] python3-sh: upgrade 1.14.2 -> 1.14.3

wangmy
 

bugfix where Command was not aware of default call args when wrapping the module

Add dependence python3-fcntl

Signed-off-by: Wang Mingyu <wangmy@...>
---
.../python/{python3-sh_1.14.2.bb => python3-sh_1.14.3.bb} | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-sh_1.14.2.bb => python3-sh_1.14.3.bb} (81%)

diff --git a/meta-python/recipes-devtools/python/python3-sh_1.14.2.bb b/meta-python/recipes-devtools/python/python3-sh_1.14.3.bb
similarity index 81%
rename from meta-python/recipes-devtools/python/python3-sh_1.14.2.bb
rename to meta-python/recipes-devtools/python/python3-sh_1.14.3.bb
index f8cecfdfcb..317f648dcd 100644
--- a/meta-python/recipes-devtools/python/python3-sh_1.14.2.bb
+++ b/meta-python/recipes-devtools/python/python3-sh_1.14.3.bb
@@ -3,7 +3,7 @@ HOMEPAGE = "https://github.com/amoffat/sh"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=5317094292296f03405f59ae5f6544b6"

-SRC_URI[sha256sum] = "9d7bd0334d494b2a4609fe521b2107438cdb21c0e469ffeeb191489883d6fe0d"
+SRC_URI[sha256sum] = "e4045b6c732d9ce75d571c79f5ac2234edd9ae4f5fa9d59b09705082bdca18c7"

PYPI_PACKAGE = "sh"

@@ -19,4 +19,5 @@ RDEPENDS:${PN} += " \
${PYTHON_PN}-terminal \
${PYTHON_PN}-threading \
${PYTHON_PN}-unixadmin \
+ ${PYTHON_PN}-fcntl \
"
--
2.25.1


[meta-python] [PATCH] python3-rsa: upgrade 4.8 -> 4.9

wangmy
 

Changelog:
==========
Remove debug logging from rsa/key.py (#194).
Remove overlapping slots in PrivateKey and PublicKey. (#189).
Do not include CHANGELOG/LICENSE/README.md in wheel (#191).
Fixed Key Generation Unittest: Public and Private keys are assigned the wrong way around (#188).

Signed-off-by: Wang Mingyu <wangmy@...>
---
.../python/{python3-rsa_4.8.bb => python3-rsa_4.9.bb} | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-rsa_4.8.bb => python3-rsa_4.9.bb} (92%)

diff --git a/meta-python/recipes-devtools/python/python3-rsa_4.8.bb b/meta-python/recipes-devtools/python/python3-rsa_4.9.bb
similarity index 92%
rename from meta-python/recipes-devtools/python/python3-rsa_4.8.bb
rename to meta-python/recipes-devtools/python/python3-rsa_4.9.bb
index 21b664ddd1..ed5018f49e 100644
--- a/meta-python/recipes-devtools/python/python3-rsa_4.8.bb
+++ b/meta-python/recipes-devtools/python/python3-rsa_4.9.bb
@@ -4,7 +4,7 @@ AUTHOR = "Sybren A. Stuvel"
LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://LICENSE;md5=c403f6882d4f97a9cd927df987d55634"

-SRC_URI[sha256sum] = "5c6bd9dc7a543b7fe4304a631f8a8a3b674e2bbfc49c2ae96200cdbe55df6b17"
+SRC_URI[sha256sum] = "e38464a49c6c85d7f1351b0126661487a7e0a14a50f1675ec50eb34d4f20ef21"

inherit pypi python_poetry_core update-alternatives

--
2.25.1


[meta-python] [PATCH] python3-regex: upgrade 2022.7.9 -> 2022.7.24

wangmy
 

Signed-off-by: Wang Mingyu <wangmy@...>
---
.../{python3-regex_2022.7.9.bb => python3-regex_2022.7.24.bb} | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-regex_2022.7.9.bb => python3-regex_2022.7.24.bb} (79%)

diff --git a/meta-python/recipes-devtools/python/python3-regex_2022.7.9.bb b/meta-python/recipes-devtools/python/python3-regex_2022.7.24.bb
similarity index 79%
rename from meta-python/recipes-devtools/python/python3-regex_2022.7.9.bb
rename to meta-python/recipes-devtools/python/python3-regex_2022.7.24.bb
index 3fbe8b0b27..897aa76c35 100644
--- a/meta-python/recipes-devtools/python/python3-regex_2022.7.9.bb
+++ b/meta-python/recipes-devtools/python/python3-regex_2022.7.24.bb
@@ -5,7 +5,7 @@ LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=7b5751ddd6b643203c31ff873051d069"

inherit pypi setuptools3

-SRC_URI[sha256sum] = "601c99ac775b6c89699a48976f3dbb000b47d3ca59362c8abc9582e6d0780d91"
+SRC_URI[sha256sum] = "fa8a4bc81b15f49c57ede3fd636786c6619179661acf2430fcc387d75bf28d33"

RDEPENDS:${PN} += " \
python3-stringold \
--
2.25.1


[meta-python] [PATCH] python3-pyscaffold: upgrade 4.2.3 -> 4.3

wangmy
 

Changelog:
==========
- Removed wheel from the set of build dependencies in pyproject.toml (it is
redundant since setuptools already includes it), PR #652.
- Updated freebsd configuration in .cirrus.yml (with workaround for pipx in
2022Q3 repo), PR #657.

Signed-off-by: Wang Mingyu <wangmy@...>
---
.../{python3-pyscaffold_4.2.3.bb => python3-pyscaffold_4.3.bb} | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-pyscaffold_4.2.3.bb => python3-pyscaffold_4.3.bb} (88%)

diff --git a/meta-python/recipes-devtools/python/python3-pyscaffold_4.2.3.bb b/meta-python/recipes-devtools/python/python3-pyscaffold_4.3.bb
similarity index 88%
rename from meta-python/recipes-devtools/python/python3-pyscaffold_4.2.3.bb
rename to meta-python/recipes-devtools/python/python3-pyscaffold_4.3.bb
index fe4f7e4eb7..027d7b9029 100644
--- a/meta-python/recipes-devtools/python/python3-pyscaffold_4.2.3.bb
+++ b/meta-python/recipes-devtools/python/python3-pyscaffold_4.3.bb
@@ -9,7 +9,7 @@ LICENSE = "0BSD & MIT"
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=14a49c74a1d91829908ac756c07e6b91"
DEPENDS += "python3-setuptools-scm-native"

-SRC_URI[sha256sum] = "58c7d9ce296cc26ac377061365c2f87cd8e28f46e4fb2c96ee48f9c64e33ac4a"
+SRC_URI[sha256sum] = "1a8c39bbad9abc121d6e126035740ba5f043434abb432f368a3a76596184b3ed"

inherit pypi python_setuptools_build_meta
PYPI_PACKAGE = "PyScaffold"
--
2.25.1


[meta-python] [PATCH] python3-pymongo: upgrade 4.1.1 -> 4.2.0

wangmy
 

Signed-off-by: Wang Mingyu <wangmy@...>
---
.../{python3-pymongo_4.1.1.bb => python3-pymongo_4.2.0.bb} | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-pymongo_4.1.1.bb => python3-pymongo_4.2.0.bb} (91%)

diff --git a/meta-python/recipes-devtools/python/python3-pymongo_4.1.1.bb b/meta-python/recipes-devtools/python/python3-pymongo_4.2.0.bb
similarity index 91%
rename from meta-python/recipes-devtools/python/python3-pymongo_4.1.1.bb
rename to meta-python/recipes-devtools/python/python3-pymongo_4.2.0.bb
index 7bde4ff681..62b6a941b0 100644
--- a/meta-python/recipes-devtools/python/python3-pymongo_4.1.1.bb
+++ b/meta-python/recipes-devtools/python/python3-pymongo_4.2.0.bb
@@ -8,7 +8,7 @@ HOMEPAGE = "http://github.com/mongodb/mongo-python-driver"
LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://LICENSE;md5=86d3f3a95c324c9479bd8986968f4327"

-SRC_URI[sha256sum] = "d7b8f25c9b0043cbaf77b8b895814e33e7a3c807a097377c07e1bd49946030d5"
+SRC_URI[sha256sum] = "72f338f6aabd37d343bd9d1fdd3de921104d395766bcc5cdc4039e4c2dd97766"

inherit pypi setuptools3

--
2.25.1


[meta-python] [PATCH] python3-elementpath: upgrade 2.5.3 -> 3.0.1

wangmy
 

Changelog:
==========
Fix of descendant path operator (issue #51)
Add support for Python 3.11

Signed-off-by: Wang Mingyu <wangmy@...>
---
...ython3-elementpath_2.5.3.bb => python3-elementpath_3.0.1.bb} | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
rename meta-python/recipes-devtools/python/{python3-elementpath_2.5.3.bb => python3-elementpath_3.0.1.bb} (83%)

diff --git a/meta-python/recipes-devtools/python/python3-elementpath_2.5.3.bb b/meta-python/recipes-devtools/python/python3-elementpath_3.0.1.bb
similarity index 83%
rename from meta-python/recipes-devtools/python/python3-elementpath_2.5.3.bb
rename to meta-python/recipes-devtools/python/python3-elementpath_3.0.1.bb
index 22f5aa099b..13468ebfff 100644
--- a/meta-python/recipes-devtools/python/python3-elementpath_2.5.3.bb
+++ b/meta-python/recipes-devtools/python/python3-elementpath_3.0.1.bb
@@ -3,7 +3,7 @@ HOMEPAGE = "https://github.com/sissaschool/elementpath"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://LICENSE;md5=5dbb7fb7d72da3921202dd7b995d3ecf"

-SRC_URI[sha256sum] = "b8aeb6f27dddc10fb9201b62090628a846cbae8577f3544cb1075fa38d0817f6"
+SRC_URI[sha256sum] = "a75eed5aad3dad92ba577b1f3a268d8c3c98ceeda91cb8abae4269e920e7c8f6"

PYPI_PACKAGE = "elementpath"
inherit pypi setuptools3
--
2.25.1


Re: [meta-networking][PATCH] sshpass: add recipe

Khem Raj
 

There are newer version in some layers on layerindex e.g.

https://layers.openembedded.org/layerindex/recipe/106509/

perhaps use that as starting point.

On 7/27/22 2:19 PM, Mike Petersen wrote:
From: Ioan-Adrian Ratiu <adrian.ratiu@...>
Needed for automating ssh logins, used in auto-tests.
Signed-off-by: Ioan-Adrian Ratiu <adrian.ratiu@...>
Signed-off-by: Mike Petersen <mike.petersen@...>
---
.../recipes-connectivity/sshpass/sshpass.inc | 10 ++++++++++
.../recipes-connectivity/sshpass/sshpass_1.05.bb | 8 ++++++++
2 files changed, 18 insertions(+)
create mode 100644 meta-networking/recipes-connectivity/sshpass/sshpass.inc
create mode 100644 meta-networking/recipes-connectivity/sshpass/sshpass_1.05.bb
diff --git a/meta-networking/recipes-connectivity/sshpass/sshpass.inc b/meta-networking/recipes-connectivity/sshpass/sshpass.inc
new file mode 100644
index 000000000..b19ae4313
--- /dev/null
+++ b/meta-networking/recipes-connectivity/sshpass/sshpass.inc
@@ -0,0 +1,10 @@
+DESCRIPTION = "Non-interactive ssh password auth"
+HOMEPAGE = "http://sshpass.sourceforge.net/"
+SECTION = "console/network"
+LICENSE = "GPLv2"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/sshpass/sshpass-${PV}.tar.gz"
+
+INC_PR = "r0"
+
+inherit autotools
diff --git a/meta-networking/recipes-connectivity/sshpass/sshpass_1.05.bb b/meta-networking/recipes-connectivity/sshpass/sshpass_1.05.bb
new file mode 100644
index 000000000..a345dbd95
--- /dev/null
+++ b/meta-networking/recipes-connectivity/sshpass/sshpass_1.05.bb
@@ -0,0 +1,8 @@
+PR = "${INC_PR}.0"
+
+require sshpass.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+SRC_URI[md5sum] = "c52d65fdee0712af6f77eb2b60974ac7"
+SRC_URI[sha256sum] = "c3f78752a68a0c3f62efb3332cceea0c8a1f04f7cf6b46e00ec0c3000bc8483e"

1801 - 1820 of 99837