[OE-core] [PATCH v2] staging.bbclass: Inlcude native dirs for nativesdk build

2023-11-09 Thread Vyacheslav Yurkov
Some build systems (like cmake) check whether target binaries are
present even if they are not used during compilation. Excluded ${bindir}
causes such recipes to fail to build nativesdk variant. The good
example of that is protobuf/grpc nativesdk build from meta-oe layer.

For more details refer this long discussion:
https://lists.openembedded.org/g/openembedded-devel/topic/101679410#105284

Signed-off-by: Vyacheslav Yurkov 
---
 meta/classes-global/staging.bbclass | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/classes-global/staging.bbclass 
b/meta/classes-global/staging.bbclass
index d229f40107..72c811d609 100644
--- a/meta/classes-global/staging.bbclass
+++ b/meta/classes-global/staging.bbclass
@@ -26,6 +26,7 @@ SYSROOT_DIRS_NATIVE = " \
 ${localstatedir} \
 "
 SYSROOT_DIRS:append:class-native = " ${SYSROOT_DIRS_NATIVE}"
+SYSROOT_DIRS:append:class-nativesdk = " ${SYSROOT_DIRS_NATIVE}"
 SYSROOT_DIRS:append:class-cross = " ${SYSROOT_DIRS_NATIVE}"
 SYSROOT_DIRS:append:class-crosssdk = " ${SYSROOT_DIRS_NATIVE}"
 
-- 
2.35.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190400): 
https://lists.openembedded.org/g/openembedded-core/message/190400
Mute This Topic: https://lists.openembedded.org/mt/102502647/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH] staging.bbclass: Inlcude native dirs for nativesdk build

2023-11-09 Thread Vyacheslav Yurkov
Some build systems (like cmake) check whether target binaries are
present even if they are not used during compilation. Excluded ${bindir}
causes such recipes to faile to build nativesdk variant. The good
example of that is protobuf/grps nativesdk build.

For more details refer this long discussion:
https://lists.openembedded.org/g/openembedded-devel/topic/101679410#105284

Signed-off-by: Vyacheslav Yurkov 
---
 meta/classes-global/staging.bbclass | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/classes-global/staging.bbclass 
b/meta/classes-global/staging.bbclass
index d229f40107..72c811d609 100644
--- a/meta/classes-global/staging.bbclass
+++ b/meta/classes-global/staging.bbclass
@@ -26,6 +26,7 @@ SYSROOT_DIRS_NATIVE = " \
 ${localstatedir} \
 "
 SYSROOT_DIRS:append:class-native = " ${SYSROOT_DIRS_NATIVE}"
+SYSROOT_DIRS:append:class-nativesdk = " ${SYSROOT_DIRS_NATIVE}"
 SYSROOT_DIRS:append:class-cross = " ${SYSROOT_DIRS_NATIVE}"
 SYSROOT_DIRS:append:class-crosssdk = " ${SYSROOT_DIRS_NATIVE}"
 
-- 
2.35.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190399): 
https://lists.openembedded.org/g/openembedded-core/message/190399
Mute This Topic: https://lists.openembedded.org/mt/102502625/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core][kirkstone][PATCH] tiff: Backport fix for CVE-2023-41175

2023-11-09 Thread Vijay Anusuri via lists.openembedded.org
From: Vijay Anusuri 

Upstream-Status: Backport 
[https://gitlab.com/libtiff/libtiff/-/commit/6e2dac5f904496d127c92ddc4e56eccfca25c2ee]

Reference: https://security-tracker.debian.org/tracker/CVE-2023-41175

Signed-off-by: Vijay Anusuri 
---
 .../libtiff/tiff/CVE-2023-41175.patch | 69 +++
 meta/recipes-multimedia/libtiff/tiff_4.3.0.bb |  1 +
 2 files changed, 70 insertions(+)
 create mode 100644 meta/recipes-multimedia/libtiff/tiff/CVE-2023-41175.patch

diff --git a/meta/recipes-multimedia/libtiff/tiff/CVE-2023-41175.patch 
b/meta/recipes-multimedia/libtiff/tiff/CVE-2023-41175.patch
new file mode 100644
index 00..06645bed68
--- /dev/null
+++ b/meta/recipes-multimedia/libtiff/tiff/CVE-2023-41175.patch
@@ -0,0 +1,69 @@
+From 6e2dac5f904496d127c92ddc4e56eccfca25c2ee Mon Sep 17 00:00:00 2001
+From: Arie Haenel 
+Date: Wed, 19 Jul 2023 19:40:01 +
+Subject: [PATCH] raw2tiff: fix integer overflow and bypass of the check (fixes 
#592)
+
+Upstream-Status: Backport 
[https://gitlab.com/libtiff/libtiff/-/commit/6e2dac5f904496d127c92ddc4e56eccfca25c2ee]
+CVE: CVE-2023-41175
+Signed-off-by: Vijay Anusuri 
+---
+ tools/raw2tiff.c | 29 +
+ 1 file changed, 29 insertions(+)
+
+diff --git a/tools/raw2tiff.c b/tools/raw2tiff.c
+index dfee715..253c023 100644
+--- a/tools/raw2tiff.c
 b/tools/raw2tiff.c
+@@ -36,6 +36,7 @@
+ #include 
+ #include 
+ #include 
++#include 
+ 
+ #ifdef HAVE_UNISTD_H
+ # include 
+@@ -101,6 +102,7 @@ main(int argc, char* argv[])
+   int fd;
+   char*outfilename = NULL;
+   TIFF*out;
++  uint32_t temp_limit_check = 0; /* temp for integer overflow 
checking*/
+ 
+   uint32_t row, col, band;
+   int c;
+@@ -212,6 +214,33 @@ main(int argc, char* argv[])
+   if (guessSize(fd, dtype, hdr_size, nbands, swab, , ) < 0)
+   return EXIT_FAILURE;
+ 
++  /* check for integer overflow in */
++  /* hdr_size + (*width) * (*length) * nbands * depth */
++
++  if ((width == 0) || (length == 0) ){
++  fprintf(stderr, "Too large nbands value specified.\n");
++  return (EXIT_FAILURE);
++  }
++
++  temp_limit_check = nbands * depth;
++
++  if ( !temp_limit_check || length > ( UINT_MAX / temp_limit_check ) )  {
++  fprintf(stderr, "Too large length size specified.\n");
++  return (EXIT_FAILURE);
++  }
++  temp_limit_check = temp_limit_check * length;
++
++  if ( !temp_limit_check || width > ( UINT_MAX / temp_limit_check ) )  {
++  fprintf(stderr, "Too large width size specified.\n");
++  return (EXIT_FAILURE);
++  }
++  temp_limit_check = temp_limit_check * width;
++
++  if ( !temp_limit_check || hdr_size > ( UINT_MAX - temp_limit_check ) )  
{
++  fprintf(stderr, "Too large header size specified.\n");
++  return (EXIT_FAILURE);
++  }
++
+   if (outfilename == NULL)
+   outfilename = argv[optind+1];
+   out = TIFFOpen(outfilename, "w");
+-- 
+2.25.1
+
diff --git a/meta/recipes-multimedia/libtiff/tiff_4.3.0.bb 
b/meta/recipes-multimedia/libtiff/tiff_4.3.0.bb
index e925b7d652..11e3818c69 100644
--- a/meta/recipes-multimedia/libtiff/tiff_4.3.0.bb
+++ b/meta/recipes-multimedia/libtiff/tiff_4.3.0.bb
@@ -46,6 +46,7 @@ SRC_URI = 
"http://download.osgeo.org/libtiff/tiff-${PV}.tar.gz \
file://CVE-2022-40090.patch \
file://CVE-2023-1916.patch \
file://CVE-2023-40745.patch \
+   file://CVE-2023-41175.patch \
"
 
 SRC_URI[sha256sum] = 
"0e46e5acb087ce7d1ac53cf4f56a09b221537fc86dfc5daaad1c2e89e1b37ac8"
-- 
2.25.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190398): 
https://lists.openembedded.org/g/openembedded-core/message/190398
Mute This Topic: https://lists.openembedded.org/mt/102502426/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core][mickledore][PATCH] sudo: upgrade 1.9.13p3 -> 1.9.15p2

2023-11-09 Thread Xiangyu Chen
From: Xiangyu Chen 

Upgrade 1.9.13p3 to 1.9.15p2 to fix bugs and CVEs

License-update: file removed upstream
Drop patch as issue fixed upstream.

Changelogs:
1.9.15p2: https://www.sudo.ws/releases/stable/#1.9.15p2
1.9.15p1: https://www.sudo.ws/releases/stable/#1.9.15p1
1.9.15:   https://www.sudo.ws/releases/stable/#1.9.15
1.9.14p3: https://www.sudo.ws/releases/stable/#1.9.14p3
1.9.14p2: https://www.sudo.ws/releases/stable/#1.9.14p2
1.9.14p1: https://www.sudo.ws/releases/stable/#1.9.14p1
1.9.14:   https://www.sudo.ws/releases/stable/#1.9.14

Signed-off-by: Xiangyu Chen 
---
 ...me.c-correctly-include-header-for-ou.patch | 25 ---
 meta/recipes-extended/sudo/sudo.inc   |  5 ++--
 .../{sudo_1.9.13p3.bb => sudo_1.9.15p2.bb}|  3 +--
 3 files changed, 3 insertions(+), 30 deletions(-)
 delete mode 100644 
meta/recipes-extended/sudo/files/0001-lib-util-mksigname.c-correctly-include-header-for-ou.patch
 rename meta/recipes-extended/sudo/{sudo_1.9.13p3.bb => sudo_1.9.15p2.bb} (92%)

diff --git 
a/meta/recipes-extended/sudo/files/0001-lib-util-mksigname.c-correctly-include-header-for-ou.patch
 
b/meta/recipes-extended/sudo/files/0001-lib-util-mksigname.c-correctly-include-header-for-ou.patch
deleted file mode 100644
index f63ed553be..00
--- 
a/meta/recipes-extended/sudo/files/0001-lib-util-mksigname.c-correctly-include-header-for-ou.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From f993c5c88faacc43971899aae2168ffb3e34dc80 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin 
-Date: Fri, 24 Sep 2021 13:36:24 +0200
-Subject: [PATCH] lib/util/mksigname.c: correctly include header for out of
- tree builds
-
-Upstream-Status: Submitted [https://github.com/sudo-project/sudo/pull/123]
-Signed-off-by: Alexander Kanavin 

- lib/util/mksigname.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/lib/util/mksigname.c b/lib/util/mksigname.c
-index de8b1ad..0a69e7e 100644
 a/lib/util/mksigname.c
-+++ b/lib/util/mksigname.c
-@@ -36,7 +36,7 @@ main(int argc, char *argv[])
- {
- unsigned int i;
- 
--#include "mksigname.h"
-+#include "lib/util/mksigname.h"
- 
- printf("const char *const sudo_sys_signame[] = {\n");
- for (i = 0; i < nitems(sudo_sys_signame); i++) {
diff --git a/meta/recipes-extended/sudo/sudo.inc 
b/meta/recipes-extended/sudo/sudo.inc
index bedf713d2c..feb1cf35a7 100644
--- a/meta/recipes-extended/sudo/sudo.inc
+++ b/meta/recipes-extended/sudo/sudo.inc
@@ -8,7 +8,6 @@ LIC_FILES_CHKSUM = 
"file://LICENSE.md;md5=5100e20d35f9015f9eef6bdb27ba194f \
 
file://plugins/sudoers/redblack.c;beginline=1;endline=46;md5=03e35317699ba00b496251e0dfe9f109
 \
 
file://lib/util/reallocarray.c;beginline=3;endline=15;md5=397dd45c7683e90b9f8bf24638cf03bf
 \
 
file://lib/util/fnmatch.c;beginline=3;endline=27;md5=004d7d2866ba1f5b41174906849d2e0f
 \
-
file://lib/util/getcwd.c;beginline=2;endline=27;md5=50f8d9667750e18dea4e84a935c12009
 \
 
file://lib/util/glob.c;beginline=2;endline=31;md5=2852f68687544e3eb8a0a61665506f0e
 \
 
file://lib/util/snprintf.c;beginline=3;endline=33;md5=b70df6179969e38fcf68da91b53b8029
 \
 
file://include/sudo_queue.h;beginline=2;endline=27;md5=ad578e9664d17a010b63e4bc0576ee8d
 \
@@ -31,12 +30,12 @@ EXTRA_OECONF = "--with-editor=${base_bindir}/vi 
--with-env-editor"
 EXTRA_OECONF:append:libc-musl = " --disable-hardening "
 
 do_compile:prepend () {
-   # Remove build host references from sudo_usage.h
+   # Remove build host references from config.h
sed -i  \
-e 's,--with-libtool-sysroot=${STAGING_DIR_TARGET},,g' \
-e 's,--build=${BUILD_SYS},,g' \
-e 's,--host=${HOST_SYS},,g' \
-   ${B}/src/sudo_usage.h
+   ${B}/config.h
 }
 
 # Explicitly create ${localstatedir}/lib before do_install to ensure
diff --git a/meta/recipes-extended/sudo/sudo_1.9.13p3.bb 
b/meta/recipes-extended/sudo/sudo_1.9.15p2.bb
similarity index 92%
rename from meta/recipes-extended/sudo/sudo_1.9.13p3.bb
rename to meta/recipes-extended/sudo/sudo_1.9.15p2.bb
index 2e11739470..431dfba3c2 100644
--- a/meta/recipes-extended/sudo/sudo_1.9.13p3.bb
+++ b/meta/recipes-extended/sudo/sudo_1.9.15p2.bb
@@ -3,12 +3,11 @@ require sudo.inc
 SRC_URI = "https://www.sudo.ws/dist/sudo-${PV}.tar.gz \
${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', 
'', d)} \
file://0001-sudo.conf.in-fix-conflict-with-multilib.patch \
-   
file://0001-lib-util-mksigname.c-correctly-include-header-for-ou.patch \
"
 
 PAM_SRC_URI = "file://sudo.pam"
 
-SRC_URI[sha256sum] = 
"92334a12bb93e0c056b09f53e255ccb7d6f67c6350e2813cd9593ceeca78560b"
+SRC_URI[sha256sum] = 
"199c0cdbfa7efcfffa9c88684a8e2fb206a62b70a316507e4a91c89c873bbcc8"
 
 DEPENDS += " virtual/crypt ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 
'libpam', '', d)}"
 RDEPENDS:${PN} += " 

[OE-core][PATCH] sudo: upgrade 1.9.14p3 -> 1.9.15p2

2023-11-09 Thread Xiangyu Chen
From: Xiangyu Chen 

Changelog:
===
1.9.15p2:
- Fixed a bug on BSD systems where sudo would not restore the
terminal settings on exit if the terminal had parity enabled.

1.9.15p1:
- Fixed a bug introduced in sudo 1.9.15 that prevented LDAP-based
sudoers from being able to read the ldap.conf file.

1.9.15:
- Fixed an undefined symbol problem on older versions of macOS
when "intercept" or "log_subcmds" are enabled in sudoers.
- Fixed "make check" failure related to getpwent(3) wrapping
on NetBSD.
- Fixed the warning message for "sudo -l command" when the command
is not permitted.  There was a missing space between "list" and
the actual command due to changes in sudo 1.9.14.
- Fixed a bug where output could go to the wrong terminal if
"use_pty" is enabled (the default) and the standard input, output
or error is redirected to a different terminal.  Bug #1056.
- The visudo utility will no longer create an empty file when the
specified sudoers file does not exist and the user exits the
editor without making any changes.  GitHub issue #294.
- The AIX and Solaris sudo packages on www.sudo.ws now support
"log_subcmds" and "intercept" with both 32-bit and 64-bit
binaries.  Previously, they only worked when running binaries
with the same word size as the sudo binary.  GitHub issue #289.
- The sudoers source is now logged in the JSON event log.  This
makes it possible to tell which rule resulted in a match.
Running "sudo -ll command" now produces verbose output that
includes matching rule as well as the path to the sudoers file
the matching rule came from.  For LDAP sudoers, the name of the
matching sudoRole is printed instead.
- The embedded copy of zlib has been updated to version 1.3.
- The sudoers plugin has been modified to make it more resilient
to ROWHAMMER attacks on authentication and policy matching.
This addresses CVE-2023-42465.
- The sudoers plugin now constructs the user time stamp file path
name using the user-ID instead of the user name.  This avoids a
potential problem with user names that contain a path separator
('/') being interpreted as part of the path name.  A similar
issue in sudo-rs has been assigned CVE-2023-42456.
- A path separator ('/') in a user, group or host name is now
replaced with an underbar character ('_') when expanding escapes
in @include and @includedir directives as well as the "iolog_file"
and "iolog_dir" sudoers Default settings.
- The "intercept_verify" sudoers option is now only applied when
the "intercept" option is set in sudoers.  Previously, it was
also applied when "log_subcmds" was enabled.  Sudo 1.9.14
contained an incorrect fix for this.  Bug #1058.
- Changes to terminal settings are now performed atomically, where
possible.  If the command is being run in a pseudo-terminal and
the user's terminal is already in raw mode, sudo will not change
the user's terminal settings.  This prevents concurrent sudo
processes from restoring the terminal settings to the wrong values.
GitHub issue #312.
- Reverted a change from sudo 1.9.4 that resulted in PAM session
modules being called with the environment of the command to be
run instead of the environment of the invoking user.
GitHub issue #318.
- New Indonesian translation from translationproject.org.
- The sudo_logsrvd server will now raise its open file descriptor
limit to the maximum allowed value when it starts up.  Each
connection can require up to nine open file descriptors so the
default soft limit may be too low.
- Better log message when rejecting a command if the "intercept"
option is enabled and the "intercept_allow_setid" option is
disabled.  Previously, "command not allowed" would be logged and
the user had no way of knowing what the actual problem was.
- Sudo will now log the invoking user's environment as "submitenv"
in the JSON logs.  The command's environment ("runenv") is no
longer logged for commands rejected by the sudoers file or an
approval plugin.

Signed-off-by: Xiangyu Chen 
---
 .../sudo/{sudo_1.9.14p3.bb => sudo_1.9.15p2.bb} | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
 rename meta/recipes-extended/sudo/{sudo_1.9.14p3.bb => sudo_1.9.15p2.bb} (96%)

diff --git a/meta/recipes-extended/sudo/sudo_1.9.14p3.bb 
b/meta/recipes-extended/sudo/sudo_1.9.15p2.bb
similarity index 96%
rename from meta/recipes-extended/sudo/sudo_1.9.14p3.bb
rename to meta/recipes-extended/sudo/sudo_1.9.15p2.bb
index d5c5718ea5..431dfba3c2 100644
--- a/meta/recipes-extended/sudo/sudo_1.9.14p3.bb
+++ b/meta/recipes-extended/sudo/sudo_1.9.15p2.bb
@@ -7,7 +7,7 @@ SRC_URI = "https://www.sudo.ws/dist/sudo-${PV}.tar.gz \
 
 PAM_SRC_URI = "file://sudo.pam"
 
-SRC_URI[sha256sum] = 
"a08318b1c4bc8582c004d4cd9ae2903abc549e7e46ba815e41fe81d1c0782b62"
+SRC_URI[sha256sum] = 
"199c0cdbfa7efcfffa9c88684a8e2fb206a62b70a316507e4a91c89c873bbcc8"
 
 DEPENDS += " virtual/crypt ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 
'libpam', '', d)}"
 RDEPENDS:${PN} += " ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 

[OE-core] Patchtest results for [PATCH] linux/cve-exclusion6.1/6.5: Update to latest kernel point releases

2023-11-09 Thread Patchtest
Thank you for your submission. Patchtest identified one
or more issues with the patch. Please see the log below for
more information:

---
Testing patch 
/home/patchtest/share/mboxes/linux-cve-exclusion6.1-6.5-Update-to-latest-kernel-point-releases.patch

FAIL: test commit message presence: Please include a commit message on your 
patch explaining the change (test_mbox.TestMbox.test_commit_message_presence)

PASS: test Signed-off-by presence 
(test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test max line length (test_metadata.TestMetadata.test_max_line_length)
PASS: test mbox format (test_mbox.TestMbox.test_mbox_format)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test target mailing list (test_mbox.TestMbox.test_target_mailing_list)

SKIP: pretest pylint: No python related patches, skipping test 
(test_python_pylint.PyLint.pretest_pylint)
SKIP: pretest src uri left files: Patch cannot be merged 
(test_metadata.TestMetadata.pretest_src_uri_left_files)
SKIP: test CVE tag format: No new CVE patches introduced 
(test_patch.TestPatch.test_cve_tag_format)
SKIP: test Signed-off-by presence: No new CVE patches introduced 
(test_patch.TestPatch.test_signed_off_by_presence)
SKIP: test Upstream-Status presence: No new CVE patches introduced 
(test_patch.TestPatch.test_upstream_status_presence_format)
SKIP: test bugzilla entry format: No bug ID found 
(test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test lic files chksum modified not mentioned: No modified recipes, 
skipping test 
(test_metadata.TestMetadata.test_lic_files_chksum_modified_not_mentioned)
SKIP: test lic files chksum presence: No added recipes, skipping test 
(test_metadata.TestMetadata.test_lic_files_chksum_presence)
SKIP: test license presence: No added recipes, skipping test 
(test_metadata.TestMetadata.test_license_presence)
SKIP: test pylint: No python related patches, skipping test 
(test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now 
(test_mbox.TestMbox.test_series_merge_on_head)
SKIP: test src uri left files: Patch cannot be merged 
(test_metadata.TestMetadata.test_src_uri_left_files)
SKIP: test summary presence: No added recipes, skipping test 
(test_metadata.TestMetadata.test_summary_presence)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this
email with an explanation of why the patch should be accepted. If you
believe these results are due to an error in patchtest, please submit a
bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category
under 'Yocto Project Subprojects'). For more information on specific
failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank
you!

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190395): 
https://lists.openembedded.org/g/openembedded-core/message/190395
Mute This Topic: https://lists.openembedded.org/mt/102490389/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH] linux/cve-exclusion6.1/6.5: Update to latest kernel point releases

2023-11-09 Thread Richard Purdie
Signed-off-by: Richard Purdie 
---
 .../linux/cve-exclusion_6.1.inc   | 30 ++---
 .../linux/cve-exclusion_6.5.inc   | 62 ---
 2 files changed, 60 insertions(+), 32 deletions(-)

diff --git a/meta/recipes-kernel/linux/cve-exclusion_6.1.inc 
b/meta/recipes-kernel/linux/cve-exclusion_6.1.inc
index 3f708b0cc51..1216e0c2ddd 100644
--- a/meta/recipes-kernel/linux/cve-exclusion_6.1.inc
+++ b/meta/recipes-kernel/linux/cve-exclusion_6.1.inc
@@ -1,9 +1,9 @@
 
 # Auto-generated CVE metadata, DO NOT EDIT BY HAND.
-# Generated at 2023-10-23 14:03:17.479563+00:00 for version 6.1.57
+# Generated at 2023-11-09 17:12:27.365962+00:00 for version 6.1.61
 
 python check_kernel_cve_status_version() {
-this_version = "6.1.57"
+this_version = "6.1.61"
 kernel_version = d.getVar("LINUX_VERSION")
 if kernel_version != this_version:
 bb.warn("Kernel CVE status needs updating: generated for %s but kernel 
is %s" % (this_version, kernel_version))
@@ -4644,7 +4644,7 @@ CVE_STATUS[CVE-2023-1118] = "cpe-stable-backport: 
Backported in 6.1.16"
 
 CVE_STATUS[CVE-2023-1192] = "cpe-stable-backport: Backported in 6.1.33"
 
-# CVE-2023-1193 has no known resolution
+# CVE-2023-1193 needs backporting (fixed from 6.3rc6)
 
 CVE_STATUS[CVE-2023-1194] = "cpe-stable-backport: Backported in 6.1.34"
 
@@ -4954,7 +4954,7 @@ CVE_STATUS[CVE-2023-35824] = "cpe-stable-backport: 
Backported in 6.1.28"
 
 CVE_STATUS[CVE-2023-35826] = "cpe-stable-backport: Backported in 6.1.28"
 
-# CVE-2023-35827 has no known resolution
+CVE_STATUS[CVE-2023-35827] = "cpe-stable-backport: Backported in 6.1.59"
 
 CVE_STATUS[CVE-2023-35828] = "cpe-stable-backport: Backported in 6.1.28"
 
@@ -5024,7 +5024,7 @@ CVE_STATUS[CVE-2023-4015] = "cpe-stable-backport: 
Backported in 6.1.43"
 
 CVE_STATUS[CVE-2023-40283] = "cpe-stable-backport: Backported in 6.1.45"
 
-# CVE-2023-40791 needs backporting (fixed from 6.5rc6)
+CVE_STATUS[CVE-2023-40791] = "fixed-version: only affects 6.3rc1 onwards"
 
 CVE_STATUS[CVE-2023-4128] = "cpe-stable-backport: Backported in 6.1.45"
 
@@ -5082,9 +5082,9 @@ CVE_STATUS[CVE-2023-45863] = "cpe-stable-backport: 
Backported in 6.1.16"
 
 CVE_STATUS[CVE-2023-45871] = "cpe-stable-backport: Backported in 6.1.53"
 
-# CVE-2023-45898 needs backporting (fixed from 6.6rc1)
+CVE_STATUS[CVE-2023-45898] = "fixed-version: only affects 6.5rc1 onwards"
 
-# CVE-2023-4610 has no known resolution
+# CVE-2023-4610 needs backporting (fixed from 6.4)
 
 CVE_STATUS[CVE-2023-4611] = "fixed-version: only affects 6.4rc1 onwards"
 
@@ -5092,15 +5092,29 @@ CVE_STATUS[CVE-2023-4611] = "fixed-version: only 
affects 6.4rc1 onwards"
 
 CVE_STATUS[CVE-2023-4623] = "cpe-stable-backport: Backported in 6.1.53"
 
+CVE_STATUS[CVE-2023-46813] = "cpe-stable-backport: Backported in 6.1.60"
+
+CVE_STATUS[CVE-2023-46862] = "cpe-stable-backport: Backported in 6.1.61"
+
+# CVE-2023-47233 has no known resolution
+
 CVE_STATUS[CVE-2023-4732] = "fixed-version: Fixed from version 5.14rc1"
 
 CVE_STATUS[CVE-2023-4881] = "cpe-stable-backport: Backported in 6.1.54"
 
 CVE_STATUS[CVE-2023-4921] = "cpe-stable-backport: Backported in 6.1.54"
 
-# CVE-2023-5158 has no known resolution
+# CVE-2023-5090 needs backporting (fixed from 6.6rc7)
+
+CVE_STATUS[CVE-2023-5158] = "cpe-stable-backport: Backported in 6.1.57"
+
+CVE_STATUS[CVE-2023-5178] = "cpe-stable-backport: Backported in 6.1.60"
 
 CVE_STATUS[CVE-2023-5197] = "cpe-stable-backport: Backported in 6.1.56"
 
 CVE_STATUS[CVE-2023-5345] = "cpe-stable-backport: Backported in 6.1.56"
 
+# CVE-2023-5633 needs backporting (fixed from 6.6rc6)
+
+CVE_STATUS[CVE-2023-5717] = "cpe-stable-backport: Backported in 6.1.60"
+
diff --git a/meta/recipes-kernel/linux/cve-exclusion_6.5.inc 
b/meta/recipes-kernel/linux/cve-exclusion_6.5.inc
index 69cf7908441..b4086d436c4 100644
--- a/meta/recipes-kernel/linux/cve-exclusion_6.5.inc
+++ b/meta/recipes-kernel/linux/cve-exclusion_6.5.inc
@@ -1,9 +1,9 @@
 
 # Auto-generated CVE metadata, DO NOT EDIT BY HAND.
-# Generated at 2023-10-23 14:03:24.529766+00:00 for version 6.5.7
+# Generated at 2023-11-09 17:13:01.267965+00:00 for version 6.5.10
 
 python check_kernel_cve_status_version() {
-this_version = "6.5.7"
+this_version = "6.5.10"
 kernel_version = d.getVar("LINUX_VERSION")
 if kernel_version != this_version:
 bb.warn("Kernel CVE status needs updating: generated for %s but kernel 
is %s" % (this_version, kernel_version))
@@ -4644,7 +4644,7 @@ CVE_STATUS[CVE-2023-1118] = "fixed-version: Fixed from 
version 6.3rc1"
 
 CVE_STATUS[CVE-2023-1192] = "fixed-version: Fixed from version 6.4rc1"
 
-# CVE-2023-1193 has no known resolution
+CVE_STATUS[CVE-2023-1193] = "fixed-version: Fixed from version 6.3rc6"
 
 CVE_STATUS[CVE-2023-1194] = "fixed-version: Fixed from version 6.4rc6"
 
@@ -4796,7 +4796,7 @@ CVE_STATUS[CVE-2023-25012] = "fixed-version: Fixed from 
version 6.3rc1"
 
 CVE_STATUS[CVE-2023-2513] = "fixed-version: Fixed from version 

[OE-core] Patchtest results for [PATCH] layer.conf: Switch layer to nanbield series only

2023-11-09 Thread Patchtest
Thank you for your submission. Patchtest identified one
or more issues with the patch. Please see the log below for
more information:

---
Testing patch 
/home/patchtest/share/mboxes/layer.conf-Switch-layer-to-nanbield-series-only.patch

FAIL: test commit message presence: Please include a commit message on your 
patch explaining the change (test_mbox.TestMbox.test_commit_message_presence)

PASS: test Signed-off-by presence 
(test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test max line length (test_metadata.TestMetadata.test_max_line_length)
PASS: test mbox format (test_mbox.TestMbox.test_mbox_format)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test target mailing list (test_mbox.TestMbox.test_target_mailing_list)

SKIP: pretest pylint: No python related patches, skipping test 
(test_python_pylint.PyLint.pretest_pylint)
SKIP: pretest src uri left files: Patch cannot be merged 
(test_metadata.TestMetadata.pretest_src_uri_left_files)
SKIP: test CVE tag format: No new CVE patches introduced 
(test_patch.TestPatch.test_cve_tag_format)
SKIP: test Signed-off-by presence: No new CVE patches introduced 
(test_patch.TestPatch.test_signed_off_by_presence)
SKIP: test Upstream-Status presence: No new CVE patches introduced 
(test_patch.TestPatch.test_upstream_status_presence_format)
SKIP: test bugzilla entry format: No bug ID found 
(test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test lic files chksum modified not mentioned: No modified recipes, 
skipping test 
(test_metadata.TestMetadata.test_lic_files_chksum_modified_not_mentioned)
SKIP: test lic files chksum presence: No added recipes, skipping test 
(test_metadata.TestMetadata.test_lic_files_chksum_presence)
SKIP: test license presence: No added recipes, skipping test 
(test_metadata.TestMetadata.test_license_presence)
SKIP: test pylint: No python related patches, skipping test 
(test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now 
(test_mbox.TestMbox.test_series_merge_on_head)
SKIP: test src uri left files: Patch cannot be merged 
(test_metadata.TestMetadata.test_src_uri_left_files)
SKIP: test summary presence: No added recipes, skipping test 
(test_metadata.TestMetadata.test_summary_presence)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this
email with an explanation of why the patch should be accepted. If you
believe these results are due to an error in patchtest, please submit a
bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category
under 'Yocto Project Subprojects'). For more information on specific
failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank
you!

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190393): 
https://lists.openembedded.org/g/openembedded-core/message/190393
Mute This Topic: https://lists.openembedded.org/mt/102489353/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH] layer.conf: Switch layer to nanbield series only

2023-11-09 Thread Richard Purdie
Signed-off-by: Richard Purdie 
---
 meta/conf/layer.conf | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf
index 9b94bbd8b34..bb8b1c81b12 100644
--- a/meta/conf/layer.conf
+++ b/meta/conf/layer.conf
@@ -7,7 +7,7 @@ BBFILE_COLLECTIONS += "core"
 BBFILE_PATTERN_core = "^${LAYERDIR}/"
 BBFILE_PRIORITY_core = "5"
 
-LAYERSERIES_CORENAMES = "nanbield mickledore"
+LAYERSERIES_CORENAMES = "nanbield"
 
 # This should only be incremented on significant changes that will
 # cause compatibility issues with other layers
-- 
2.39.2


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190392): 
https://lists.openembedded.org/g/openembedded-core/message/190392
Mute This Topic: https://lists.openembedded.org/mt/102488851/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH] librsvg: Enable 64bit atomics in crossbeam again for riscv32

2023-11-09 Thread Khem Raj
This works all fine now.

Signed-off-by: Khem Raj 
---
 meta/recipes-gnome/librsvg/librsvg_2.56.3.bb | 1 -
 1 file changed, 1 deletion(-)

diff --git a/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb 
b/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
index b1b7c8d0fc3..43d4059cf2f 100644
--- a/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
+++ b/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
@@ -39,7 +39,6 @@ export RUST_TARGET = "${RUST_HOST_SYS}"
 RUSTFLAGS:append:mips = " --cfg crossbeam_no_atomic_64"
 RUSTFLAGS:append:mipsel = " --cfg crossbeam_no_atomic_64"
 RUSTFLAGS:append:powerpc = " --cfg crossbeam_no_atomic_64"
-RUSTFLAGS:append:riscv32 = " --cfg crossbeam_no_atomic_64"
 
 do_configure[postfuncs] += "cargo_common_do_configure"
 
-- 
2.42.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190391): 
https://lists.openembedded.org/g/openembedded-core/message/190391
Mute This Topic: https://lists.openembedded.org/mt/102487099/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH v2] librsvg: Fix build for riscv32

2023-11-09 Thread Khem Raj
Add missing support for linux-raw-sys

Signed-off-by: Khem Raj 
---
v2: Drop crossbeam 64bit atomics enabling change

 .../librsvg/0001-Add-riscv32-support.patch| 1511 +
 meta/recipes-gnome/librsvg/librsvg_2.56.3.bb  |1 +
 2 files changed, 1512 insertions(+)
 create mode 100644 
meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch

diff --git a/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch 
b/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
new file mode 100644
index 000..2e36eaf5084
--- /dev/null
+++ b/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
@@ -0,0 +1,1511 @@
+From a4066c09bec2d4ec956459237e0a48501cc4780f Mon Sep 17 00:00:00 2001
+From: Khem Raj 
+Date: Wed, 8 Nov 2023 22:41:54 -0800
+Subject: [PATCH] Add riscv32 support
+
+Upstream-Status: Submitted 
[https://github.com/sunfishcode/linux-raw-sys/pull/95]
+
+Signed-off-by: Khem Raj 
+---
+ src/riscv32/ioctl.rs | 1490 +-
+ 1 file changed, 1488 insertions(+), 2 deletions(-)
+
+diff --git a/src/riscv32/ioctl.rs b/src/riscv32/ioctl.rs
+index 85bcbe8..1d97396 100644
+--- a/src/riscv32/ioctl.rs
 b/src/riscv32/ioctl.rs
+@@ -1,3 +1,1489 @@
+-/* automatically generated by rust-bindgen 0.65.1 */
+-
++/* automatically generated by rust-bindgen 0.66.1 */
+ 
++pub const FIONREAD: u32 = 21531;
++pub const FIONBIO: u32 = 21537;
++pub const FIOCLEX: u32 = 21585;
++pub const FIONCLEX: u32 = 21584;
++pub const FIOASYNC: u32 = 21586;
++pub const FIOQSIZE: u32 = 21600;
++pub const TCXONC: u32 = 21514;
++pub const TCFLSH: u32 = 21515;
++pub const TIOCSCTTY: u32 = 21518;
++pub const TIOCSPGRP: u32 = 21520;
++pub const TIOCOUTQ: u32 = 21521;
++pub const TIOCSTI: u32 = 21522;
++pub const TIOCSWINSZ: u32 = 21524;
++pub const TIOCMGET: u32 = 21525;
++pub const TIOCMBIS: u32 = 21526;
++pub const TIOCMBIC: u32 = 21527;
++pub const TIOCMSET: u32 = 21528;
++pub const TIOCSSOFTCAR: u32 = 21530;
++pub const TIOCLINUX: u32 = 21532;
++pub const TIOCCONS: u32 = 21533;
++pub const TIOCSSERIAL: u32 = 21535;
++pub const TIOCPKT: u32 = 21536;
++pub const TIOCNOTTY: u32 = 21538;
++pub const TIOCSETD: u32 = 21539;
++pub const TIOCSBRK: u32 = 21543;
++pub const TIOCCBRK: u32 = 21544;
++pub const TIOCSRS485: u32 = 21551;
++pub const TIOCSPTLCK: u32 = 1074025521;
++pub const TIOCSIG: u32 = 1074025526;
++pub const TIOCVHANGUP: u32 = 21559;
++pub const TIOCSERCONFIG: u32 = 21587;
++pub const TIOCSERGWILD: u32 = 21588;
++pub const TIOCSERSWILD: u32 = 21589;
++pub const TIOCSLCKTRMIOS: u32 = 21591;
++pub const TIOCSERGSTRUCT: u32 = 21592;
++pub const TIOCSERGETLSR: u32 = 21593;
++pub const TIOCSERGETMULTI: u32 = 21594;
++pub const TIOCSERSETMULTI: u32 = 21595;
++pub const TIOCMIWAIT: u32 = 21596;
++pub const TCGETS: u32 = 21505;
++pub const TCGETA: u32 = 21509;
++pub const TCSBRK: u32 = 21513;
++pub const TCSBRKP: u32 = 21541;
++pub const TCSETA: u32 = 21510;
++pub const TCSETAF: u32 = 21512;
++pub const TCSETAW: u32 = 21511;
++pub const TIOCEXCL: u32 = 21516;
++pub const TIOCNXCL: u32 = 21517;
++pub const TIOCGDEV: u32 = 2147767346;
++pub const TIOCGEXCL: u32 = 2147767360;
++pub const TIOCGICOUNT: u32 = 21597;
++pub const TIOCGLCKTRMIOS: u32 = 21590;
++pub const TIOCGPGRP: u32 = 21519;
++pub const TIOCGPKT: u32 = 2147767352;
++pub const TIOCGPTLCK: u32 = 2147767353;
++pub const TIOCGPTN: u32 = 2147767344;
++pub const TIOCGPTPEER: u32 = 21569;
++pub const TIOCGRS485: u32 = 21550;
++pub const TIOCGSERIAL: u32 = 21534;
++pub const TIOCGSID: u32 = 21545;
++pub const TIOCGSOFTCAR: u32 = 21529;
++pub const TIOCGWINSZ: u32 = 21523;
++pub const TCGETS2: u32 = 2150388778;
++pub const TCGETX: u32 = 21554;
++pub const TCSETS: u32 = 21506;
++pub const TCSETS2: u32 = 1076646955;
++pub const TCSETSF: u32 = 21508;
++pub const TCSETSF2: u32 = 1076646957;
++pub const TCSETSW: u32 = 21507;
++pub const TCSETSW2: u32 = 1076646956;
++pub const TCSETX: u32 = 21555;
++pub const TCSETXF: u32 = 21556;
++pub const TCSETXW: u32 = 21557;
++pub const TIOCGETD: u32 = 21540;
++pub const MTIOCGET: u32 = 2150657282;
++pub const BLKSSZGET: u32 = 4712;
++pub const BLKPBSZGET: u32 = 4731;
++pub const BLKROSET: u32 = 4701;
++pub const BLKROGET: u32 = 4702;
++pub const BLKRRPART: u32 = 4703;
++pub const BLKGETSIZE: u32 = 4704;
++pub const BLKFLSBUF: u32 = 4705;
++pub const BLKRASET: u32 = 4706;
++pub const BLKRAGET: u32 = 4707;
++pub const BLKFRASET: u32 = 4708;
++pub const BLKFRAGET: u32 = 4709;
++pub const BLKSECTSET: u32 = 4710;
++pub const BLKSECTGET: u32 = 4711;
++pub const BLKPG: u32 = 4713;
++pub const BLKBSZGET: u32 = 2148012656;
++pub const BLKBSZSET: u32 = 1074270833;
++pub const BLKGETSIZE64: u32 = 2148012658;
++pub const BLKTRACESETUP: u32 = 3225948787;
++pub const BLKTRACESTART: u32 = 4724;
++pub const BLKTRACESTOP: u32 = 4725;
++pub const BLKTRACETEARDOWN: u32 = 4726;
++pub const BLKDISCARD: u32 = 4727;
++pub const BLKIOMIN: u32 = 4728;
++pub const BLKIOOPT: u32 = 4729;

Re: [OE-core] [PATCH] librsvg: Fix build for riscv32

2023-11-09 Thread Khem Raj
On Thu, Nov 9, 2023 at 6:00 AM Richard Purdie
 wrote:
>
> On Wed, 2023-11-08 at 22:50 -0800, Khem Raj wrote:
> > Add missing support for linux-raw-sys
> >
> > Signed-off-by: Khem Raj 
> > ---
> >  .../librsvg/0001-Add-riscv32-support.patch| 1511 +
> >  meta/recipes-gnome/librsvg/librsvg_2.56.3.bb  |3 +-
> >  2 files changed, 1513 insertions(+), 1 deletion(-)
> >  create mode 100644 
> > meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
> >
> > diff --git 
> > a/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch 
> > b/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
> > new file mode 100644
> > index 000..2e36eaf5084
> > --- /dev/null
> > +++ b/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
> > @@ -0,0 +1,1511 @@
> > +From a4066c09bec2d4ec956459237e0a48501cc4780f Mon Sep 17 00:00:00 2001
> > +From: Khem Raj 
> > +Date: Wed, 8 Nov 2023 22:41:54 -0800
> > +Subject: [PATCH] Add riscv32 support
> > +
> > +Upstream-Status: Submitted 
> > [https://github.com/sunfishcode/linux-raw-sys/pull/95]
> > +
> > +Signed-off-by: Khem Raj 
> > +---
> > + src/riscv32/ioctl.rs | 1490 +-
> > + 1 file changed, 1488 insertions(+), 2 deletions(-)
> > +
> >
> [...]
>
> > +2.42.1
> > +
> > diff --git a/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb 
> > b/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
> > index 4b9aaeecbe7..32d720d2b92 100644
> > --- a/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
> > +++ b/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
> > @@ -19,6 +19,7 @@ inherit cargo_common gnomebase pixbufcache 
> > gobject-introspection rust vala gi-do
> >  require ${BPN}-crates.inc
> >
> >  SRC_URI += 
> > "file://0001-Makefile.am-pass-rust-target-to-cargo-also-when-not-.patch \
> > +
> > file://0001-Add-riscv32-support.patch;patchdir=../cargo_home/bitbake/linux-raw-sys-0.4.3
> >  \
> > "
> >
> >  SRC_URI[archive.sha256sum] = 
> > "5a328048a02d014645cd27f61140f4e0b11280fb2c7f2a21864fe0c59ac1ce88"
> > @@ -38,7 +39,7 @@ export RUST_TARGET = "${RUST_HOST_SYS}"
> >  RUSTFLAGS:append:mips = " --cfg crossbeam_no_atomic_64"
> >  RUSTFLAGS:append:mipsel = " --cfg crossbeam_no_atomic_64"
> >  RUSTFLAGS:append:powerpc = " --cfg crossbeam_no_atomic_64"
> > -RUSTFLAGS:append:riscv32 = " --cfg crossbeam_no_atomic_64"
> > +#RUSTFLAGS:append:riscv32 = " --cfg crossbeam_no_atomic_64"
> >
> >  do_configure[postfuncs] += "cargo_common_do_configure"
>
> Is this change at the end meant to be here? It isn't mentioned in the
> commit message.

Yeah I saw that too and
I think it can be a separate commit. Let me send a v2 without atomic_64 for now.
and follow up with the patch for atomics

>
> Cheers,
>
> Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190389): 
https://lists.openembedded.org/g/openembedded-core/message/190389
Mute This Topic: https://lists.openembedded.org/mt/102481280/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH v2] oeqa,ssh: Handle SSHCall timeout error code

2023-11-09 Thread luca fancellu
The current code in ssh.py is terminating the ssh process that
does not finish its computation in a given timeout (when timeout
is passed), the SSHCall function is returning the process error
code.

The Openssl ssh before version 8.6_p1 is returning 0 when it is
terminated, from commit 8a9520836e71830f4fccca066dba73fea3d16bda
onwards (version >= 8.6_p1) ssh is returning 255 instead.

So for version of ssh older than 8.6_p1 when the SSHCall time out,
the return code will be 0, meaning success, which is wrong.

Fix this issue checking if the process has timeout (hence it's been
terminated) and checking if the returned code is 0, in that case
set it to 255 to advertise that an error occurred.

Add a test case excercising the timeout in the SSHTest, test_ssh
test function.

Signed-off-by: Luca Fancellu 
---
 meta/lib/oeqa/core/target/ssh.py   | 17 -
 meta/lib/oeqa/runtime/cases/ssh.py |  3 +++
 2 files changed, 19 insertions(+), 1 deletion(-)

diff --git a/meta/lib/oeqa/core/target/ssh.py b/meta/lib/oeqa/core/target/ssh.py
index f22836d390ac..f4dd0ca417a4 100644
--- a/meta/lib/oeqa/core/target/ssh.py
+++ b/meta/lib/oeqa/core/target/ssh.py
@@ -232,11 +232,12 @@ def SSHCall(command, logger, timeout=None, **opts):
 output_raw = b''
 starttime = time.time()
 process = subprocess.Popen(command, **options)
+has_timeout = False
 if timeout:
 endtime = starttime + timeout
 eof = False
 os.set_blocking(process.stdout.fileno(), False)
-while time.time() < endtime and not eof:
+while not has_timeout and not eof:
 try:
 logger.debug('Waiting for process output: time: %s, 
endtime: %s' % (time.time(), endtime))
 if select.select([process.stdout], [], [], 5)[0] != []:
@@ -257,6 +258,10 @@ def SSHCall(command, logger, timeout=None, **opts):
 logger.debug('BlockingIOError')
 continue
 
+if time.time() >= endtime:
+logger.debug('SSHCall has timeout! Time: %s, endtime: %s' 
% (time.time(), endtime))
+has_timeout = True
+
 process.stdout.close()
 
 # process hasn't returned yet
@@ -293,6 +298,16 @@ def SSHCall(command, logger, timeout=None, **opts):
 pass
 process.wait()
 
+if has_timeout:
+# Version of openssh before 8.6_p1 returns error code 0 when killed
+# by a signal, when the timeout occurs we will receive a 0 error
+# code because the process is been terminated and it's wrong 
because
+# that value means success, but the process timed out.
+# Afterwards, from version 8.6_p1 onwards, the returned code is 
255.
+# Fix this behaviour by checking the return code
+if process.returncode == 0:
+process.returncode = 255
+
 options = {
 "stdout": subprocess.PIPE,
 "stderr": subprocess.STDOUT,
diff --git a/meta/lib/oeqa/runtime/cases/ssh.py 
b/meta/lib/oeqa/runtime/cases/ssh.py
index 13aac5439698..cdbef595008c 100644
--- a/meta/lib/oeqa/runtime/cases/ssh.py
+++ b/meta/lib/oeqa/runtime/cases/ssh.py
@@ -13,6 +13,9 @@ class SSHTest(OERuntimeTestCase):
 @OETestDepends(['ping.PingTest.test_ping'])
 @OEHasPackage(['dropbear', 'openssh-sshd'])
 def test_ssh(self):
+(status, output) = self.target.run('sleep 20', timeout=2)
+msg='run() timed out but return code was zero.'
+self.assertNotEqual(status, 0, msg=msg)
 (status, output) = self.target.run('uname -a')
 self.assertEqual(status, 0, msg='SSH Test failed: %s' % output)
 (status, output) = self.target.run('cat /etc/controllerimage')
-- 
2.34.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190388): 
https://lists.openembedded.org/g/openembedded-core/message/190388
Mute This Topic: https://lists.openembedded.org/mt/102486415/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core][kirkstone][PATCH] goarch: Move Go architecture mapping to a library

2023-11-09 Thread Jose Quaresma
Bruce Ashfield  escreveu no dia quinta, 9/11/2023
à(s) 14:18:

> On Thu, Nov 9, 2023 at 7:37 AM Peter Marko 
> wrote:
> >
> > From: Peter Marko 
> >
> > Other spaces uses the Go architecture definitions as their own (for
> > example, container arches are defined to be Go arches). To make it
> > easier for other places to use this mapping, move the code that does the
> > translation of OpenEmbedded arches to Go arches to a library.
> >
> > (From oe-core rev: 3e86f72fc2e1cc2e5ea4b4499722d736941167ce)
> >
> > This commit together with meta-virtualization commit
> > 115f6367f37095415f289fb6981cda9608ac72ff
> > broke meta-virtualization master used with
> > meta-lts-mixins kirkstone/go which is our primary
> > usecase for having kirkstone/go mixin layer
> >
>
> I was trying to figure out the best way to address this issue
> just yesterday.
>
> If the patch is accepted for backport, then that's definitely
> another solution.
>

Looks like this kirstone patch doesn't change anything on the
goarch.bbclass
functionality so everything should work as before.
If it is not possible to integrate we can try to move some of these changes
to
the meta-lts-mixins kirkstone/go.

Jose


> Otherwise, I'll have to carry the meta-virt patch that I did
> in nanbield on master until such a time as any branches
> that will reasonably work with meta-virt master have the
> go_arch library change.
>
> Alternatively, I suppose we could trap the error and use
> a fallback, etc, but I won't get complicated yet :)
>
> Bruce
>
> > Manually crafted since cherry-pick had too many conflicts:
> > * different path to classes
> > * additional architecture loongarch64
> > * different way how to import library
> >
> > Signed-off-by: Peter Marko 
> > Cc: Joshua Watt 
> > Cc: Bruce Ashfield 
> > Cc: Jose Quaresma 
> > ---
> >  meta/classes/base.bbclass   |  2 +-
> >  meta/classes/goarch.bbclass | 27 +++
> >  meta/lib/oe/go.py   | 32 
> >  3 files changed, 36 insertions(+), 25 deletions(-)
> >  create mode 100644 meta/lib/oe/go.py
> >
> > diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
> > index b15c5839b6..ee26ee5597 100644
> > --- a/meta/classes/base.bbclass
> > +++ b/meta/classes/base.bbclass
> > @@ -12,7 +12,7 @@ inherit logging
> >
> >  OE_EXTRA_IMPORTS ?= ""
> >
> > -OE_IMPORTS += "os sys time oe.path oe.utils oe.types oe.package
> oe.packagegroup oe.sstatesig oe.lsb oe.cachedpath oe.license oe.qa
> oe.reproducible oe.rust ${OE_EXTRA_IMPORTS}"
> > +OE_IMPORTS += "os sys time oe.path oe.utils oe.types oe.package
> oe.packagegroup oe.sstatesig oe.lsb oe.cachedpath oe.license oe.qa
> oe.reproducible oe.rust oe.go ${OE_EXTRA_IMPORTS}"
> >  OE_IMPORTS[type] = "list"
> >
> >  PACKAGECONFIG_CONFARGS ??= ""
> > diff --git a/meta/classes/goarch.bbclass b/meta/classes/goarch.bbclass
> > index 92fec16b82..394c0c5d84 100644
> > --- a/meta/classes/goarch.bbclass
> > +++ b/meta/classes/goarch.bbclass
> > @@ -61,31 +61,10 @@ SECURITY_NOPIE_CFLAGS ??= ""
> >  CCACHE_DISABLE ?= "1"
> >
> >  def go_map_arch(a, d):
> > -import re
> > -if re.match('i.86', a):
> > -return '386'
> > -elif a == 'x86_64':
> > -return 'amd64'
> > -elif re.match('arm.*', a):
> > -return 'arm'
> > -elif re.match('aarch64.*', a):
> > -return 'arm64'
> > -elif re.match('mips64el.*', a):
> > -return 'mips64le'
> > -elif re.match('mips64.*', a):
> > -return 'mips64'
> > -elif a == 'mips':
> > -return 'mips'
> > -elif a == 'mipsel':
> > -return 'mipsle'
> > -elif re.match('p(pc|owerpc)(64le)', a):
> > -return 'ppc64le'
> > -elif re.match('p(pc|owerpc)(64)', a):
> > -return 'ppc64'
> > -elif a == 'riscv64':
> > -return 'riscv64'
> > -else:
> > +arch = oe.go.map_arch(a)
> > +if not arch:
> >  raise bb.parse.SkipRecipe("Unsupported CPU architecture: %s" %
> a)
> > +return arch
> >
> >  def go_map_arm(a, d):
> >  if a.startswith("arm"):
> > diff --git a/meta/lib/oe/go.py b/meta/lib/oe/go.py
> > new file mode 100644
> > index 00..9996057f12
> > --- /dev/null
> > +++ b/meta/lib/oe/go.py
> > @@ -0,0 +1,32 @@
> > +#
> > +# Copyright OpenEmbedded Contributors
> > +#
> > +# SPDX-License-Identifier: MIT
> > +#
> > +
> > +import re
> > +
> > +def map_arch(a):
> > +if re.match('i.86', a):
> > +return '386'
> > +elif a == 'x86_64':
> > +return 'amd64'
> > +elif re.match('arm.*', a):
> > +return 'arm'
> > +elif re.match('aarch64.*', a):
> > +return 'arm64'
> > +elif re.match('mips64el.*', a):
> > +return 'mips64le'
> > +elif re.match('mips64.*', a):
> > +return 'mips64'
> > +elif a == 'mips':
> > +return 'mips'
> > +elif a == 'mipsel':
> > +return 'mipsle'
> > +elif re.match('p(pc|owerpc)(64le)', a):
> > +return 'ppc64le'
> > +elif 

Re: [OE-core][kirkstone][PATCH] goarch: Move Go architecture mapping to a library

2023-11-09 Thread Bruce Ashfield
On Thu, Nov 9, 2023 at 7:37 AM Peter Marko  wrote:
>
> From: Peter Marko 
>
> Other spaces uses the Go architecture definitions as their own (for
> example, container arches are defined to be Go arches). To make it
> easier for other places to use this mapping, move the code that does the
> translation of OpenEmbedded arches to Go arches to a library.
>
> (From oe-core rev: 3e86f72fc2e1cc2e5ea4b4499722d736941167ce)
>
> This commit together with meta-virtualization commit
> 115f6367f37095415f289fb6981cda9608ac72ff
> broke meta-virtualization master used with
> meta-lts-mixins kirkstone/go which is our primary
> usecase for having kirkstone/go mixin layer
>

I was trying to figure out the best way to address this issue
just yesterday.

If the patch is accepted for backport, then that's definitely
another solution.

Otherwise, I'll have to carry the meta-virt patch that I did
in nanbield on master until such a time as any branches
that will reasonably work with meta-virt master have the
go_arch library change.

Alternatively, I suppose we could trap the error and use
a fallback, etc, but I won't get complicated yet :)

Bruce

> Manually crafted since cherry-pick had too many conflicts:
> * different path to classes
> * additional architecture loongarch64
> * different way how to import library
>
> Signed-off-by: Peter Marko 
> Cc: Joshua Watt 
> Cc: Bruce Ashfield 
> Cc: Jose Quaresma 
> ---
>  meta/classes/base.bbclass   |  2 +-
>  meta/classes/goarch.bbclass | 27 +++
>  meta/lib/oe/go.py   | 32 
>  3 files changed, 36 insertions(+), 25 deletions(-)
>  create mode 100644 meta/lib/oe/go.py
>
> diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
> index b15c5839b6..ee26ee5597 100644
> --- a/meta/classes/base.bbclass
> +++ b/meta/classes/base.bbclass
> @@ -12,7 +12,7 @@ inherit logging
>
>  OE_EXTRA_IMPORTS ?= ""
>
> -OE_IMPORTS += "os sys time oe.path oe.utils oe.types oe.package 
> oe.packagegroup oe.sstatesig oe.lsb oe.cachedpath oe.license oe.qa 
> oe.reproducible oe.rust ${OE_EXTRA_IMPORTS}"
> +OE_IMPORTS += "os sys time oe.path oe.utils oe.types oe.package 
> oe.packagegroup oe.sstatesig oe.lsb oe.cachedpath oe.license oe.qa 
> oe.reproducible oe.rust oe.go ${OE_EXTRA_IMPORTS}"
>  OE_IMPORTS[type] = "list"
>
>  PACKAGECONFIG_CONFARGS ??= ""
> diff --git a/meta/classes/goarch.bbclass b/meta/classes/goarch.bbclass
> index 92fec16b82..394c0c5d84 100644
> --- a/meta/classes/goarch.bbclass
> +++ b/meta/classes/goarch.bbclass
> @@ -61,31 +61,10 @@ SECURITY_NOPIE_CFLAGS ??= ""
>  CCACHE_DISABLE ?= "1"
>
>  def go_map_arch(a, d):
> -import re
> -if re.match('i.86', a):
> -return '386'
> -elif a == 'x86_64':
> -return 'amd64'
> -elif re.match('arm.*', a):
> -return 'arm'
> -elif re.match('aarch64.*', a):
> -return 'arm64'
> -elif re.match('mips64el.*', a):
> -return 'mips64le'
> -elif re.match('mips64.*', a):
> -return 'mips64'
> -elif a == 'mips':
> -return 'mips'
> -elif a == 'mipsel':
> -return 'mipsle'
> -elif re.match('p(pc|owerpc)(64le)', a):
> -return 'ppc64le'
> -elif re.match('p(pc|owerpc)(64)', a):
> -return 'ppc64'
> -elif a == 'riscv64':
> -return 'riscv64'
> -else:
> +arch = oe.go.map_arch(a)
> +if not arch:
>  raise bb.parse.SkipRecipe("Unsupported CPU architecture: %s" % a)
> +return arch
>
>  def go_map_arm(a, d):
>  if a.startswith("arm"):
> diff --git a/meta/lib/oe/go.py b/meta/lib/oe/go.py
> new file mode 100644
> index 00..9996057f12
> --- /dev/null
> +++ b/meta/lib/oe/go.py
> @@ -0,0 +1,32 @@
> +#
> +# Copyright OpenEmbedded Contributors
> +#
> +# SPDX-License-Identifier: MIT
> +#
> +
> +import re
> +
> +def map_arch(a):
> +if re.match('i.86', a):
> +return '386'
> +elif a == 'x86_64':
> +return 'amd64'
> +elif re.match('arm.*', a):
> +return 'arm'
> +elif re.match('aarch64.*', a):
> +return 'arm64'
> +elif re.match('mips64el.*', a):
> +return 'mips64le'
> +elif re.match('mips64.*', a):
> +return 'mips64'
> +elif a == 'mips':
> +return 'mips'
> +elif a == 'mipsel':
> +return 'mipsle'
> +elif re.match('p(pc|owerpc)(64le)', a):
> +return 'ppc64le'
> +elif re.match('p(pc|owerpc)(64)', a):
> +return 'ppc64'
> +elif a == 'riscv64':
> +return 'riscv64'
> +return ''
> --
> 2.30.2
>


-- 
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190386): 
https://lists.openembedded.org/g/openembedded-core/message/190386
Mute This Topic: https://lists.openembedded.org/mt/102484351/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org

Re: [OE-core] [PATCH] librsvg: Fix build for riscv32

2023-11-09 Thread Richard Purdie
On Wed, 2023-11-08 at 22:50 -0800, Khem Raj wrote:
> Add missing support for linux-raw-sys
> 
> Signed-off-by: Khem Raj 
> ---
>  .../librsvg/0001-Add-riscv32-support.patch| 1511 +
>  meta/recipes-gnome/librsvg/librsvg_2.56.3.bb  |3 +-
>  2 files changed, 1513 insertions(+), 1 deletion(-)
>  create mode 100644 
> meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
> 
> diff --git 
> a/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch 
> b/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
> new file mode 100644
> index 000..2e36eaf5084
> --- /dev/null
> +++ b/meta/recipes-gnome/librsvg/librsvg/0001-Add-riscv32-support.patch
> @@ -0,0 +1,1511 @@
> +From a4066c09bec2d4ec956459237e0a48501cc4780f Mon Sep 17 00:00:00 2001
> +From: Khem Raj 
> +Date: Wed, 8 Nov 2023 22:41:54 -0800
> +Subject: [PATCH] Add riscv32 support
> +
> +Upstream-Status: Submitted 
> [https://github.com/sunfishcode/linux-raw-sys/pull/95]
> +
> +Signed-off-by: Khem Raj 
> +---
> + src/riscv32/ioctl.rs | 1490 +-
> + 1 file changed, 1488 insertions(+), 2 deletions(-)
> +
> 
[...]

> +2.42.1
> +
> diff --git a/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb 
> b/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
> index 4b9aaeecbe7..32d720d2b92 100644
> --- a/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
> +++ b/meta/recipes-gnome/librsvg/librsvg_2.56.3.bb
> @@ -19,6 +19,7 @@ inherit cargo_common gnomebase pixbufcache 
> gobject-introspection rust vala gi-do
>  require ${BPN}-crates.inc
>  
>  SRC_URI += 
> "file://0001-Makefile.am-pass-rust-target-to-cargo-also-when-not-.patch \
> +
> file://0001-Add-riscv32-support.patch;patchdir=../cargo_home/bitbake/linux-raw-sys-0.4.3
>  \
> "
>  
>  SRC_URI[archive.sha256sum] = 
> "5a328048a02d014645cd27f61140f4e0b11280fb2c7f2a21864fe0c59ac1ce88"
> @@ -38,7 +39,7 @@ export RUST_TARGET = "${RUST_HOST_SYS}"
>  RUSTFLAGS:append:mips = " --cfg crossbeam_no_atomic_64"
>  RUSTFLAGS:append:mipsel = " --cfg crossbeam_no_atomic_64"
>  RUSTFLAGS:append:powerpc = " --cfg crossbeam_no_atomic_64"
> -RUSTFLAGS:append:riscv32 = " --cfg crossbeam_no_atomic_64"
> +#RUSTFLAGS:append:riscv32 = " --cfg crossbeam_no_atomic_64"
>  
>  do_configure[postfuncs] += "cargo_common_do_configure"

Is this change at the end meant to be here? It isn't mentioned in the
commit message.

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190385): 
https://lists.openembedded.org/g/openembedded-core/message/190385
Mute This Topic: https://lists.openembedded.org/mt/102481280/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core][kirkstone][PATCH] goarch: Move Go architecture mapping to a library

2023-11-09 Thread Peter Marko via lists.openembedded.org
From: Peter Marko 

Other spaces uses the Go architecture definitions as their own (for
example, container arches are defined to be Go arches). To make it
easier for other places to use this mapping, move the code that does the
translation of OpenEmbedded arches to Go arches to a library.

(From oe-core rev: 3e86f72fc2e1cc2e5ea4b4499722d736941167ce)

This commit together with meta-virtualization commit
115f6367f37095415f289fb6981cda9608ac72ff
broke meta-virtualization master used with
meta-lts-mixins kirkstone/go which is our primary
usecase for having kirkstone/go mixin layer

Manually crafted since cherry-pick had too many conflicts:
* different path to classes
* additional architecture loongarch64
* different way how to import library

Signed-off-by: Peter Marko 
Cc: Joshua Watt 
Cc: Bruce Ashfield 
Cc: Jose Quaresma 
---
 meta/classes/base.bbclass   |  2 +-
 meta/classes/goarch.bbclass | 27 +++
 meta/lib/oe/go.py   | 32 
 3 files changed, 36 insertions(+), 25 deletions(-)
 create mode 100644 meta/lib/oe/go.py

diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index b15c5839b6..ee26ee5597 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -12,7 +12,7 @@ inherit logging
 
 OE_EXTRA_IMPORTS ?= ""
 
-OE_IMPORTS += "os sys time oe.path oe.utils oe.types oe.package 
oe.packagegroup oe.sstatesig oe.lsb oe.cachedpath oe.license oe.qa 
oe.reproducible oe.rust ${OE_EXTRA_IMPORTS}"
+OE_IMPORTS += "os sys time oe.path oe.utils oe.types oe.package 
oe.packagegroup oe.sstatesig oe.lsb oe.cachedpath oe.license oe.qa 
oe.reproducible oe.rust oe.go ${OE_EXTRA_IMPORTS}"
 OE_IMPORTS[type] = "list"
 
 PACKAGECONFIG_CONFARGS ??= ""
diff --git a/meta/classes/goarch.bbclass b/meta/classes/goarch.bbclass
index 92fec16b82..394c0c5d84 100644
--- a/meta/classes/goarch.bbclass
+++ b/meta/classes/goarch.bbclass
@@ -61,31 +61,10 @@ SECURITY_NOPIE_CFLAGS ??= ""
 CCACHE_DISABLE ?= "1"
 
 def go_map_arch(a, d):
-import re
-if re.match('i.86', a):
-return '386'
-elif a == 'x86_64':
-return 'amd64'
-elif re.match('arm.*', a):
-return 'arm'
-elif re.match('aarch64.*', a):
-return 'arm64'
-elif re.match('mips64el.*', a):
-return 'mips64le'
-elif re.match('mips64.*', a):
-return 'mips64'
-elif a == 'mips':
-return 'mips'
-elif a == 'mipsel':
-return 'mipsle'
-elif re.match('p(pc|owerpc)(64le)', a):
-return 'ppc64le'
-elif re.match('p(pc|owerpc)(64)', a):
-return 'ppc64'
-elif a == 'riscv64':
-return 'riscv64'
-else:
+arch = oe.go.map_arch(a)
+if not arch:
 raise bb.parse.SkipRecipe("Unsupported CPU architecture: %s" % a)
+return arch
 
 def go_map_arm(a, d):
 if a.startswith("arm"):
diff --git a/meta/lib/oe/go.py b/meta/lib/oe/go.py
new file mode 100644
index 00..9996057f12
--- /dev/null
+++ b/meta/lib/oe/go.py
@@ -0,0 +1,32 @@
+#
+# Copyright OpenEmbedded Contributors
+#
+# SPDX-License-Identifier: MIT
+#
+
+import re
+
+def map_arch(a):
+if re.match('i.86', a):
+return '386'
+elif a == 'x86_64':
+return 'amd64'
+elif re.match('arm.*', a):
+return 'arm'
+elif re.match('aarch64.*', a):
+return 'arm64'
+elif re.match('mips64el.*', a):
+return 'mips64le'
+elif re.match('mips64.*', a):
+return 'mips64'
+elif a == 'mips':
+return 'mips'
+elif a == 'mipsel':
+return 'mipsle'
+elif re.match('p(pc|owerpc)(64le)', a):
+return 'ppc64le'
+elif re.match('p(pc|owerpc)(64)', a):
+return 'ppc64'
+elif a == 'riscv64':
+return 'riscv64'
+return ''
-- 
2.30.2


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190384): 
https://lists.openembedded.org/g/openembedded-core/message/190384
Mute This Topic: https://lists.openembedded.org/mt/102484351/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH] oeqa,ssh: Handle SSHCall timeout error code

2023-11-09 Thread luca fancellu

>> +except SSHCallTimeout:
>> +# Version of openssh before 8.6_p1 returns error code 0 when killed 
>> by
>> +# a signal, when the timeout occurs we will receive a 0 error code
>> +# because the process is been terminated and it's wrong because that
>> +# value means success, but the process timed out.
>> +# Afterwards, from version 8.6_p1 onwards, the returned code is 255.
>> +# Fix this behaviour by checking the return code
>> +if process.returncode == 0:
>> +process.returncode = 255
> 
> This breaks most of our tests:
> 
> https://autobuilder.yoctoproject.org/typhoon/#/builders/40/builds/8103/steps/13/logs/stdio
> https://autobuilder.yoctoproject.org/typhoon/#/builders/76/builds/8054/steps/21/logs/stdio
> https://autobuilder.yoctoproject.org/typhoon/#/builders/87/builds/6037/steps/14/logs/stdio
> https://autobuilder.yoctoproject.org/typhoon/#/builders/72/builds/8106/steps/15/logs/stdio
> 
> and more...


Hi Alexandre,

Sorry about that, I will push a v2 that fixes the issues

Cheers,
Luca



-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190383): 
https://lists.openembedded.org/g/openembedded-core/message/190383
Mute This Topic: https://lists.openembedded.org/mt/102461629/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH] bitbake.conf: Drop PE and PR from WORKDIR and STAMP

2023-11-09 Thread Richard Purdie
On Wed, 2023-11-08 at 09:34 +0100, Martin Jansa wrote:
> On Thu, Aug 10, 2023 at 6:41 PM Richard Purdie
>  wrote:
> > Once, we relied upon stamps changing to rebuild. PE and PR are
> > packaging
> > variables and are reflected in the taskhashes when/where they're
> > used so
> > they do not need to be in STAMP.
> > 
> > Similarly, once, multiple versions were something which was useful
> > in
> > WORKDIR but this is really just noise causing long pathnames now.
> > 
> > Drop PR and PE from these variables to clean up the paths a bit.
> > 
> > This may break some tool assumptions about paths but those are
> > probably
> > things we need to fix.
> > 
> 
> 
> meta/conf/bitbake.conf: -fdebug-prefix-
> map=${S}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR} \
> meta/conf/bitbake.conf: -fdebug-prefix-
> map=${B}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR} \
> 
> What about changing ^ as well to match workdir names? I know it works
> as it is now and it might be useful to know from which PR the PN-dbg
> files are, but as we don't depend on PR in WORKDIR maybe we don't
> need it in /usr/src/debug as well anymore.

I'm ok with trying that. I think we could drop PE there too and I'm
even wondering about PV...

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190382): 
https://lists.openembedded.org/g/openembedded-core/message/190382
Mute This Topic: https://lists.openembedded.org/mt/100667206/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH v2] libdnf: Fix arm arch mapping issues for qemuarmv5

2023-11-09 Thread Richard Purdie
qemuarmv5 currently fails with:

$ dnf --help
Error: Incorrect or unknown "arch": armv5hl

Fix this by removing the code in libdnf which is trying to be too
clever, we don't need this mappings given the way OE configures rpm.

Signed-off-by: Richard Purdie 
---
 .../libdnf/libdnf/armarch.patch   | 42 +++
 meta/recipes-devtools/libdnf/libdnf_0.72.0.bb |  1 +
 2 files changed, 43 insertions(+)
 create mode 100644 meta/recipes-devtools/libdnf/libdnf/armarch.patch

v2 - actually send the right patch

diff --git a/meta/recipes-devtools/libdnf/libdnf/armarch.patch 
b/meta/recipes-devtools/libdnf/libdnf/armarch.patch
new file mode 100644
index 000..99eaf1d521f
--- /dev/null
+++ b/meta/recipes-devtools/libdnf/libdnf/armarch.patch
@@ -0,0 +1,42 @@
+We change the way rpm architectures work, we make the machine name the default 
machine
+specific package architecture.
+
+This arm mapping code can work or in the case of qemuarmv5, it doesn't as it 
creates
+armv5hl which doesn't exist and causes errrors. We can simply remove it, we 
don't need it.
+
+Upstream-Status: Inappropriate [Relies on OE rpm config]
+
+Index: git/libdnf/hy-util.cpp
+===
+--- git.orig/libdnf/hy-util.cpp
 git/libdnf/hy-util.cpp
+@@ -117,29 +117,6 @@ hy_detect_arch(char **arch)
+ if (uname() < 0)
+ return DNF_ERROR_FAILED;
+ 
+-if (!strncmp(un.machine, "armv", 4)) {
+-/* un.machine is armvXE, where X is version number and E is
+- * endianness (b or l); we need to add modifiers such as
+- * h (hardfloat), n (neon). Neon is a requirement of armv8 so
+- * as far as rpm is concerned armv8l is the equivilent of armv7hnl
+- * (or 7hnb) so we don't explicitly add 'n' for 8+ as it's expected. 
*/
+-char endian = un.machine[strlen(un.machine)-1];
+-char *modifier = un.machine + 5;
+-while(isdigit(*modifier)) /* keep armv7, armv8, armv9, armv10, 
armv100, ... */
+-modifier++;
+-if (getauxval(AT_HWCAP) & HWCAP_ARM_VFP)
+-*modifier++ = 'h';
+-if ((atoi(un.machine+4) == 7) && (getauxval(AT_HWCAP) & 
HWCAP_ARM_NEON))
+-*modifier++ = 'n';
+-*modifier++ = endian;
+-*modifier = 0;
+-}
+-#ifdef __MIPSEL__
+-if (!strcmp(un.machine, "mips"))
+-strcpy(un.machine, "mipsel");
+-else if (!strcmp(un.machine, "mips64"))
+-strcpy(un.machine, "mips64el");
+-#endif
+ *arch = g_strdup(un.machine);
+ return 0;
+ }
diff --git a/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb 
b/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb
index d58ad0353ff..a8685a16048 100644
--- a/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb
+++ b/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb
@@ -10,6 +10,7 @@ SRC_URI = 
"git://github.com/rpm-software-management/libdnf;branch=dnf-4-master;p

file://0001-Get-parameters-for-both-libsolv-and-libsolvext-libdn.patch \
file://enable_test_data_dir_set.patch \
file://0001-drop-FindPythonInstDir.cmake.patch \
+   file://armarch.patch \
"
 
 SRCREV = "908dba63c9e18c86a2d81166ce7523559e65338c"
-- 
2.39.2


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190381): 
https://lists.openembedded.org/g/openembedded-core/message/190381
Mute This Topic: https://lists.openembedded.org/mt/102483061/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH] libdnf: Fix arm arch mapping issues for qemuarmv5

2023-11-09 Thread Richard Purdie
qemuarmv5 currently fails with:

$ dnf --help
Error: Incorrect or unknown "arch": armv5hl

Fix this by removing the code in libdnf which is trying to be too
clever, we don't need this mappings given the way OE configures rpm.

Signed-off-by: Richard Purdie 
---
 meta/recipes-devtools/libdnf/libdnf_0.72.0.bb | 1 +
 meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb | 8 
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb 
b/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb
index d58ad0353ff..a8685a16048 100644
--- a/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb
+++ b/meta/recipes-devtools/libdnf/libdnf_0.72.0.bb
@@ -10,6 +10,7 @@ SRC_URI = 
"git://github.com/rpm-software-management/libdnf;branch=dnf-4-master;p

file://0001-Get-parameters-for-both-libsolv-and-libsolvext-libdn.patch \
file://enable_test_data_dir_set.patch \
file://0001-drop-FindPythonInstDir.cmake.patch \
+   file://armarch.patch \
"
 
 SRCREV = "908dba63c9e18c86a2d81166ce7523559e65338c"
diff --git a/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb 
b/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb
index 671c0a290e8..c9bf85013f4 100644
--- a/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb
+++ b/meta/recipes-graphics/x11-common/xserver-nodm-init_3.0.bb
@@ -17,7 +17,7 @@ S = "${WORKDIR}"
 # Since we refer to ROOTLESS_X which is normally enabled per-machine
 PACKAGE_ARCH = "${MACHINE_ARCH}"
 
-inherit update-rc.d systemd features_check
+inherit systemd features_check
 
 REQUIRED_DISTRO_FEATURES = "x11 ${@oe.utils.conditional('ROOTLESS_X', '1', 
'pam', '', d)}"
 
@@ -64,8 +64,8 @@ do_install() {
 
 RDEPENDS:${PN} = "xinit ${@oe.utils.conditional('ROOTLESS_X', '1', 
'xuser-account libcap libcap-bin', '', d)}"
 
-INITSCRIPT_NAME = "xserver-nodm"
-INITSCRIPT_PARAMS = "start 9 5 . stop 20 0 1 2 3 6 ."
-SYSTEMD_SERVICE:${PN} = "xserver-nodm.service"
+#INITSCRIPT_NAME = "xserver-nodm"
+#INITSCRIPT_PARAMS = "start 9 5 . stop 20 0 1 2 3 6 ."
+#SYSTEMD_SERVICE:${PN} = "xserver-nodm.service"
 
 RCONFLICTS:${PN} = "xserver-common (< 1.34-r9) x11-common"
-- 
2.39.2


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190380): 
https://lists.openembedded.org/g/openembedded-core/message/190380
Mute This Topic: https://lists.openembedded.org/mt/102482971/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [yocto] QA notification for completed autobuilder build (yocto-4.0.14.rc1)

2023-11-09 Thread Jing Hui Tham
Hi All,
 
QA for yocto-4.0.14.rc1 is completed. This is the full report for this release: 
 
https://git.yoctoproject.org/cgit/cgit.cgi/yocto-testresults-contrib/tree/?h=intel-yocto-testresults
 
=== Summary 
No high milestone defects.
 
No new issue found. 
 
Thanks,
Jing Hui



> -Original Message-
> From: yo...@lists.yoctoproject.org  On Behalf
> Of Pokybuild User
> Sent: Saturday, November 4, 2023 1:50 PM
> To: yo...@lists.yoctoproject.org
> Cc: qa-build-notificat...@lists.yoctoproject.org
> Subject: [yocto] QA notification for completed autobuilder build (yocto-
> 4.0.14.rc1)
> 
> 
> A build flagged for QA (yocto-4.0.14.rc1) was completed on the autobuilder
> and is available at:
> 
> 
> https://autobuilder.yocto.io/pub/releases/yocto-4.0.14.rc1
> 
> 
> Build URL:
> https://autobuilder.yoctoproject.org/typhoon/#/builders/83/builds/6132
> 
> Build hash information:
> 
> bitbake: 6c1ffa9091d0c53a100e8c8c15122d28642034bd
> meta-agl: 09890bc1ce3d1836f0e35fbae7713f54d70a72ae
> meta-arm: b187fb9232ca0a6b5f8f90b4715958546fc41d73
> meta-aws: 408f9331156ec101014cf065314d3b90e79e6814
> meta-gplv2: d2f8b5cdb285b72a4ed93450f6703ca27aa42e8a
> meta-intel: 3f0115e9e59f94af54b74838f4f9ea7584ae
> meta-mingw: f6b38ce3c90e1600d41c2ebb41e152936a0357d7
> meta-openembedded: 79a6f60dabad9e5b0e041efa91379447ef030482
> meta-virtualization: 2d8b3cba8ff27c9ec2187a52b6a551fe1dcfaa07
> oecore: 0eb8e67aa6833df0cde29833568a70e65c21d7e5
> poky: d8d6d921fad14b82167d9f031d4fca06b5e01883
> 
> 
> 
> This is an automated message from the Yocto Project Autobuilder
> Git: git://git.yoctoproject.org/yocto-autobuilder2
> Email: richard.pur...@linuxfoundation.org
> 
> 
> 

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190379): 
https://lists.openembedded.org/g/openembedded-core/message/190379
Mute This Topic: https://lists.openembedded.org/mt/102414813/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH] oeqa,ssh: Handle SSHCall timeout error code

2023-11-09 Thread Alexandre Belloni via lists.openembedded.org
On 08/11/2023 11:25:47+, luca fancellu wrote:
> The current code in ssh.py is terminating the ssh process that
> does not finish its computation in a given timeout (when timeout
> is passed), the SSHCall function is returning the process error
> code.
> 
> The Openssl ssh before version 8.6_p1 is returning 0 when it is
> terminated, from commit 8a9520836e71830f4fccca066dba73fea3d16bda
> onwards (version >= 8.6_p1) ssh is returning 255 instead.
> 
> So for version of ssh older than 8.6_p1 when the SSHCall time out,
> the return code will be 0, meaning success, which is wrong.
> 
> Fix this issue checking if the process has timeout (hence it's been
> terminated) and checking if the returned code is 0, in that case
> set it to 255 to advertise that an error occurred.
> 
> Add a test case exercising the timeout in the SSHTest, test_ssh
> test function.
> 
> Signed-off-by: Luca Fancellu 
> ---
>  meta/lib/oeqa/core/target/ssh.py   | 21 -
>  meta/lib/oeqa/runtime/cases/ssh.py |  3 +++
>  2 files changed, 23 insertions(+), 1 deletion(-)
> 
> diff --git a/meta/lib/oeqa/core/target/ssh.py 
> b/meta/lib/oeqa/core/target/ssh.py
> index f22836d390ac..4fe763aaefba 100644
> --- a/meta/lib/oeqa/core/target/ssh.py
> +++ b/meta/lib/oeqa/core/target/ssh.py
> @@ -224,6 +224,11 @@ class OESSHTarget(OETarget):
>  remoteDir = os.path.join(remotePath, tmpDir.lstrip("/"))
>  self.deleteDir(remoteDir)
>  
> +
> +class SSHCallTimeout(Exception):
> +pass
> +
> +
>  def SSHCall(command, logger, timeout=None, **opts):
>  
>  def run():
> @@ -232,9 +237,9 @@ def SSHCall(command, logger, timeout=None, **opts):
>  output_raw = b''
>  starttime = time.time()
>  process = subprocess.Popen(command, **options)
> +eof = False
>  if timeout:
>  endtime = starttime + timeout
> -eof = False
>  os.set_blocking(process.stdout.fileno(), False)
>  while time.time() < endtime and not eof:
>  try:
> @@ -293,6 +298,11 @@ def SSHCall(command, logger, timeout=None, **opts):
>  pass
>  process.wait()
>  
> +# Process has timed out, raise exception here so that the process at
> +# this point is already terminated/killed
> +if not eof:
> +raise SSHCallTimeout
> +
>  options = {
>  "stdout": subprocess.PIPE,
>  "stderr": subprocess.STDOUT,
> @@ -313,6 +323,15 @@ def SSHCall(command, logger, timeout=None, **opts):
>  
>  try:
>  run()
> +except SSHCallTimeout:
> +# Version of openssh before 8.6_p1 returns error code 0 when killed 
> by
> +# a signal, when the timeout occurs we will receive a 0 error code
> +# because the process is been terminated and it's wrong because that
> +# value means success, but the process timed out.
> +# Afterwards, from version 8.6_p1 onwards, the returned code is 255.
> +# Fix this behaviour by checking the return code
> +if process.returncode == 0:
> +process.returncode = 255

This breaks most of our tests:

https://autobuilder.yoctoproject.org/typhoon/#/builders/40/builds/8103/steps/13/logs/stdio
https://autobuilder.yoctoproject.org/typhoon/#/builders/76/builds/8054/steps/21/logs/stdio
https://autobuilder.yoctoproject.org/typhoon/#/builders/87/builds/6037/steps/14/logs/stdio
https://autobuilder.yoctoproject.org/typhoon/#/builders/72/builds/8106/steps/15/logs/stdio

and more...

>  except:
>  # Need to guard against a SystemExit or other exception ocurring
>  # whilst running and ensure we don't leave a process behind.
> diff --git a/meta/lib/oeqa/runtime/cases/ssh.py 
> b/meta/lib/oeqa/runtime/cases/ssh.py
> index 13aac5439698..cdbef595008c 100644
> --- a/meta/lib/oeqa/runtime/cases/ssh.py
> +++ b/meta/lib/oeqa/runtime/cases/ssh.py
> @@ -13,6 +13,9 @@ class SSHTest(OERuntimeTestCase):
>  @OETestDepends(['ping.PingTest.test_ping'])
>  @OEHasPackage(['dropbear', 'openssh-sshd'])
>  def test_ssh(self):
> +(status, output) = self.target.run('sleep 20', timeout=2)
> +msg='run() timed out but return code was zero.'
> +self.assertNotEqual(status, 0, msg=msg)
>  (status, output) = self.target.run('uname -a')
>  self.assertEqual(status, 0, msg='SSH Test failed: %s' % output)
>  (status, output) = self.target.run('cat /etc/controllerimage')
> 
> base-commit: 6806bd23499aa66942c2b6b8fbc52dbec8ff8483
> -- 
> 2.34.1
> 

> 
> 
> 


-- 
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#190378): 
https://lists.openembedded.org/g/openembedded-core/message/190378
Mute This Topic: https://lists.openembedded.org/mt/102461629/21656
Group Owner: