[OE-core] [PATCH] ncurses: Fix CVE-2023-50495
From: Mingli Yu Backport a patch [1] to fix CVE-2023-50495. [1] http://ncurses.scripts.mit.edu/?p=ncurses.git;a=commitdiff;h=7723dd6799ab10b32047ec73b14df9f107bafe99 Signed-off-by: Mingli Yu --- .../ncurses/files/CVE-2023-50495.patch| 301 ++ meta/recipes-core/ncurses/ncurses_6.4.bb | 1 + 2 files changed, 302 insertions(+) create mode 100644 meta/recipes-core/ncurses/files/CVE-2023-50495.patch diff --git a/meta/recipes-core/ncurses/files/CVE-2023-50495.patch b/meta/recipes-core/ncurses/files/CVE-2023-50495.patch new file mode 100644 index 00..7d90ddd30f --- /dev/null +++ b/meta/recipes-core/ncurses/files/CVE-2023-50495.patch @@ -0,0 +1,301 @@ +From 7daae3f2139a678fe0ae0b42fcf8d807cbff485c Mon Sep 17 00:00:00 2001 +From: Mingli Yu +Date: Sun, 4 Feb 2024 13:42:38 +0800 +Subject: [PATCH] parse_entry.c: check return value of _nc_save_str + +* check return value of _nc_save_str(), in special case for tic where +extended capabilities are processed but the terminal description was +not initialized (report by Ziqiao Kong). + +* regenerate llib-* files. + +CVE: CVE-2023-50495 + +Upstream-Status: Backport [http://ncurses.scripts.mit.edu/?p=ncurses.git;a=commitdiff;h=7723dd6799ab10b32047ec73b14df9f107bafe99] + +Signed-off-by: Mingli Yu +--- + ncurses/llib-lncurses | 15 +++ + ncurses/llib-lncursest | 15 +++ + ncurses/llib-lncursestw | 15 +++ + ncurses/llib-lncursesw | 15 +++ + ncurses/llib-ltinfo | 15 +++ + ncurses/llib-ltinfot| 15 +++ + ncurses/llib-ltinfotw | 15 +++ + ncurses/llib-ltinfow| 15 +++ + ncurses/tinfo/parse_entry.c | 23 --- + 9 files changed, 136 insertions(+), 7 deletions(-) + +diff --git a/ncurses/llib-lncurses b/ncurses/llib-lncurses +index 211cf3b7..e4190aa2 100644 +--- a/ncurses/llib-lncurses b/ncurses/llib-lncurses +@@ -3656,6 +3656,21 @@ char*tiparm( + ...) + { return(*(char **)0); } + ++#undef tiparm_s ++char *tiparm_s( ++ int num_expected, ++ int tparm_type, ++ const char *string, ++ ...) ++ { return(*(char **)0); } ++ ++#undef tiscan_s ++int tiscan_s( ++ int *num_expected, ++ int *tparm_type, ++ const char *string) ++ { return(*(int *)0); } ++ + #undef _nc_tiparm + char *_nc_tiparm( + int expected, +diff --git a/ncurses/llib-lncursest b/ncurses/llib-lncursest +index 1b09d676..e07abba6 100644 +--- a/ncurses/llib-lncursest b/ncurses/llib-lncursest +@@ -3741,6 +3741,21 @@ char*tiparm( + ...) + { return(*(char **)0); } + ++#undef tiparm_s ++char *tiparm_s( ++ int num_expected, ++ int tparm_type, ++ const char *string, ++ ...) ++ { return(*(char **)0); } ++ ++#undef tiscan_s ++int tiscan_s( ++ int *num_expected, ++ int *tparm_type, ++ const char *string) ++ { return(*(int *)0); } ++ + #undef _nc_tiparm + char *_nc_tiparm( + int expected, +diff --git a/ncurses/llib-lncursestw b/ncurses/llib-lncursestw +index 4576e0fc..747c6be8 100644 +--- a/ncurses/llib-lncursestw b/ncurses/llib-lncursestw +@@ -4702,6 +4702,21 @@ char*tiparm( + ...) + { return(*(char **)0); } + ++#undef tiparm_s ++char *tiparm_s( ++ int num_expected, ++ int tparm_type, ++ const char *string, ++ ...) ++ { return(*(char **)0); } ++ ++#undef tiscan_s ++int tiscan_s( ++ int *num_expected, ++ int *tparm_type, ++ const char *string) ++ { return(*(int *)0); } ++ + #undef _nc_tiparm + char *_nc_tiparm( + int expected, +diff --git a/ncurses/llib-lncursesw b/ncurses/llib-lncursesw +index 127350d2..862305d9 100644 +--- a/ncurses/llib-lncursesw b/ncurses/llib-lncursesw +@@ -4617,6 +4617,21 @@ char*tiparm( + ...) + { return(*(char **)0); } + ++#undef tiparm_s ++char *tiparm_s( ++ int num_expected, ++ int tparm_type, ++ const char *string, ++ ...) ++ { return(*(char **)0); } ++ ++#undef tiscan_s ++int tiscan_s( ++ int *num_expected, ++ int *tparm_type, ++ const char *string) ++ { return(*(int *)0); } ++ + #undef _nc_tiparm + char *_nc_tiparm( + int expected, +diff --git a/ncurses/llib-ltinfo b/ncurses/llib-ltinfo +index a5cd7cd3..31e5e9a6 100644 +--- a/ncurses/llib-ltinfo b/ncurses/llib-ltinfo +@@ -927,6 +927,21 @@ char *tiparm( + ...) +
[OE-core] [kirkstone][PATCH 1/2] python3-unittest-automake-output: add new recipe for ptest integration
From: Ross Burton This package contains modules for both unittest and pytest that alter the output to look like automake's 'make check' output, for better integration with ptest. Signed-off-by: Ross Burton Signed-off-by: Richard Purdie (cherry picked from commit 961e4f3fc786715fc136fa446686972a4a95a3d5) Signed-off-by: Mingli Yu --- meta/conf/distro/include/maintainers.inc| 1 + .../python/python3-unittest-automake-output_0.1.bb | 13 + 2 files changed, 14 insertions(+) create mode 100644 meta/recipes-devtools/python/python3-unittest-automake-output_0.1.bb diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc index bfc14951fe..09c1599915 100644 --- a/meta/conf/distro/include/maintainers.inc +++ b/meta/conf/distro/include/maintainers.inc @@ -684,6 +684,7 @@ RECIPE_MAINTAINER:pn-python3-toml = "Tim Orling " RECIPE_MAINTAINER:pn-python3-tomli = "Tim Orling " RECIPE_MAINTAINER:pn-python3-typing-extensions = "Tim Orling " RECIPE_MAINTAINER:pn-python3-typogrify = "Alexander Kanavin " +RECIPE_MAINTAINER:pn-python3-unittest-automake-output = "Ross Burton " RECIPE_MAINTAINER:pn-python3-urllib3 = "Tim Orling " RECIPE_MAINTAINER:pn-python3-vcversioner = "Bruce Ashfield " RECIPE_MAINTAINER:pn-python3-wcwidth = "Tim Orling " diff --git a/meta/recipes-devtools/python/python3-unittest-automake-output_0.1.bb b/meta/recipes-devtools/python/python3-unittest-automake-output_0.1.bb new file mode 100644 index 00..ba58c18df0 --- /dev/null +++ b/meta/recipes-devtools/python/python3-unittest-automake-output_0.1.bb @@ -0,0 +1,13 @@ +SUMMARY = "Modules to make unittest and pytest look like Automake output, for ptest" +HOMEPAGE = "https://gitlab.com/rossburton/python-unittest-automake-output; +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=f6f16008d9fb7349f06609329f1ab93b" + +SRC_URI = "git://gitlab.com/rossburton/python-unittest-automake-output;protocol=https;branch=main" +SRCREV = "06537edb18f3641c70bce25256f6ecf5f5164ead" + +S = "${WORKDIR}/git" + +inherit python_flit_core + +BBCLASSEXTEND = "native nativesdk" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#197548): https://lists.openembedded.org/g/openembedded-core/message/197548 Mute This Topic: https://lists.openembedded.org/mt/105173226/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 2/2] python3-unittest-automake-output: upgrade to 0.2
From: Ross Burton Specifically this fixes the issue where if a pytest test suite fails during collection then the errors are hidden. Signed-off-by: Ross Burton Signed-off-by: Richard Purdie (cherry picked from commit db0e82135ce73d0d6d55b2c2ac17a3fdec8aca99) Signed-off-by: Mingli Yu --- ...ke-output_0.1.bb => python3-unittest-automake-output_0.2.bb} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename meta/recipes-devtools/python/{python3-unittest-automake-output_0.1.bb => python3-unittest-automake-output_0.2.bb} (89%) diff --git a/meta/recipes-devtools/python/python3-unittest-automake-output_0.1.bb b/meta/recipes-devtools/python/python3-unittest-automake-output_0.2.bb similarity index 89% rename from meta/recipes-devtools/python/python3-unittest-automake-output_0.1.bb rename to meta/recipes-devtools/python/python3-unittest-automake-output_0.2.bb index ba58c18df0..1fc6180d0e 100644 --- a/meta/recipes-devtools/python/python3-unittest-automake-output_0.1.bb +++ b/meta/recipes-devtools/python/python3-unittest-automake-output_0.2.bb @@ -4,7 +4,7 @@ LICENSE = "MIT" LIC_FILES_CHKSUM = "file://LICENSE;md5=f6f16008d9fb7349f06609329f1ab93b" SRC_URI = "git://gitlab.com/rossburton/python-unittest-automake-output;protocol=https;branch=main" -SRCREV = "06537edb18f3641c70bce25256f6ecf5f5164ead" +SRCREV = "aebdfb188e368c690ea55cf6c9c9ffa1a52def65" S = "${WORKDIR}/git" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#197549): https://lists.openembedded.org/g/openembedded-core/message/197549 Mute This Topic: https://lists.openembedded.org/mt/105173227/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] weston-init: Add --system for useradd
From: Mingli Yu Add --system parameter for useradd to avoid intruducing .bashrc and .profile under home dir to fix the below error. $ bitbake core-image-weston | DEBUG: Executing python function set_image_size | DEBUG: 352679.60 = 271292 * 1.30 | DEBUG: 455079.60 = max(352679.60, 65536)[352679.60] + 102400 | DEBUG: 455080.00 = int(455079.60) | DEBUG: 455080 = aligned(455080) | DEBUG: returning 455080 | DEBUG: Python function set_image_size finished | DEBUG: Executing shell function do_image_tar | tar: ./home/weston/.bashrc: Unknown file type; file ignored | tar: ./home/weston/.profile: Unknown file type; file ignored | tar: Exiting with failure status due to previous errors | WARNING: /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/temp/run.do_image_tar.1972897:150 exit 1 from '[ $? -eq 1 ]' | WARNING: Backtrace (BB generated script): #1: do_image_tar, /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/temp/run.do_image_tar.1972897, line 150 #2: main, /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/temp/run.do_image_tar.1972897, line 156 | DEBUG: Python function extend_recipe_sysroot finished | DEBUG: Executing python function set_image_size | DEBUG: 352679.60 = 271292 * 1.30 | DEBUG: 455079.60 = max(352679.60, 65536)[352679.60] + 102400 | DEBUG: 455080.00 = int(455079.60) | DEBUG: 455080 = aligned(455080) | DEBUG: returning 455080 | DEBUG: Python function set_image_size finished | DEBUG: Executing shell function do_image_ext4 | DEBUG: Executing dd if=/dev/zero of=/buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/deploy-core-image-weston-image-complete/core-image-weston-qemux86-64.rootfs-20240315032140.ext4 seek=455080 count=0 bs=1024 | 0+0 records in | 0+0 records out | 0 bytes copied, 0.00136946 s, 0.0 kB/s | DEBUG: Actual Rootfs size: 268184 /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/rootfs | DEBUG: Actual Partition size: 466001920 | DEBUG: Executing mkfs.ext4 -F -i 4096 /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/deploy-core-image-weston-image-complete/core-image-weston-qemux86-64.rootfs-20240315032140.ext4 -d /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/rootfs | mke2fs 1.47.0 (5-Feb-2023) | Discarding device blocks: done | Creating filesystem with 455080 1k blocks and 113792 inodes | Filesystem UUID: 2031373e-63cd-4711-968b-4023ff7d6a90 | Superblock backups stored on blocks: | 8193, 24577, 40961, 57345, 73729, 204801, 221185, 401409 | | Allocating group tables: done | Writing inode tables: done | Creating journal (8192 blocks): done | Copying files into the device: __populate_fs: ignoring entry ".bashrc" | .bashrc: File not found by ext2_lookup while looking up ".bashrc" | mkfs.ext4: File not found by ext2_lookup while populating file system | WARNING: /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/temp/run.do_image_ext4.1972895:178 exit 1 from 'mkfs.$fstype -F $extra_imagecmd /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/deploy-core-image-weston-image-complete/core-image-weston-qemux86-64.rootfs-20240315032140.$fstype -d /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/rootfs' | WARNING: Backtrace (BB generated script): | #1: oe_mkext234fs, /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/temp/run.do_image_ext4.1972895, line 178 | #2: do_image_ext4, /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/temp/run.do_image_ext4.1972895, line 150 | #3: main, /buildarea1/test/yocto/builds/poky-build-weston/tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/temp/run.do_image_ext4.1972895, line 215 ERROR: Task (/buildarea1/test/yocto/poky/meta/recipes-graphics/images/core-image-weston.bb:do_image_ext4) failed with exit code '1' Before the patch: $ ls -a tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/rootfs/home/weston/ . .. .bashrc .profile After the patch: $ ls -a tmp/work/qemux86_64-poky-linux/core-image-weston/1.0/rootfs/home/weston/ . .. Signed-off-by: Mingli Yu --- meta/recipes-graphics/wayland/weston-init.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-graphics/wayland/weston-init.bb b/meta/recipes-graphics/wayland/weston-init.bb index 024e400665..542b86818c 100644 --- a/meta/recipes-graphics/wayland/weston-init.bb +++ b/meta/recipes-graphics/wayland/weston-init.bb @@ -101,6 +101,6 @@ FILES:${PN} += "\ CONFFILES:${PN}
Re: [OE-core] [PATCH 1/3] pkgconfig: Correct the PV
On 1/25/24 17:29, Alexander Kanavin wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Thu, 25 Jan 2024 at 10:25, Yu, Mingli wrote: From: Mingli Yu Correct the PV to make the version consistent. SRCREV = "d97db4fae4c1cd099b506970b285dc2afd818ea2" -PV = "0.29.2+git" +PV = "0.29.2" 0.29.2 release tag maps to a different commit, so we cannot drop +git: https://gitlab.freedesktop.org/pkg-config/pkg-config/-/tags/pkg-config-0.29.2 Thanks Alex to pointing out! The commit [1] did make to update pkgconfig to a non-release version. [1] https://git.openembedded.org/openembedded-core/commit/?id=fd621eefee1a4acaffa3754b76f8e14d2684ab3f It helps if you explain the broader goal. Why does version as reported by rpm need to match version as reported by component exactly? Can't you strip all the suffixes from what rpm says? For some reasons, the user complains the version which rpm says is not consistent with the version which reported by some binary as below though no function impacts. So we try to fix the gap. # rpm -qa | grep pkgconfig pkgconfig-0.29.2+git0+d97db4fae4-r0.core2_64 # rpm -ql pkgconfig /usr /usr/bin /usr/bin/pkg-config /usr/bin/x86_64-wrs-linux-gnu-pkg-config /usr/share /usr/share/aclocal /usr/share/aclocal/pkg.m4 # pkg-config --version 0.29.2 Thanks, Alex -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194347): https://lists.openembedded.org/g/openembedded-core/message/194347 Mute This Topic: https://lists.openembedded.org/mt/103950927/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 3/3] blktool: Make the version consistent
From: Mingli Yu Update the version to make package version consistent and there is indeed the source as blktool_4.orig.tar.gz [1]. Before the patch: # rpm -qa | grep blktool blktool-4+7.1-r0.core2_64 # blktool blktool version 4 usage: blktool [options] DEVICE COMMAND [args...] command list: ATA defect-mgmt { off | on } ATA dev-keep-settings { off | on } any dev-read-ahead { off | on } [snip] After the patch: # rpm -qa | grep blktool blktool-4-r0.core2_64 # blktool blktool version 4 usage: blktool [options] DEVICE COMMAND [args...] command list: ATA defect-mgmt { off | on } ATA dev-keep-settings { off | on } any dev-read-ahead { off | on } [snip] [1] http://snapshot.debian.org/archive/debian/20160728T043443Z/pool/main/b/blktool/ Signed-off-by: Mingli Yu --- meta/recipes-extended/blktool/{blktool_4-7.1.bb => blktool_4.bb} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename meta/recipes-extended/blktool/{blktool_4-7.1.bb => blktool_4.bb} (100%) diff --git a/meta/recipes-extended/blktool/blktool_4-7.1.bb b/meta/recipes-extended/blktool/blktool_4.bb similarity index 100% rename from meta/recipes-extended/blktool/blktool_4-7.1.bb rename to meta/recipes-extended/blktool/blktool_4.bb -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194312): https://lists.openembedded.org/g/openembedded-core/message/194312 Mute This Topic: https://lists.openembedded.org/mt/103950929/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 1/3] pkgconfig: Correct the PV
From: Mingli Yu Correct the PV to make the version consistent. Before the patch: # rpm -qa | grep pkgconfig pkgconfig-0.29.2+git0+d97db4fae4-r0.core2_64 # rpm -ql pkgconfig /usr /usr/bin /usr/bin/pkg-config /usr/bin/x86_64-wrs-linux-gnu-pkg-config /usr/share /usr/share/aclocal /usr/share/aclocal/pkg.m4 # pkg-config --version 0.29.2 After the patch: # rpm -qa | grep pkgconfig pkgconfig-0.29.2-r0.core2_64 # rpm -ql pkgconfig /usr /usr/bin /usr/bin/pkg-config /usr/bin/x86_64-wrs-linux-gnu-pkg-config /usr/share /usr/share/aclocal /usr/share/aclocal/pkg.m4 # pkg-config --version 0.29.2 Signed-off-by: Mingli Yu --- meta/recipes-devtools/pkgconfig/pkgconfig_git.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb b/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb index 16e6c5b609..53d2335317 100644 --- a/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb +++ b/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb @@ -9,7 +9,7 @@ LICENSE = "GPL-2.0-or-later" LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" SRCREV = "d97db4fae4c1cd099b506970b285dc2afd818ea2" -PV = "0.29.2+git" +PV = "0.29.2" SRC_URI = "git://gitlab.freedesktop.org/pkg-config/pkg-config.git;branch=master;protocol=https \ file://pkg-config-esdk.in \ -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194310): https://lists.openembedded.org/g/openembedded-core/message/194310 Mute This Topic: https://lists.openembedded.org/mt/103950927/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 2/3] icu: Make the version consistent
From: Mingli Yu Update the version in the bb name to make the version consistent. Before the patch: # rpm -qa | grep icu icu-74+1-r0.core2_64 # rpm -ql icu /usr /usr/bin /usr/bin/derb [snip] # derb --version derb version 1.1 (ICU version 74.1). Copyright (C) 2016 and later: Unicode, Inc. and others. License & terms of use: http://www.unicode.org/copyright.html After the patch: # rpm -qa | grep icu icu-74.1-r0.core2_64 # rpm -ql icu /usr /usr/bin /usr/bin/derb [snip] # derb --version derb version 1.1 (ICU version 74.1). Copyright (C) 2016 and later: Unicode, Inc. and others. License & terms of use: http://www.unicode.org/copyright.html Signed-off-by: Mingli Yu --- meta/recipes-support/icu/{icu_74-1.bb => icu_74.1.bb} | 8 1 file changed, 4 insertions(+), 4 deletions(-) rename meta/recipes-support/icu/{icu_74-1.bb => icu_74.1.bb} (96%) diff --git a/meta/recipes-support/icu/icu_74-1.bb b/meta/recipes-support/icu/icu_74.1.bb similarity index 96% rename from meta/recipes-support/icu/icu_74-1.bb rename to meta/recipes-support/icu/icu_74.1.bb index 88ded166b5..196b3dc579 100644 --- a/meta/recipes-support/icu/icu_74-1.bb +++ b/meta/recipes-support/icu/icu_74.1.bb @@ -14,7 +14,7 @@ S = "${WORKDIR}/icu/source" SPDX_S = "${WORKDIR}/icu" STAGING_ICU_DIR_NATIVE = "${STAGING_DATADIR_NATIVE}/${BPN}/${PV}" -ICU_MAJOR_VER = "${@d.getVar('PV').split('-')[0]}" +ICU_MAJOR_VER = "${@d.getVar('PV').split('.')[0]}" inherit autotools pkgconfig github-releases @@ -81,15 +81,15 @@ BBCLASSEXTEND = "native nativesdk" LIC_FILES_CHKSUM = "file://../LICENSE;md5=08dc3852df8fffa807301902ad899ff8" def icu_download_version(d): -pvsplit = d.getVar('PV').split('-') +pvsplit = d.getVar('PV').split('.') return pvsplit[0] + "_" + pvsplit[1] def icu_download_folder(d): -pvsplit = d.getVar('PV').split('-') +pvsplit = d.getVar('PV').split('.') return pvsplit[0] + "-" + pvsplit[1] def icu_install_folder(d): -pvsplit = d.getVar('PV').split('-') +pvsplit = d.getVar('PV').split('.') return pvsplit[0] + "." + pvsplit[1] ICU_PV = "${@icu_download_version(d)}" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194311): https://lists.openembedded.org/g/openembedded-core/message/194311 Mute This Topic: https://lists.openembedded.org/mt/103950928/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 2/3] gnupg: Make the version consistent
Thanks Richard and Ross's comments! I will try to send the patch to the upstream. Thanks, On 1/20/24 01:41, Ross Burton wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On 19 Jan 2024, at 11:33, Yu, Mingli via lists.openembedded.org wrote: file://0004-autogen.sh-fix-find-version-for-beta-checking.patch \ file://0001-Woverride-init-is-not-needed-with-gcc-9.patch \ file://fix-ldap.patch \ + file://0001-autogen.sh-Remove-the-unknown-suffix.patch \ 0004-autogen.sh-fix-find-version-for-beta-checking.patch already does something similar, so the patches should be merged instead of having a series of incremental fixes. Also, as RP said, engaging with upstream here would be good. Ross -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194113): https://lists.openembedded.org/g/openembedded-core/message/194113 Mute This Topic: https://lists.openembedded.org/mt/103827979/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 3/3] libgcrypt: Make the version consistent
From: Mingli Yu The change [1] extends a -unknown suffix to version and introduces the version inconsistency. Before the patch: # rpm -qa | grep libgcrypt libgcrypt-1.10.3-r0.core2_64 libgcrypt-ptest-1.10.3-r0.core2_64 # rpm -ql libgcrypt /usr /usr/bin /usr/bin/mpicalc /usr/lib64 /usr/lib64/libgcrypt.so.20 /usr/lib64/libgcrypt.so.20.4.3 # mpicalc --help mpicalc 2.0 libgcrypt 1.10.3-unknown [snip] After the patch: # rpm -qa | grep libgcrypt libgcrypt-1.10.3-r0.core2_64 libgcrypt-ptest-1.10.3-r0.core2_64 # rpm -ql libgcrypt /usr /usr/bin /usr/bin/mpicalc /usr/lib64 /usr/lib64/libgcrypt.so.20 /usr/lib64/libgcrypt.so.20.4.3 # mpicalc --help mpicalc 2.0 libgcrypt 1.10.3 [snip] [1] https://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgcrypt.git;a=commitdiff;h=0f2c6ce2;hp=86e5e06a97ae13b8bbf6923ecc76e02b9c429b46 Signed-off-by: Mingli Yu --- ...autogen.sh-Remove-the-unknown-suffix.patch | 50 +++ .../libgcrypt/libgcrypt_1.10.3.bb | 1 + 2 files changed, 51 insertions(+) create mode 100644 meta/recipes-support/libgcrypt/files/0001-autogen.sh-Remove-the-unknown-suffix.patch diff --git a/meta/recipes-support/libgcrypt/files/0001-autogen.sh-Remove-the-unknown-suffix.patch b/meta/recipes-support/libgcrypt/files/0001-autogen.sh-Remove-the-unknown-suffix.patch new file mode 100644 index 00..6023eb82b2 --- /dev/null +++ b/meta/recipes-support/libgcrypt/files/0001-autogen.sh-Remove-the-unknown-suffix.patch @@ -0,0 +1,50 @@ +From c951a588d63d0fdf8571112a04dec5d09b27bc3c Mon Sep 17 00:00:00 2001 +From: Mingli Yu +Date: Thu, 18 Jan 2024 16:45:56 +0800 +Subject: [PATCH] autogen.sh: Remove the unknown suffix + +The commit [0f2c6ce2 build: Let configure create the VERSION file.] [1] +extends the version to make the version inconsistent as below: + # rpm -qa | grep libgcrypt + libgcrypt-1.10.3-r0.core2_64 + libgcrypt-ptest-1.10.3-r0.core2_64 + # rpm -ql libgcrypt + /usr + /usr/bin + /usr/bin/mpicalc + /usr/lib64 + /usr/lib64/libgcrypt.so.20 + /usr/lib64/libgcrypt.so.20.4.3 + # mpicalc --help + mpicalc 2.0 + libgcrypt 1.10.3-unknown + [snip] + +Considering we mainly use a release version in oe, so remove the added +suffix to keep consistent. + +[1] https://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgcrypt.git;a=commitdiff;h=0f2c6ce2;hp=86e5e06a97ae13b8bbf6923ecc76e02b9c429b46 + +Upstream-Status: Inappropriate [OE-Specific as we use a release version in oe] + +Signed-off-by: Mingli Yu +--- + .../libgcrypt/1.10.3/libgcrypt-1.10.3/autogen.sh| 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/autogen.sh b/autogen.sh +index 9b36158..d5cccd2 100755 +--- a/autogen.sh b/autogen.sh +@@ -266,7 +266,7 @@ if [ "$myhost" = "find-version" ]; then + else + ingit=no + beta=yes +- tmp="-unknown" ++ tmp="" + rev="000" + rvd="0" + fi +-- +2.25.1 + diff --git a/meta/recipes-support/libgcrypt/libgcrypt_1.10.3.bb b/meta/recipes-support/libgcrypt/libgcrypt_1.10.3.bb index 1c4f4d6038..a2f97d08f0 100644 --- a/meta/recipes-support/libgcrypt/libgcrypt_1.10.3.bb +++ b/meta/recipes-support/libgcrypt/libgcrypt_1.10.3.bb @@ -25,6 +25,7 @@ SRC_URI = "${GNUPG_MIRROR}/libgcrypt/libgcrypt-${PV}.tar.bz2 \ file://0004-tests-Makefile.am-fix-undefined-reference-to-pthread.patch \ file://no-native-gpg-error.patch \ file://no-bench-slope.patch \ + file://0001-autogen.sh-Remove-the-unknown-suffix.patch \ file://run-ptest \ " SRC_URI[sha256sum] = "8b0870897ac5ac67ded568dcfadf45969cfa8a6beb0fd60af2a9eadc2a3272aa" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194031): https://lists.openembedded.org/g/openembedded-core/message/194031 Mute This Topic: https://lists.openembedded.org/mt/103827980/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 2/3] gnupg: Make the version consistent
From: Mingli Yu The commit [b67e4e523 Improve the beta number generation.] [1] extends the version to make it work well for no release version, but it introduces the version inconsistency. Considering we mainly use a release version in oe, so remove the added suffix to keep consistent. Before the patch: # rpm -qa | grep gnupg gnupg-gpg-2.4.3-r0.core2_64 gnupg-2.4.3-r0.core2_64 # gpgv --version gpgv (GnuPG) 2.4.3-unknown [snip] After the patch: # rpm -qa | grep gnupg gnupg-gpg-2.4.3-r0.core2_64 gnupg-2.4.3-r0.core2_64 # gpgv --version gpgv (GnuPG) 2.4.3 [snip] [1] https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=blobdiff;f=autogen.sh;h=2b0a5dc51a7386ef90ff6c8358d26b9cc65c0c72;hp=471193c2af6a298fdde466950061dd890feb230e;hb=b67e4e523e6d19d384e23c5bb03010caebd150e7;hpb=518d835380a2ae01d6a9cc19de92684baade96a4 Signed-off-by: Mingli Yu --- ...autogen.sh-Remove-the-unknown-suffix.patch | 43 +++ meta/recipes-support/gnupg/gnupg_2.4.3.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-support/gnupg/gnupg/0001-autogen.sh-Remove-the-unknown-suffix.patch diff --git a/meta/recipes-support/gnupg/gnupg/0001-autogen.sh-Remove-the-unknown-suffix.patch b/meta/recipes-support/gnupg/gnupg/0001-autogen.sh-Remove-the-unknown-suffix.patch new file mode 100644 index 00..05614954e0 --- /dev/null +++ b/meta/recipes-support/gnupg/gnupg/0001-autogen.sh-Remove-the-unknown-suffix.patch @@ -0,0 +1,43 @@ +From 7bdc05ad7c2e196344565988dfc0225eeb86ec0a Mon Sep 17 00:00:00 2001 +From: Mingli Yu +Date: Fri, 19 Jan 2024 16:29:06 +0800 +Subject: [PATCH] autogen.sh: Remove the unknown suffix + +The commit [b67e4e523 Improve the beta number generation.] [1] +extends the version to make it work well for no release version +and introduce the below version inconsistency as below: + # rpm -qa | grep gnupg + gnupg-gpg-2.4.3-r0.core2_64 + gnupg-2.4.3-r0.core2_64 + # gpgv --version + gpgv (GnuPG) 2.4.3-unknown + [snip] + +Considering we mainly use a release version in oe, so remove the added +suffix to keep consistent. + +[1] https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=blobdiff;f=autogen.sh;h=2b0a5dc51a7386ef90ff6c8358d26b9cc65c0c72;hp=471193c2af6a298fdde466950061dd890feb230e;hb=b67e4e523e6d19d384e23c5bb03010caebd150e7;hpb=518d835380a2ae01d6a9cc19de92684baade96a4 + +Upstream-Status: Inappropriate [OE-Specific as we use a release version in oe] + +Signed-off-by: Mingli Yu +--- + autogen.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/autogen.sh b/autogen.sh +index 78753b5..fdaa0ad 100755 +--- a/autogen.sh b/autogen.sh +@@ -237,7 +237,7 @@ if [ "$myhost" = "find-version" ]; then + rvd=$((0x$(echo ${rev} | dd bs=1 count=4 2>/dev/null))) + else + ingit=no +- tmp="-unknown" ++ tmp="" + rev="000" + rvd="0" + fi +-- +2.25.1 + diff --git a/meta/recipes-support/gnupg/gnupg_2.4.3.bb b/meta/recipes-support/gnupg/gnupg_2.4.3.bb index e91ef34b7d..f50bb7c391 100644 --- a/meta/recipes-support/gnupg/gnupg_2.4.3.bb +++ b/meta/recipes-support/gnupg/gnupg_2.4.3.bb @@ -19,6 +19,7 @@ SRC_URI = "${GNUPG_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \ file://0004-autogen.sh-fix-find-version-for-beta-checking.patch \ file://0001-Woverride-init-is-not-needed-with-gcc-9.patch \ file://fix-ldap.patch \ + file://0001-autogen.sh-Remove-the-unknown-suffix.patch \ " SRC_URI:append:class-native = " file://0001-configure.ac-use-a-custom-value-for-the-location-of-.patch \ file://relocate.patch" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194030): https://lists.openembedded.org/g/openembedded-core/message/194030 Mute This Topic: https://lists.openembedded.org/mt/103827979/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 1/3] xmlto: Remove the explicit PV setting
From: Mingli Yu The latest release for xmlto is 0.0.28 [1], but the PV is set individually [2] in terms of backport several patches to fix builds with newer compilers after 0.0.28 was releases in 2015. [1] https://releases.pagure.org/xmlto/ [2] https://git.openembedded.org/openembedded-core/commit/?id=27a5000724e4f4df274279bcd801d1dc2830208e Signed-off-by: Mingli Yu --- meta/recipes-devtools/xmlto/xmlto_0.0.28.bb | 2 -- 1 file changed, 2 deletions(-) diff --git a/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb b/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb index d5a0e69849..69f989f5b8 100644 --- a/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb +++ b/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb @@ -11,8 +11,6 @@ UPSTREAM_CHECK_COMMITS = "1" SRC_URI = "git://pagure.io/xmlto.git;protocol=https;branch=master" S = "${WORKDIR}/git" -PV .= "+0.0.29+git" - inherit autotools CLEANBROKEN = "1" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#194029): https://lists.openembedded.org/g/openembedded-core/message/194029 Mute This Topic: https://lists.openembedded.org/mt/103827978/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] gptfdisk: Make the version consistent
From: Mingli Yu The previous change [262aa17e0e popt: update 1.18 -> 1.19] backports a patch [1] for gptfdisk and make the version bump from 1.0.9 to 1.0.9.1 and make the package version inconsistent as below: root@qemux86-64:~# rpm -qa | grep gptfdisk gptfdisk-1.0.9-r0.core2_64 root@qemux86-64:~# rpm -ql gptfdisk /usr /usr/sbin /usr/sbin/cgdisk /usr/sbin/fixparts /usr/sbin/gdisk /usr/sbin/sgdisk root@qemux86-64:~# gdisk --help GPT fdisk (gdisk) version 1.0.9.1 [snip] So update the bumped version part to make the package version consistent. [1] https://sourceforge.net/p/gptfdisk/code/ci/5d5e76d369a412bfb3d2cebb5fc0a7509cef878d Signed-off-by: Mingli Yu --- ...h-of-sgdisk-when-compiled-with-lates.patch | 25 +-- 1 file changed, 6 insertions(+), 19 deletions(-) diff --git a/meta/recipes-devtools/fdisk/gptfdisk/0001-Fix-failure-crash-of-sgdisk-when-compiled-with-lates.patch b/meta/recipes-devtools/fdisk/gptfdisk/0001-Fix-failure-crash-of-sgdisk-when-compiled-with-lates.patch index 218d9d6713..095d00b1e2 100644 --- a/meta/recipes-devtools/fdisk/gptfdisk/0001-Fix-failure-crash-of-sgdisk-when-compiled-with-lates.patch +++ b/meta/recipes-devtools/fdisk/gptfdisk/0001-Fix-failure-crash-of-sgdisk-when-compiled-with-lates.patch @@ -1,4 +1,4 @@ -From 5d5e76d369a412bfb3d2cebb5fc0a7509cef878d Mon Sep 17 00:00:00 2001 +From e7f9c9909c27d6ceed5aa4ca17023a1bc94b620a Mon Sep 17 00:00:00 2001 From: Rod Smith Date: Fri, 15 Apr 2022 18:10:14 -0400 Subject: [PATCH] Fix failure & crash of sgdisk when compiled with latest popt @@ -6,11 +6,11 @@ Subject: [PATCH] Fix failure & crash of sgdisk when compiled with latest popt Upstream-Status: Backport [https://sourceforge.net/p/gptfdisk/code/ci/5d5e76d369a412bfb3d2cebb5fc0a7509cef878d/] Signed-off-by: Alexander Kanavin +Signed-off-by: Mingli Yu --- - NEWS | 8 - gptcl.cc | 2 +- - support.h | 2 +- - 3 files changed, 10 insertions(+), 2 deletions(-) + NEWS | 8 + gptcl.cc | 2 +- + 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index c7add56..9e153fd 100644 @@ -41,19 +41,6 @@ index 34c9421..0d578eb 100644 poptResetContext(poptCon); if (device != NULL) { -diff --git a/support.h b/support.h -index 8ba9ad1..f91f1bc 100644 a/support.h -+++ b/support.h -@@ -8,7 +8,7 @@ - #include - #include - --#define GPTFDISK_VERSION "1.0.9" -+#define GPTFDISK_VERSION "1.0.9.1" - - #if defined (__FreeBSD__) || defined (__FreeBSD_kernel__) || defined (__APPLE__) - // Darwin (Mac OS) & FreeBSD: disk IOCTLs are different, and there is no lseek64 -- -2.30.2 +2.35.5 -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#193397): https://lists.openembedded.org/g/openembedded-core/message/193397 Mute This Topic: https://lists.openembedded.org/mt/103594168/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 v5] openssh: Add PACKAGECONFIG option to customize sshd mode
From: Mingli Yu Add systemd-sshd-socket-mode PACKAGECONFIG option to choose installing sshd.socket and systemd-sshd-service-mode PACKAGECONFIG option to choose installing sshd.service. The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default and user can choose the above two PACKAGECONFIG option to customize the sshd mode. Signed-off-by: Mingli Yu --- .../openssh/openssh_9.5p1.bb | 25 ++- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb index bbb8fb091a..0312d5bd66 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" +SYSTEMD_SERVICE:${PN}-sshd = "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', '', d)} ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', '', d)}" inherit autotools-brokensep ptest pkgconfig DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}" -PACKAGECONFIG ??= "" +# systemd-sshd-socket-mode means installing sshd.socket +# and systemd-sshd-service-mode corresponding to sshd.service +PACKAGECONFIG ??= "systemd-sshd-socket-mode" PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" +PACKAGECONFIG[systemd-sshd-socket-mode] = "" +PACKAGECONFIG[systemd-sshd-service-mode] = "" EXTRA_AUTORECONF += "--exclude=aclocal" @@ -125,15 +129,24 @@ do_install:append () { echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly install -d ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} + install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ + -e 's,@SBINDIR@,${sbindir},g' \ + -e 's,@BINDIR@,${bindir},g' \ + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ +${D}${systemd_system_unitdir}/sshd.socket + fi + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} + fi install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_system_unitdir} sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ -e 's,@SBINDIR@,${sbindir},g' \ -e 's,@BINDIR@,${bindir},g' \ -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ - ${D}${systemd_system_unitdir}/sshd.socket ${D}${systemd_system_unitdir}/*.service + ${D}${systemd_system_unitdir}/*.service sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ ${D}${sysconfdir}/init.d/sshd -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#193194): https://lists.openembedded.org/g/openembedded-core/message/193194 Mute This Topic: https://lists.openembedded.org/mt/103475233/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 v4 2/2] ptest-packagelists.inc: Add python3-license-expression
From: Mingli Yu # ./run-ptest [snip] PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_bad_syntax PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_as_regular_key PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_with_choice PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception_strict_false PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_key PASS: tests/test_license_expression.py::UtilTest::test_build_licensing PASS: tests/test_license_expression.py::UtilTest::test_build_spdx_licensing PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info_vendored PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_duplicated_elements PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_regular PASS: tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle Testsuite summary # TOTAL: 175 # PASS: 175 # SKIP: 0 # XFAIL: 0 # FAIL: 0 # XPASS: 0 Signed-off-by: Mingli Yu --- meta/conf/distro/include/ptest-packagelists.inc | 1 + 1 file changed, 1 insertion(+) diff --git a/meta/conf/distro/include/ptest-packagelists.inc b/meta/conf/distro/include/ptest-packagelists.inc index 7ca23cb4f0..9057c12b09 100644 --- a/meta/conf/distro/include/ptest-packagelists.inc +++ b/meta/conf/distro/include/ptest-packagelists.inc @@ -62,6 +62,7 @@ PTESTS_FAST = "\ python3-hypothesis \ python3-jinja2 \ python3-jsonpointer \ +python3-license-expression \ python3-markupsafe \ python3-more-itertools \ python3-pluggy \ -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192687): https://lists.openembedded.org/g/openembedded-core/message/192687 Mute This Topic: https://lists.openembedded.org/mt/103256617/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 v4 1/2] python3-license-expression: Fix the ptest failure
From: Mingli Yu Fix the below ptest failure: self = def test_skeleton_codestyle(self): """ This test shouldn't run in proliferated repositories. """ setup_cfg = configparser.ConfigParser() setup_cfg.read("setup.cfg") > if setup_cfg["metadata"]["name"] != "skeleton": tests/test_skeleton_codestyle.py:22: self = , key = 'metadata' def _getitem_(self, key): if key != self.default_section and not self.has_section(key): > raise KeyError(key) E KeyError: 'metadata' After the patch: # ./run-ptest [snip] PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_bad_syntax PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_as_regular_key PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_with_choice PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception_strict_false PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_key PASS: tests/test_license_expression.py::UtilTest::test_build_licensing PASS: tests/test_license_expression.py::UtilTest::test_build_spdx_licensing PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info_vendored PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_duplicated_elements PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_regular PASS: tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle Testsuite summary # TOTAL: 175 # PASS: 175 # SKIP: 0 # XFAIL: 0 # FAIL: 0 # XPASS: 0 Signed-off-by: Mingli Yu Changed in v4: Add python3-license-expression to PTESTS_FAST --- .../python/python3-license-expression/run-ptest | 2 +- .../python/python3-license-expression_30.1.1.bb | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/meta/recipes-devtools/python/python3-license-expression/run-ptest b/meta/recipes-devtools/python/python3-license-expression/run-ptest index 5cec711696..8d2017d39c 100644 --- a/meta/recipes-devtools/python/python3-license-expression/run-ptest +++ b/meta/recipes-devtools/python/python3-license-expression/run-ptest @@ -1,3 +1,3 @@ #!/bin/sh -pytest +pytest --automake diff --git a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb index 31fb88d6e5..92ca419e4a 100644 --- a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb +++ b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb @@ -26,6 +26,7 @@ SRC_URI += " \ RDEPENDS:${PN}-ptest += " \ ${PYTHON_PN}-pytest \ + ${PYTHON_PN}-unittest-automake-output \ " do_install_ptest() { @@ -33,4 +34,5 @@ do_install_ptest() { install -d ${D}${PTEST_PATH}/src cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/ cp -rf ${S}/src/* ${D}${PTEST_PATH}/src/ +cp -rf ${S}/setup.cfg ${D}${PTEST_PATH}/ } -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192686): https://lists.openembedded.org/g/openembedded-core/message/192686 Mute This Topic: https://lists.openembedded.org/mt/103256616/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 v3] python3-license-expression: Fix the ptest failure
yes, the python3-license-expression ptest is fast and v4 sent to add python3-license-expression to PTESTS_FAST. Thanks, From: Alexander Kanavin Sent: Monday, December 18, 2023 17:26 To: Yu, Mingli Cc: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] [PATCH v3] python3-license-expression: Fix the ptest failure CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Mon, 18 Dec 2023 at 10:13, Yu, Mingli wrote: > > From: Mingli Yu > > Fix the below ptest failure: > self = > def test_skeleton_codestyle(self): > """ > This test shouldn't run in proliferated repositories. > """ > setup_cfg = configparser.ConfigParser() > setup_cfg.read("setup.cfg") > > if setup_cfg["metadata"]["name"] != "skeleton": > tests/test_skeleton_codestyle.py:22: > self = , key = 'metadata' > def _getitem_(self, key): > if key != self.default_section and not self.has_section(key): > > raise KeyError(key) > E KeyError: 'metadata' I went and checked why this isn't seen on the autobulder - this ptest is actually excluded from testing because it's in PTESTS_PROBLEMS. Please add it to PTESTS_FAST (if it's quick enough), and then it's good. Alex -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192685): https://lists.openembedded.org/g/openembedded-core/message/192685 Mute This Topic: https://lists.openembedded.org/mt/103239607/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 v3] python3-license-expression: Fix the ptest failure
From: Mingli Yu Fix the below ptest failure: self = def test_skeleton_codestyle(self): """ This test shouldn't run in proliferated repositories. """ setup_cfg = configparser.ConfigParser() setup_cfg.read("setup.cfg") > if setup_cfg["metadata"]["name"] != "skeleton": tests/test_skeleton_codestyle.py:22: self = , key = 'metadata' def _getitem_(self, key): if key != self.default_section and not self.has_section(key): > raise KeyError(key) E KeyError: 'metadata' After the patch: # ./run-ptest [snip] PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_bad_syntax PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_as_regular_key PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_with_choice PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception_strict_false PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_key PASS: tests/test_license_expression.py::UtilTest::test_build_licensing PASS: tests/test_license_expression.py::UtilTest::test_build_spdx_licensing PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info_vendored PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_duplicated_elements PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_regular PASS: tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle Testsuite summary # TOTAL: 175 # PASS: 175 # SKIP: 0 # XFAIL: 0 # FAIL: 0 # XPASS: 0 Signed-off-by: Mingli Yu --- .../python/python3-license-expression/run-ptest | 2 +- .../python/python3-license-expression_30.1.1.bb | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/meta/recipes-devtools/python/python3-license-expression/run-ptest b/meta/recipes-devtools/python/python3-license-expression/run-ptest index 5cec711696..8d2017d39c 100644 --- a/meta/recipes-devtools/python/python3-license-expression/run-ptest +++ b/meta/recipes-devtools/python/python3-license-expression/run-ptest @@ -1,3 +1,3 @@ #!/bin/sh -pytest +pytest --automake diff --git a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb index 31fb88d6e5..92ca419e4a 100644 --- a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb +++ b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb @@ -26,6 +26,7 @@ SRC_URI += " \ RDEPENDS:${PN}-ptest += " \ ${PYTHON_PN}-pytest \ + ${PYTHON_PN}-unittest-automake-output \ " do_install_ptest() { @@ -33,4 +34,5 @@ do_install_ptest() { install -d ${D}${PTEST_PATH}/src cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/ cp -rf ${S}/src/* ${D}${PTEST_PATH}/src/ +cp -rf ${S}/setup.cfg ${D}${PTEST_PATH}/ } -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192624): https://lists.openembedded.org/g/openembedded-core/message/192624 Mute This Topic: https://lists.openembedded.org/mt/103239607/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 v2] python3-license-expression: Fix the ptest failure
Hi Alex, Please check the comments inline. On 12/18/23 16:41, Alexander Kanavin wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. Wait. There were two specific review requests, and both remain unanswered. You are just resending the patch, and that is not acceptable. - (from Ross) can we use pytest —automake instead of unreadable sed/awk monster expression? A: Will use pytest --automake in v3. - (from me) is ptest returning a non-zero error code when it fails like the commit says? If it does, why isn't the failure seen when running -c testimage, or in the autobuilder which does that? Yes, the pytest command should return non-zero as below: # ./run-ptest [snip] PASS: tests/test_license_expression.py:CombineExpressionTest.test_combine_expressions_with_duplicated_elements PASS: tests/test_license_expression.py:CombineExpressionTest.test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py:CombineExpressionTest.test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py:CombineExpressionTest.test_combine_expressions_with_regular self = testMethod=test_skeleton_codestyle> def test_skeleton_codestyle(self): """ This test shouldn't run in proliferated repositories. """ setup_cfg = configparser.ConfigParser() setup_cfg.read("setup.cfg") > if setup_cfg["metadata"]["name"] != "skeleton": tests/test_skeleton_codestyle.py:22: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , key = 'metadata' def __getitem__(self, key): if key != self.default_section and not self.has_section(key): > raise KeyError(key) E KeyError: 'metadata' ../../python3.11/configparser.py:979: KeyError FAIL: tests/test_skeleton_codestyle.py:BaseTests.test_skeleton_codestyle Testsuite summary # TOTAL: 175 # PASS: 174 # SKIP: 0 # XFAIL: 0 # FAIL: 1 # XPASS: 0 # ERROR: 0 # echo $? 1 Thanks, Please do check these first, and please do pay attention to what people ask. Alex On Mon, 18 Dec 2023 at 07:15, wrote: From: Mingli Yu Fix the below ptest failure: self = def test_skeleton_codestyle(self): """ This test shouldn't run in proliferated repositories. """ setup_cfg = configparser.ConfigParser() setup_cfg.read("setup.cfg") > if setup_cfg["metadata"]["name"] != "skeleton": tests/test_skeleton_codestyle.py:22: self = , key = 'metadata' def _getitem_(self, key): if key != self.default_section and not self.has_section(key): > raise KeyError(key) E KeyError: 'metadata' After the patch: # ./run-ptest [snip] PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_bad_syntax PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_as_regular_key PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_with_choice PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception_strict_false PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_key PASS: tests/test_license_expression.py::UtilTest::test_build_licensing PASS: tests/test_license_expression.py::UtilTest::test_build_spdx_licensing PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info_vendored PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_duplicated_elements PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_regular PASS: tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle = 175 passed in 10.36s = Signed-off-by: Mingli Yu --- .../python/python3-license-expression/run-ptest | 6 +- .../python/python3-license-expression_30.1.1.bb | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/meta/recipes-devtools/python/python3-license-expression/run-ptest b/meta/recipes-devtools/python/python3-license-expression/run-ptest index 5cec711696..07e2dd17ee 100644 --- a/meta/recipes-devtools/python/python3-license-expression/run-ptest +++
Re: [OE-core] [PATCH] python3-license-expression: Fix the ptest failure
Hi Ross, On 12/14/23 02:05, Ross Burton wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On 13 Dec 2023, at 10:21, Yu, Mingli via lists.openembedded.org wrote: -pytest +pytest -o log_cli=true -o log_cli_level=INFO | sed -e 's/\[...%\]//g'| sed -e 's/PASSED/PASS/g'| sed -e 's/FAILED/FAIL/g'|sed -e 's/SKIPED/SKIP/g'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS"){printf "%s: %s\n", $NF, $0}else{print}}'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS") {$NF="";print $0}else{print}}’ python3-unittest-automake-output has a helper class to do this for you, so you just need to "pytest —automake”. Thanks your suggestion! Will use "pytest —automake" in v3. Thanks, Ross -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192619): https://lists.openembedded.org/g/openembedded-core/message/192619 Mute This Topic: https://lists.openembedded.org/mt/103146950/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 v4] openssh: Add PACKAGECONFIG option to customize sshd mode
Ping. Thanks, On 12/6/23 16:56, Yu, Mingli wrote: From: Mingli Yu Add systemd-sshd-socket-mode PACKAGECONFIG option to choose sshd.socket and systemd-sshd-service-mode PACKAGECONFIG option to choose installing sshd.service. The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default and user can customize the above two PACKAGECONFIG option to choose the sshd mode. Signed-off-by: Mingli Yu --- Changed in v3: rebase based on https://lore.kernel.org/all/20231201140947.792594-1-xiangyu.c...@eng.windriver.com/ Changed in v4: make it possible to install both sshd.socket and sshd.service .../openssh/openssh_9.5p1.bb | 25 ++- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb index 2c1c821ea9..58dd030c64 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" +SYSTEMD_SERVICE:${PN}-sshd = "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', '', d)} ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', '', d)}" inherit autotools-brokensep ptest pkgconfig -PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" +# systemd-sshd-socket-mode means sshd.socket and systemd-sshd-service-mode +# corresponding to sshd.service +PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} systemd-sshd-socket-mode" PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd" +PACKAGECONFIG[systemd-sshd-socket-mode] = "" +PACKAGECONFIG[systemd-sshd-service-mode] = "" EXTRA_AUTORECONF += "--exclude=aclocal" @@ -124,15 +128,24 @@ do_install:append () { echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly install -d ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} + install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ + -e 's,@SBINDIR@,${sbindir},g' \ + -e 's,@BINDIR@,${bindir},g' \ + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ +${D}${systemd_system_unitdir}/sshd.socket + fi + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} + fi install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_system_unitdir} sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ -e 's,@SBINDIR@,${sbindir},g' \ -e 's,@BINDIR@,${bindir},g' \ -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ - ${D}${systemd_system_unitdir}/sshd.socket ${D}${systemd_system_unitdir}/*.service + ${D}${systemd_system_unitdir}/*.service sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ ${D}${sysconfdir}/init.d/sshd -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192604): https://lists.openembedded.org/g/openembedded-core/message/192604 Mute This Topic: https://lists.openembedded.org/mt/103238411/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] python3-license-expression: Fix the ptest failure
From: Mingli Yu Fix the below ptest failure: self = def test_skeleton_codestyle(self): """ This test shouldn't run in proliferated repositories. """ setup_cfg = configparser.ConfigParser() setup_cfg.read("setup.cfg") > if setup_cfg["metadata"]["name"] != "skeleton": tests/test_skeleton_codestyle.py:22: self = , key = 'metadata' def _getitem_(self, key): if key != self.default_section and not self.has_section(key): > raise KeyError(key) E KeyError: 'metadata' After the patch: # ./run-ptest [snip] PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_bad_syntax PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_as_regular_key PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_with_choice PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception_strict_false PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_key PASS: tests/test_license_expression.py::UtilTest::test_build_licensing PASS: tests/test_license_expression.py::UtilTest::test_build_spdx_licensing PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info_vendored PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_duplicated_elements PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_regular PASS: tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle = 175 passed in 10.36s = Signed-off-by: Mingli Yu --- .../python/python3-license-expression/run-ptest | 6 +- .../python/python3-license-expression_30.1.1.bb | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/meta/recipes-devtools/python/python3-license-expression/run-ptest b/meta/recipes-devtools/python/python3-license-expression/run-ptest index 5cec711696..07e2dd17ee 100644 --- a/meta/recipes-devtools/python/python3-license-expression/run-ptest +++ b/meta/recipes-devtools/python/python3-license-expression/run-ptest @@ -1,3 +1,7 @@ #!/bin/sh -pytest +rm -rf output.log +pytest -o log_cli=true -o log_cli_level=INFO > output.log 2>&1 +exitcode=$? +cat output.log | sed -e 's/\[...%\]//g'| sed -e 's/PASSED/PASS/g'| sed -e 's/FAILED/FAIL/g'|sed -e 's/SKIPED/SKIP/g'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS"){printf "%s: %s\n", $NF, $0}else{print}}'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS") {$NF="";print $0}else{print}}' +exit $exitcode diff --git a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb index 31fb88d6e5..5d3923d487 100644 --- a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb +++ b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb @@ -33,4 +33,5 @@ do_install_ptest() { install -d ${D}${PTEST_PATH}/src cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/ cp -rf ${S}/src/* ${D}${PTEST_PATH}/src/ +cp -rf ${S}/setup.cfg ${D}${PTEST_PATH}/ } -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192602): https://lists.openembedded.org/g/openembedded-core/message/192602 Mute This Topic: https://lists.openembedded.org/mt/103238401/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] python3-license-expression: Fix the ptest failure
Hi Alex, The single command is enough to indicate the build failure such as: root@qemux86-64:/usr/lib64/python3-license-expression/ptest# ./run-ptest [snip] PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_regular FAIL: tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle === FAILURES === __ BaseTests.test_skeleton_codestyle ___ self = def test_skeleton_codestyle(self): """ This test shouldn't run in proliferated repositories. """ setup_cfg = configparser.ConfigParser() setup_cfg.read("setup.cfg") > if setup_cfg["metadata"]["name"] != "skeleton": tests/test_skeleton_codestyle.py:22: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , key = 'metadata' def __getitem__(self, key): if key != self.default_section and not self.has_section(key): > raise KeyError(key) E KeyError: 'metadata' ../../python3.11/configparser.py:979: KeyError === short test summary info FAIL tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle 1 failed, 174 passed in 7.08s = Thanks, ________ From: Alexander Kanavin Sent: Thursday, December 14, 2023 00:39 To: Yu, Mingli Cc: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] [PATCH] python3-license-expression: Fix the ptest failure CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. I see that run-ptest consists of a single pytest command; does that command return a zero exit code even it fails? Alex On Wed, 13 Dec 2023 at 17:38, Alexander Kanavin wrote: > > Why isn't the ptest failure reported by the autobuilder? Shouldn't we > first fix the ptest so that the failure is reported correctly, if it > starts occurring again? > > Alex > > On Wed, 13 Dec 2023 at 11:21, Yu, Mingli wrote: > > > > From: Mingli Yu > > > > Fix the below ptest failure: > > self = > testMethod=test_skeleton_codestyle> > > def test_skeleton_codestyle(self): > > """ > > This test shouldn't run in proliferated repositories. > > """ > > setup_cfg = configparser.ConfigParser() > > setup_cfg.read("setup.cfg") > > > if setup_cfg["metadata"]["name"] != "skeleton": > > tests/test_skeleton_codestyle.py:22: > > self = , key = > > 'metadata' > > def _getitem_(self, key): > > if key != self.default_section and not self.has_section(key): > > > raise KeyError(key) > > E KeyError: 'metadata' > > > > After the patch: > > # ./run-ptest > > [snip] > > PASS: > > tests/test_license_expression.py::LicensingValidateTest::test_validation_bad_syntax > > PASS: > > tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_as_regular_key > > PASS: > > tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_with_choice > > PASS: > > tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception > > PASS: > > tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception_strict_false > > PASS: > > tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_key > > PASS: tests/test_license_expression.py::UtilTest::test_build_licensing > > PASS: tests/test_license_expression.py::UtilTest::test_build_spdx_licensing > > PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info > > PASS: > > tests/test_license_expression.py::UtilTest::test_get_license_key_info_vendored > > PASS: > > tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_duplicated_elements > > PASS: > > tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input > > PASS: > > tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship > > PASS: > > tests/test_license_expression.py::CombineExpressionTest::test_combine_expres
[OE-core] [PATCH] python3-license-expression: Fix the ptest failure
From: Mingli Yu Fix the below ptest failure: self = def test_skeleton_codestyle(self): """ This test shouldn't run in proliferated repositories. """ setup_cfg = configparser.ConfigParser() setup_cfg.read("setup.cfg") > if setup_cfg["metadata"]["name"] != "skeleton": tests/test_skeleton_codestyle.py:22: self = , key = 'metadata' def _getitem_(self, key): if key != self.default_section and not self.has_section(key): > raise KeyError(key) E KeyError: 'metadata' After the patch: # ./run-ptest [snip] PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_bad_syntax PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_as_regular_key PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_exception_with_choice PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_exception_strict_false PASS: tests/test_license_expression.py::LicensingValidateTest::test_validation_invalid_license_key PASS: tests/test_license_expression.py::UtilTest::test_build_licensing PASS: tests/test_license_expression.py::UtilTest::test_build_spdx_licensing PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info PASS: tests/test_license_expression.py::UtilTest::test_get_license_key_info_vendored PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_duplicated_elements PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_empty_input PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_or_relationship PASS: tests/test_license_expression.py::CombineExpressionTest::test_combine_expressions_with_regular PASS: tests/test_skeleton_codestyle.py::BaseTests::test_skeleton_codestyle = 175 passed in 10.36s = Signed-off-by: Mingli Yu --- .../python/python3-license-expression/run-ptest | 2 +- .../python/python3-license-expression_30.1.1.bb | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/meta/recipes-devtools/python/python3-license-expression/run-ptest b/meta/recipes-devtools/python/python3-license-expression/run-ptest index 5cec711696..3385d68939 100644 --- a/meta/recipes-devtools/python/python3-license-expression/run-ptest +++ b/meta/recipes-devtools/python/python3-license-expression/run-ptest @@ -1,3 +1,3 @@ #!/bin/sh -pytest +pytest -o log_cli=true -o log_cli_level=INFO | sed -e 's/\[...%\]//g'| sed -e 's/PASSED/PASS/g'| sed -e 's/FAILED/FAIL/g'|sed -e 's/SKIPED/SKIP/g'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS"){printf "%s: %s\n", $NF, $0}else{print}}'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS") {$NF="";print $0}else{print}}' diff --git a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb index 31fb88d6e5..5d3923d487 100644 --- a/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb +++ b/meta/recipes-devtools/python/python3-license-expression_30.1.1.bb @@ -33,4 +33,5 @@ do_install_ptest() { install -d ${D}${PTEST_PATH}/src cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/ cp -rf ${S}/src/* ${D}${PTEST_PATH}/src/ +cp -rf ${S}/setup.cfg ${D}${PTEST_PATH}/ } -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#192278): https://lists.openembedded.org/g/openembedded-core/message/192278 Mute This Topic: https://lists.openembedded.org/mt/103146950/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 v4] openssh: Add PACKAGECONFIG option to customize sshd mode
Hi Alex, The SYSTEMD_SERVICE variable is used to control per-service preset now and we use PACKAGECONFIG to help define the variable for SYSTEMD_SERVICE as below. SYSTEMD_PACKAGES = "${PN}-sshd" SYSTEMD_SERVICE:${PN}-sshd = "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', '', d)} ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', '', d)}" Thanks, From: Alex Kiernan Sent: Thursday, December 7, 2023 20:11 To: Yu, Mingli Cc: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] [PATCH v4] openssh: Add PACKAGECONFIG option to customize sshd mode CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Thu, Dec 7, 2023 at 2:10 AM Yu, Mingli wrote: > > Hi Alex, > > Thanks for your suggestion! > > Both sshd.socket and sshd.service belong to openssh-sshd package, so using > SYSTEMD_AUTO_ENABLE can't enable one of them, it just can enable both or > disable both. > Yes, it would need changes to support per-service presets, which I suspect would be generally useful. > Thanks, > > From: Alex Kiernan > Sent: Wednesday, December 6, 2023 18:37 > To: Yu, Mingli > Cc: openembedded-core@lists.openembedded.org > > Subject: Re: [OE-core] [PATCH v4] openssh: Add PACKAGECONFIG option to > customize sshd mode > > CAUTION: This email comes from a non Wind River email account! > Do not click links or open attachments unless you recognize the sender and > know the content is safe. > > On Wed, Dec 6, 2023 at 8:56 AM Yu, Mingli wrote: > > > > From: Mingli Yu > > > > Add systemd-sshd-socket-mode PACKAGECONFIG option to choose sshd.socket > > and systemd-sshd-service-mode PACKAGECONFIG option to choose installing > > sshd.service. > > > > The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default > > and user can customize the above two PACKAGECONFIG option to choose the > > sshd mode. > > > > Signed-off-by: Mingli Yu > > --- > > Changed in v3: > > rebase based on > > https://lore.kernel.org/all/20231201140947.792594-1-xiangyu.c...@eng.windriver.com/ > > > > Changed in v4: > > make it possible to install both sshd.socket and sshd.service > > I'm wondering if we should make SYSTEMD_AUTO_ENABLE settable per > service, so you could then install both and manage which one is active > with a preset. > > > .../openssh/openssh_9.5p1.bb | 25 ++- > > 1 file changed, 19 insertions(+), 6 deletions(-) > > > > diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > > b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > > index 2c1c821ea9..58dd030c64 100644 > > --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > > +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > > @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" > > INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" > > > > SYSTEMD_PACKAGES = "${PN}-sshd" > > -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" > > +SYSTEMD_SERVICE:${PN}-sshd = > > "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', > > '', d)} > > ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', > > '', d)}" > > > > inherit autotools-brokensep ptest pkgconfig > > > > -PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" > > +# systemd-sshd-socket-mode means sshd.socket and systemd-sshd-service-mode > > +# corresponding to sshd.service > > +PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} > > systemd-sshd-socket-mode" > > PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" > > PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" > > PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" > > PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" > > PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd" > > +PACKAGECONFIG[systemd-sshd-socket-mode] = "" > > +PACKAGECONFIG[systemd-sshd-service-mode] = "" > > > > EXTRA_AUTORECONF += "--exclude=aclocal" > > > > @@ -124,15 +128,24 @@ do_install:append () { > > echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> > > ${D}${sysconfdir}/ssh/ss
Re: [OE-core] [PATCH v4] openssh: Add PACKAGECONFIG option to customize sshd mode
Hi Alex, Thanks for your suggestion! Both sshd.socket and sshd.service belong to openssh-sshd package, so using SYSTEMD_AUTO_ENABLE can't enable one of them, it just can enable both or disable both. Thanks, From: Alex Kiernan Sent: Wednesday, December 6, 2023 18:37 To: Yu, Mingli Cc: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] [PATCH v4] openssh: Add PACKAGECONFIG option to customize sshd mode CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Wed, Dec 6, 2023 at 8:56 AM Yu, Mingli wrote: > > From: Mingli Yu > > Add systemd-sshd-socket-mode PACKAGECONFIG option to choose sshd.socket > and systemd-sshd-service-mode PACKAGECONFIG option to choose installing > sshd.service. > > The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default > and user can customize the above two PACKAGECONFIG option to choose the > sshd mode. > > Signed-off-by: Mingli Yu > --- > Changed in v3: > rebase based on > https://lore.kernel.org/all/20231201140947.792594-1-xiangyu.c...@eng.windriver.com/ > > Changed in v4: > make it possible to install both sshd.socket and sshd.service I'm wondering if we should make SYSTEMD_AUTO_ENABLE settable per service, so you could then install both and manage which one is active with a preset. > .../openssh/openssh_9.5p1.bb | 25 ++- > 1 file changed, 19 insertions(+), 6 deletions(-) > > diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > index 2c1c821ea9..58dd030c64 100644 > --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" > INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" > > SYSTEMD_PACKAGES = "${PN}-sshd" > -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" > +SYSTEMD_SERVICE:${PN}-sshd = > "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', > '', d)} > ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', > '', d)}" > > inherit autotools-brokensep ptest pkgconfig > > -PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" > +# systemd-sshd-socket-mode means sshd.socket and systemd-sshd-service-mode > +# corresponding to sshd.service > +PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} > systemd-sshd-socket-mode" > PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" > PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" > PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" > PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" > PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd" > +PACKAGECONFIG[systemd-sshd-socket-mode] = "" > +PACKAGECONFIG[systemd-sshd-service-mode] = "" > > EXTRA_AUTORECONF += "--exclude=aclocal" > > @@ -124,15 +128,24 @@ do_install:append () { > echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> > ${D}${sysconfdir}/ssh/sshd_config_readonly > > install -d ${D}${systemd_system_unitdir} > - install -c -m 0644 ${WORKDIR}/sshd.socket > ${D}${systemd_system_unitdir} > - install -c -m 0644 ${WORKDIR}/sshd.service > ${D}${systemd_system_unitdir} > - install -c -m 0644 ${WORKDIR}/sshd@.service > ${D}${systemd_system_unitdir} > + if > ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','true','false',d)}; > then > + install -c -m 0644 ${WORKDIR}/sshd.socket > ${D}${systemd_system_unitdir} > + install -c -m 0644 ${WORKDIR}/sshd@.service > ${D}${systemd_system_unitdir} > + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ > + -e 's,@SBINDIR@,${sbindir},g' \ > + -e 's,@BINDIR@,${bindir},g' \ > + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ > +${D}${systemd_system_unitdir}/sshd.socket > + fi > + if > ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','true','false',d)}; > then > + install -c -m 0644 ${WORKDIR}/sshd.service > ${D}${systemd_system_unitdir} > + fi > install -c -m 0644 ${WORKDIR}/sshdgenkeys.service > ${D}${systemd_system_unitdir} > sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ > -e 's,@SBINDIR@,${sbind
Re: [OE-core] [PATCH v2] openssh: Add PACKAGECONFIG option to customize sshd mode
Hi Peter, Thanks very much for your comments! Please use v4([OE-core] [PATCH v4] openssh: Add PACKAGECONFIG option to customize sshd mode) to track the series. Thanks, From: Peter Kjellerstedt Sent: Thursday, December 7, 2023 06:34 To: Yu, Mingli ; openembedded-core@lists.openembedded.org Subject: RE: [OE-core] [PATCH v2] openssh: Add PACKAGECONFIG option to customize sshd mode CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. > -Original Message- > From: openembedded-core@lists.openembedded.org > On Behalf Of Yu, Mingli > Sent: den 5 december 2023 06:52 > To: openembedded-core@lists.openembedded.org > Subject: [OE-core] [PATCH v2] openssh: Add PACKAGECONFIG option to customize > sshd mode > > From: Mingli Yu > > Add systemd-sshd-socket-mode PACKAGECONFIG option to choose sshd.socket > and systemd-sshd-service-mode PACKAGECONFIG option to choose installing > sshd.service. > > The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default > and user can customize the above two PACKAGECONFIG option to choose the > sshd mode. > > Signed-off-by: Mingli Yu > --- > .../openssh/openssh_9.5p1.bb | 24 ++- > 1 file changed, 18 insertions(+), 6 deletions(-) > > diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > index bbb8fb091a..a10f5c5a61 100644 > --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb > @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" > INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" > > SYSTEMD_PACKAGES = "${PN}-sshd" > -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" > +SYSTEMD_SERVICE:${PN}-sshd = > "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', > '', d)} > ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', > '', d)}" > > inherit autotools-brokensep ptest pkgconfig > DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', > '', d)}" > > -PACKAGECONFIG ??= "" > +# systemd-sshd-socket-mode means sshd.socket and systemd-sshd-service-mode > +# corresponding to sshd.service > +PACKAGECONFIG ??= " systemd-sshd-socket-mode" Unnecessary leading space after the first quote. > PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" > PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" > PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" > PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" > +PACKAGECONFIG[systemd-sshd-socket-mode] = "" > +PACKAGECONFIG[systemd-sshd-service-mode] = "" > > EXTRA_AUTORECONF += "--exclude=aclocal" > > @@ -125,15 +129,23 @@ do_install:append () { > echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> > ${D}${sysconfdir}/ssh/sshd_config_readonly > > install -d ${D}${systemd_system_unitdir} > - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} > - install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} > - install -c -m 0644 ${WORKDIR}/sshd@.service > ${D}${systemd_system_unitdir} > + if > ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','true','false',d)}; > then > + install -c -m 0644 ${WORKDIR}/sshd.socket > ${D}${systemd_system_unitdir} > + install -c -m 0644 ${WORKDIR}/sshd@.service > ${D}${systemd_system_unitdir} > + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ > + -e 's,@SBINDIR@,${sbindir},g' \ > + -e 's,@BINDIR@,${bindir},g' \ > + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ > +${D}${systemd_system_unitdir}/sshd.socket There is no need to duplicate the sed command here. The original command below would take care of all the files that are actually installed. > + elif > ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','true','false',d)}; > then Are the PACKAGECONFIGs mutually exclusive? The `elif` indicates that this is the case. If so, they should be marked as mutually exclusive by changing them to: PACKAGECONFIG[systemd-sshd-socket-mode] = ", systemd-sshd-service-mode" PACKAGECONFIG[systemd-sshd-service-mode] = ", systemd-sshd-socket-mode" Alternatively, if it is useful to be able to install both the sshd.socket file and the sshd.service file at the
[OE-core] [PATCH v4] openssh: Add PACKAGECONFIG option to customize sshd mode
From: Mingli Yu Add systemd-sshd-socket-mode PACKAGECONFIG option to choose sshd.socket and systemd-sshd-service-mode PACKAGECONFIG option to choose installing sshd.service. The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default and user can customize the above two PACKAGECONFIG option to choose the sshd mode. Signed-off-by: Mingli Yu --- Changed in v3: rebase based on https://lore.kernel.org/all/20231201140947.792594-1-xiangyu.c...@eng.windriver.com/ Changed in v4: make it possible to install both sshd.socket and sshd.service .../openssh/openssh_9.5p1.bb | 25 ++- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb index 2c1c821ea9..58dd030c64 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" +SYSTEMD_SERVICE:${PN}-sshd = "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', '', d)} ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', '', d)}" inherit autotools-brokensep ptest pkgconfig -PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" +# systemd-sshd-socket-mode means sshd.socket and systemd-sshd-service-mode +# corresponding to sshd.service +PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} systemd-sshd-socket-mode" PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd" +PACKAGECONFIG[systemd-sshd-socket-mode] = "" +PACKAGECONFIG[systemd-sshd-service-mode] = "" EXTRA_AUTORECONF += "--exclude=aclocal" @@ -124,15 +128,24 @@ do_install:append () { echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly install -d ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} + install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ + -e 's,@SBINDIR@,${sbindir},g' \ + -e 's,@BINDIR@,${bindir},g' \ + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ +${D}${systemd_system_unitdir}/sshd.socket + fi + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} + fi install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_system_unitdir} sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ -e 's,@SBINDIR@,${sbindir},g' \ -e 's,@BINDIR@,${bindir},g' \ -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ - ${D}${systemd_system_unitdir}/sshd.socket ${D}${systemd_system_unitdir}/*.service + ${D}${systemd_system_unitdir}/*.service sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ ${D}${sysconfdir}/init.d/sshd -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#191874): https://lists.openembedded.org/g/openembedded-core/message/191874 Mute This Topic: https://lists.openembedded.org/mt/103009646/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 v3] openssh: Add PACKAGECONFIG option to customize sshd mode
From: Mingli Yu Add systemd-sshd-socket-mode PACKAGECONFIG option to choose sshd.socket and systemd-sshd-service-mode PACKAGECONFIG option to choose installing sshd.service. The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default and user can customize the above two PACKAGECONFIG option to choose the sshd mode. Signed-off-by: Mingli Yu --- .../openssh/openssh_9.5p1.bb | 24 ++- 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb index 2c1c821ea9..8273cc0f64 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" +SYSTEMD_SERVICE:${PN}-sshd = "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', '', d)} ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', '', d)}" inherit autotools-brokensep ptest pkgconfig -PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" +# systemd-sshd-socket-mode means sshd.socket and systemd-sshd-service-mode +# corresponding to sshd.service +PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} systemd-sshd-socket-mode" PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd" +PACKAGECONFIG[systemd-sshd-socket-mode] = "" +PACKAGECONFIG[systemd-sshd-service-mode] = "" EXTRA_AUTORECONF += "--exclude=aclocal" @@ -124,15 +128,23 @@ do_install:append () { echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly install -d ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} + install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ + -e 's,@SBINDIR@,${sbindir},g' \ + -e 's,@BINDIR@,${bindir},g' \ + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ +${D}${systemd_system_unitdir}/sshd.socket + elif ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} + fi install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_system_unitdir} sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ -e 's,@SBINDIR@,${sbindir},g' \ -e 's,@BINDIR@,${bindir},g' \ -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ - ${D}${systemd_system_unitdir}/sshd.socket ${D}${systemd_system_unitdir}/*.service + ${D}${systemd_system_unitdir}/*.service sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ ${D}${sysconfdir}/init.d/sshd -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#191869): https://lists.openembedded.org/g/openembedded-core/message/191869 Mute This Topic: https://lists.openembedded.org/mt/103008224/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] openssh: Add PACKAGECONFIG option to customize sshd mode
From: Mingli Yu Add systemd-sshd-socket-mode PACKAGECONFIG option to choose sshd.socket and systemd-sshd-service-mode PACKAGECONFIG option to choose installing sshd.service. The systemd-sshd-socket-mode PACKAGECONFIG option is enabled by default and user can customize the above two PACKAGECONFIG option to choose the sshd mode. Signed-off-by: Mingli Yu --- .../openssh/openssh_9.5p1.bb | 24 ++- 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb index bbb8fb091a..a10f5c5a61 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb @@ -50,16 +50,20 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" +SYSTEMD_SERVICE:${PN}-sshd = "${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','sshd.socket', '', d)} ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','sshd.service', '', d)}" inherit autotools-brokensep ptest pkgconfig DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}" -PACKAGECONFIG ??= "" +# systemd-sshd-socket-mode means sshd.socket and systemd-sshd-service-mode +# corresponding to sshd.service +PACKAGECONFIG ??= " systemd-sshd-socket-mode" PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" +PACKAGECONFIG[systemd-sshd-socket-mode] = "" +PACKAGECONFIG[systemd-sshd-service-mode] = "" EXTRA_AUTORECONF += "--exclude=aclocal" @@ -125,15 +129,23 @@ do_install:append () { echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly install -d ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + if ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-socket-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} + install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ + -e 's,@SBINDIR@,${sbindir},g' \ + -e 's,@BINDIR@,${bindir},g' \ + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ +${D}${systemd_system_unitdir}/sshd.socket + elif ${@bb.utils.contains('PACKAGECONFIG','systemd-sshd-service-mode','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} + fi install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_system_unitdir} sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ -e 's,@SBINDIR@,${sbindir},g' \ -e 's,@BINDIR@,${bindir},g' \ -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ - ${D}${systemd_system_unitdir}/sshd.socket ${D}${systemd_system_unitdir}/*.service + ${D}${systemd_system_unitdir}/*.service sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ ${D}${sysconfdir}/init.d/sshd -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#191794): https://lists.openembedded.org/g/openembedded-core/message/191794 Mute This Topic: https://lists.openembedded.org/mt/102987153/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] openssh: Add SSHD_SERVICE_TYPE variable
Hi Richard, On 12/4/23 19:07, Richard Purdie wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Mon, 2023-12-04 at 16:54 +0800, Yu, Mingli wrote: From: Mingli Yu There are two types of sshd server now, one is based on socket activation(sshd.socket) and another is service activation(sshd.service). And the default sshd service type is based on socket by default as below. Firstly, I'm a little frustrated about how these changes are being proposed in pieces. The original patches made no mention that this was eventually going to be controlled by a new variable. I did wonder if something like this was going to happen but the didn't push back. Now we're "pinned" into a corner with the direction this code takes now we've already merged the on target configuration change. But it's more convenient to determine the service type at build time if there are so many devices. Why did we merge a patch which made this an on target decision then? Maybe usage requirement change? sorry for noise! So add SSHD_SERVICE_TYPE variable to enable sshd.socket or sshd.service at build time and we still enable sshd.socket by default now. No, we're not adding randomly named variables which take magic options. I cannot look at SSHD_SERVICE_TYPE and know that "1" means socket activation and not setting it means service activation (or whatever, the fact I can't check what I've written easily proves my point). What happens if I set it to "true", or "socket", or "apples"? I'd suggest thinking about a PACKAGECONFIG option such as systemd-sshd- socket-mode and systemd-sshd-service-mode which at least uses naming users are mode used to and says what it does. Will sent v2 to use the common PACKAGECONFIG option to control the sshd type. Thanks, Cheers, Richard -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#191776): https://lists.openembedded.org/g/openembedded-core/message/191776 Mute This Topic: https://lists.openembedded.org/mt/102967209/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] openssh: Add SSHD_SERVICE_TYPE variable
From: Mingli Yu There are two types of sshd server now, one is based on socket activation(sshd.socket) and another is service activation(sshd.service). And the default sshd service type is based on socket by default as below. # systemctl status sshd.socket * sshd.socket Loaded: loaded (/lib/systemd/system/sshd.socket; enabled; preset: enabled) Active: active (listening) since Mon 2023-12-04 08:34:33 UTC; 22s ago Listen: [::]:22 (Stream) Accepted: 0; Connected: 0; Process: 228 ExecStartPre=/bin/mkdir -p /var/run/sshd (code=exited, status=0/SUCCESS) Tasks: 0 (limit: 263) Memory: 84.0K CGroup: /system.slice/sshd.socket Dec 04 08:34:33 qemux86-64 systemd[1]: Starting sshd.socket... Dec 04 08:34:33 qemux86-64 systemd[1]: Listening on sshd.socket. And use can switch to service activation if they want as below after the device boot up. # systemctl disable sshd.socket Removed "/etc/systemd/system/sockets.target.wants/sshd.socket". # systemctl stop sshd.socket # systemctl start sshd.service # systemctl status sshd.service * sshd.service - OpenSSH server daemon Loaded: loaded (/lib/systemd/system/sshd.service; enabled; preset: enabled) Active: active (running) since Mon 2023-12-04 08:48:14 UTC; 53s ago Process: 390 ExecStartPre=/bin/mkdir -p /var/run/sshd (code=exited, status=0/SUCCESS) Main PID: 391 (sshd) Tasks: 1 (limit: 263) Memory: 2.1M CGroup: /system.slice/sshd.service `-391 "sshd: /usr/sbin/sshd -D [listener] 0 of 10-100 startups" Dec 04 08:48:14 qemux86-64 systemd[1]: Starting OpenSSH server daemon... Dec 04 08:48:14 qemux86-64 systemd[1]: Started OpenSSH server daemon. Dec 04 08:48:14 qemux86-64 sshd[391]: Server listening on 0.0.0.0 port 22. Dec 04 08:48:14 qemux86-64 sshd[391]: Server listening on :: port 22. But it's more convenient to determine the service type at build time if there are so many devices. So add SSHD_SERVICE_TYPE variable to enable sshd.socket or sshd.service at build time and we still enable sshd.socket by default now. Signed-off-by: Mingli Yu --- .../openssh/openssh_9.5p1.bb | 18 +- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb index bbb8fb091a..6a603cd12d 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.5p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.5p1.bb @@ -50,7 +50,7 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" +SYSTEMD_SERVICE:${PN}-sshd = "${@bb.utils.contains('SSHD_SERVICE_TYPE', '1', 'sshd.service', 'sshd.socket', d)}" inherit autotools-brokensep ptest pkgconfig DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}" @@ -125,15 +125,23 @@ do_install:append () { echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly install -d ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} - install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + if ${@bb.utils.contains('SSHD_SERVICE_TYPE','1','true','false',d)}; then + install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} + else + install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} + install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} + sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ + -e 's,@SBINDIR@,${sbindir},g' \ + -e 's,@BINDIR@,${bindir},g' \ + -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ +${D}${systemd_system_unitdir}/sshd.socket + fi install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_system_unitdir} sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ -e 's,@SBINDIR@,${sbindir},g' \ -e 's,@BINDIR@,${bindir},g' \ -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ - ${D}${systemd_system_unitdir}/sshd.socket ${D}${systemd_system_unitdir}/*.service + ${D}${systemd_system_unitdir}/*.service sed -i -e 's,@LIBEXECDIR@,${libexecdir}/${BPN},g' \ ${D}${sysconfdir}/init.d/sshd -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#191727): https://lists.openembedded.org/g/openembedded-core/message/191727 Mute This Topic:
[OE-core] [mickledore][PATCH] curl: Fix CVE-2023-38039
From: Mingli Yu Backport patch [1] to fix CVE-2023-38039 and reference [2] and [3] to fix the build error. [1] https://github.com/curl/curl/commit/3ee79c1674fd6f9 [2] https://github.com/curl/curl/commit/2cb0d346aaa [3] https://github.com/curl/curl/commit/83319e027179 Signed-off-by: Mingli Yu --- .../curl/curl/CVE-2023-38039.patch| 209 ++ meta/recipes-support/curl/curl_8.0.1.bb | 1 + 2 files changed, 210 insertions(+) create mode 100644 meta/recipes-support/curl/curl/CVE-2023-38039.patch diff --git a/meta/recipes-support/curl/curl/CVE-2023-38039.patch b/meta/recipes-support/curl/curl/CVE-2023-38039.patch new file mode 100644 index 00..ef8b600413 --- /dev/null +++ b/meta/recipes-support/curl/curl/CVE-2023-38039.patch @@ -0,0 +1,209 @@ +From daa73dbfa9d4dbaf5415cc14dcbf31e45ed77468 Mon Sep 17 00:00:00 2001 +From: Daniel Stenberg +Date: Thu, 2 Nov 2023 15:57:39 +0800 +Subject: [PATCH] http: return error when receiving too large header set + +To avoid abuse. The limit is set to 300 KB for the accumulated size of +all received HTTP headers for a single response. Incomplete research +suggests that Chrome uses a 256-300 KB limit, while Firefox allows up to +1MB. + +Closes #11582 + +CVE: CVE-2023-38039 + +Upstream-Status: Backport [https://github.com/curl/curl/commit/3ee79c1674fd6f9] + +Signed-off-by: Mingli Yu +--- + lib/c-hyper.c | 12 +++- + lib/http.c | 39 +++ + lib/http.h | 9 + + lib/pingpong.c | 2 +- + lib/urldata.h | 18 ++ + 5 files changed, 62 insertions(+), 18 deletions(-) + +diff --git a/lib/c-hyper.c b/lib/c-hyper.c +index 9c7632d..28f64ef 100644 +--- a/lib/c-hyper.c b/lib/c-hyper.c +@@ -174,8 +174,11 @@ static int hyper_each_header(void *userdata, + } + } + +- data->info.header_size += (curl_off_t)len; +- data->req.headerbytecount += (curl_off_t)len; ++ result = Curl_bump_headersize(data, len, FALSE); ++ if(result) { ++data->state.hresult = result; ++return HYPER_ITER_BREAK; ++ } + return HYPER_ITER_CONTINUE; + } + +@@ -305,9 +308,8 @@ static CURLcode status_line(struct Curl_easy *data, + if(result) + return result; + } +- data->info.header_size += (curl_off_t)len; +- data->req.headerbytecount += (curl_off_t)len; +- return CURLE_OK; ++ result = Curl_bump_headersize(data, len, FALSE); ++ return result; + } + + /* +diff --git a/lib/http.c b/lib/http.c +index 400d2b0..d3efd60 100644 +--- a/lib/http.c b/lib/http.c +@@ -3760,6 +3760,34 @@ static CURLcode verify_header(struct Curl_easy *data) + return CURLE_OK; + } + ++CURLcode Curl_bump_headersize(struct Curl_easy *data, ++ size_t delta, ++ bool connect_only) ++{ ++ size_t bad = 0; ++ unsigned int max = MAX_HTTP_RESP_HEADER_SIZE; ++ if(delta < MAX_HTTP_RESP_HEADER_SIZE) { ++data->info.header_size += (unsigned int)delta; ++data->req.allheadercount += (unsigned int)delta; ++if(!connect_only) ++ data->req.headerbytecount += (unsigned int)delta; ++if(data->req.allheadercount > max) ++ bad = data->req.allheadercount; ++else if(data->info.header_size > (max * 20)) { ++ bad = data->info.header_size; ++ max *= 20; ++} ++ } ++ else ++bad = data->req.allheadercount + delta; ++ if(bad) { ++failf(data, "Too large response headers: %zu > %u", bad, max); ++return CURLE_RECV_ERROR; ++ } ++ return CURLE_OK; ++} ++ ++ + /* + * Read any HTTP header lines from the server and pass them to the client app. + */ +@@ -4007,8 +4035,9 @@ CURLcode Curl_http_readwrite_headers(struct Curl_easy *data, + if(result) + return result; + +- data->info.header_size += (long)headerlen; +- data->req.headerbytecount += (long)headerlen; ++ result = Curl_bump_headersize(data, headerlen, FALSE); ++ if(result) ++return result; + + /* +* When all the headers have been parsed, see if we should give +@@ -4330,8 +4359,10 @@ CURLcode Curl_http_readwrite_headers(struct Curl_easy *data, + if(result) + return result; + +-data->info.header_size += Curl_dyn_len(>state.headerb); +-data->req.headerbytecount += Curl_dyn_len(>state.headerb); ++result = Curl_bump_headersize(data, Curl_dyn_len(>state.headerb), ++ FALSE); ++if(result) ++ return result; + + Curl_dyn_reset(>state.headerb); + } +diff --git a/lib/http.h b/lib/http.h +index 444abc0..ea3b37e 100644 +--- a/lib/http.h b/lib/http.h +@@ -60,6 +60,10 @@ extern const struct Curl_handler Curl_handler_wss; + #endif + #endif /* websockets */ + ++CURLcode Curl_bump_headersize(struct Curl_easy *data, ++ size_t delta, ++ bool connect_only); ++ + + /* Header specific functions */ + bool Curl_compareheader(const char *headerline, /* line to check */ +@@ -176,6 +180,11
[OE-core] [PATCH] openssh: Don't hardcode the dir in sshd.service
From: Mingli Yu Don't hardcode the directory of the binary in sshd.service. Signed-off-by: Mingli Yu --- meta/recipes-connectivity/openssh/openssh/sshd.service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-connectivity/openssh/openssh/sshd.service b/meta/recipes-connectivity/openssh/openssh/sshd.service index 6ace67d8ae..2a997b656a 100644 --- a/meta/recipes-connectivity/openssh/openssh/sshd.service +++ b/meta/recipes-connectivity/openssh/openssh/sshd.service @@ -6,7 +6,7 @@ After=sshdgenkeys.service [Service] Environment="SSHD_OPTS=" EnvironmentFile=-/etc/default/ssh -ExecStartPre=/usr/bin/mkdir -p /var/run/sshd +ExecStartPre=@BASE_BINDIR@/mkdir -p /var/run/sshd ExecStart=-@SBINDIR@/sshd -D $SSHD_OPTS ExecReload=@BASE_BINDIR@/kill -HUP $MAINPID KillMode=process -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#189699): https://lists.openembedded.org/g/openembedded-core/message/189699 Mute This Topic: https://lists.openembedded.org/mt/102195446/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] openssh: Add sshd.service
From: Mingli Yu For systems with a large amount of SSH traffic, it shoule be better to run a single SSH server for all incoming connections. And both sshd.socket and sshd.service are deployed on other distros like ubuntu, fedora and etc. So add sshd.service to make it possible to run a standalone SSH server. Signed-off-by: Mingli Yu --- .../openssh/openssh/sshd.service| 17 + .../openssh/openssh_9.4p1.bb| 4 +++- 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-connectivity/openssh/openssh/sshd.service diff --git a/meta/recipes-connectivity/openssh/openssh/sshd.service b/meta/recipes-connectivity/openssh/openssh/sshd.service new file mode 100644 index 00..6ace67d8ae --- /dev/null +++ b/meta/recipes-connectivity/openssh/openssh/sshd.service @@ -0,0 +1,17 @@ +[Unit] +Description=OpenSSH server daemon +Wants=sshdgenkeys.service +After=sshdgenkeys.service + +[Service] +Environment="SSHD_OPTS=" +EnvironmentFile=-/etc/default/ssh +ExecStartPre=/usr/bin/mkdir -p /var/run/sshd +ExecStart=-@SBINDIR@/sshd -D $SSHD_OPTS +ExecReload=@BASE_BINDIR@/kill -HUP $MAINPID +KillMode=process +Restart=on-failure +RestartSec=42s + +[Install] +WantedBy=multi-user.target diff --git a/meta/recipes-connectivity/openssh/openssh_9.4p1.bb b/meta/recipes-connectivity/openssh/openssh_9.4p1.bb index e2508aa63a..3ef83a2219 100644 --- a/meta/recipes-connectivity/openssh/openssh_9.4p1.bb +++ b/meta/recipes-connectivity/openssh/openssh_9.4p1.bb @@ -16,6 +16,7 @@ SRC_URI = "http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-${PV}.tar file://ssh_config \ file://init \ ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \ + file://sshd.service \ file://sshd.socket \ file://sshd@.service \ file://sshdgenkeys.service \ @@ -48,7 +49,7 @@ INITSCRIPT_NAME:${PN}-sshd = "sshd" INITSCRIPT_PARAMS:${PN}-sshd = "defaults 9" SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket" +SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket sshd.service" inherit autotools-brokensep ptest @@ -122,6 +123,7 @@ do_install:append () { install -d ${D}${systemd_system_unitdir} install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_system_unitdir} + install -c -m 0644 ${WORKDIR}/sshd.service ${D}${systemd_system_unitdir} install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_system_unitdir} install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_system_unitdir} sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#188983): https://lists.openembedded.org/g/openembedded-core/message/188983 Mute This Topic: https://lists.openembedded.org/mt/101913305/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] multilib.conf: Remove the incorrect PKG_CONFIG_PATH setting
Hi Richard, On 9/20/23 18:41, Richard Purdie wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Wed, 2023-09-20 at 17:06 +0800, Yu, Mingli wrote: From: Mingli Yu The PKG_CONFIG_PATH is set as ${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig in multilib.conf. But there is no ${WORKDIR}/recipe-sysroot when multilib enabled such as below: $ bitbake lib32-php There is no ${WORKDIR}/recipe-sysroot and only ${WORKDIR}/lib32-recipe-sysroot exists which already covered in meta/conf/bitbake.conf as below: export PKG_CONFIG_PATH = "${PKG_CONFIG_DIR}:${STAGING_DATADIR}/pkgconfig" So remove the incorrect setting in multilib.conf. Signed-off-by: Mingli Yu --- meta/conf/multilib.conf | 9 - 1 file changed, 9 deletions(-) diff --git a/meta/conf/multilib.conf b/meta/conf/multilib.conf index ef3605a73d..09546315b8 100644 --- a/meta/conf/multilib.conf +++ b/meta/conf/multilib.conf @@ -22,15 +22,6 @@ MULTILIB_GLOBAL_VARIANTS ?= "lib32 lib64 libx32" OPKG_ARGS:append = " --force-maintainer --force-overwrite" -# When multilib is enabled, allarch recipes will be installed into the MACHINE -# sysroot, not MLPREFIXMACHINE. This means that anything using pkg-config to -# find an allarch pkgconfig file will fail as the PKG_CONFIG_PATH only looks -# inside the multilib sysroot. Fix this by explicitly adding the MACHINE's -# architecture-independent pkgconfig location to PKG_CONFIG_PATH. -PKG_CONFIG_PATH .= ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig" -PKG_CONFIG_PATH[vardepsexclude] = "datadir WORKDIR" -PKG_CONFIG_PATH[vardepvalueexclude] = ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig" - # These recipes don't need multilib variants, the ${BPN} PROVDES/RPROVDES # ${MLPREFIX}${BPN} NON_MULTILIB_RECIPES = "grub grub-efi make-mod-scripts ovmf u-boot" I'm not sure this is correct, did you check something with a dependency on an allarch recipe that has a pkgconfig file? Yes, I have checked the recipe font-alias which uses pkgconfig and depends on the allarch recipe encodings and also checked the iso-codes recipe. Thanks, Cheers, Richard -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#188171): https://lists.openembedded.org/g/openembedded-core/message/188171 Mute This Topic: https://lists.openembedded.org/mt/101474719/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] multilib.conf: Remove the incorrect PKG_CONFIG_PATH setting
From: Mingli Yu The PKG_CONFIG_PATH is set as ${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig in multilib.conf. But there is no ${WORKDIR}/recipe-sysroot when multilib enabled such as below: $ bitbake lib32-php There is no ${WORKDIR}/recipe-sysroot and only ${WORKDIR}/lib32-recipe-sysroot exists which already covered in meta/conf/bitbake.conf as below: export PKG_CONFIG_PATH = "${PKG_CONFIG_DIR}:${STAGING_DATADIR}/pkgconfig" So remove the incorrect setting in multilib.conf. Signed-off-by: Mingli Yu --- meta/conf/multilib.conf | 9 - 1 file changed, 9 deletions(-) diff --git a/meta/conf/multilib.conf b/meta/conf/multilib.conf index ef3605a73d..09546315b8 100644 --- a/meta/conf/multilib.conf +++ b/meta/conf/multilib.conf @@ -22,15 +22,6 @@ MULTILIB_GLOBAL_VARIANTS ?= "lib32 lib64 libx32" OPKG_ARGS:append = " --force-maintainer --force-overwrite" -# When multilib is enabled, allarch recipes will be installed into the MACHINE -# sysroot, not MLPREFIXMACHINE. This means that anything using pkg-config to -# find an allarch pkgconfig file will fail as the PKG_CONFIG_PATH only looks -# inside the multilib sysroot. Fix this by explicitly adding the MACHINE's -# architecture-independent pkgconfig location to PKG_CONFIG_PATH. -PKG_CONFIG_PATH .= ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig" -PKG_CONFIG_PATH[vardepsexclude] = "datadir WORKDIR" -PKG_CONFIG_PATH[vardepvalueexclude] = ":${WORKDIR}/recipe-sysroot/${datadir}/pkgconfig" - # These recipes don't need multilib variants, the ${BPN} PROVDES/RPROVDES # ${MLPREFIX}${BPN} NON_MULTILIB_RECIPES = "grub grub-efi make-mod-scripts ovmf u-boot" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#187900): https://lists.openembedded.org/g/openembedded-core/message/187900 Mute This Topic: https://lists.openembedded.org/mt/101474719/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] [mickledore][PATCH v2] fixup! python3-numpy: remove NPY_INLINE, use inline instead
We will encounter the build failure when debug enabled(add DEBUG_BUILD = "1" in local.conf) [1]. [1] https://git.openembedded.org/openembedded-core/commit/?h=mickledore=77a64a8686b6c9ef3bc6adbce6cdc442096decfd Thanks, From: Khem Raj Sent: Friday, September 8, 2023 12:46 To: Yu, Mingli Cc: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] [mickledore][PATCH v2] fixup! python3-numpy: remove NPY_INLINE, use inline instead CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. when do we see these errors ? how does this impact performance? On Thu, Sep 7, 2023 at 9:16 PM Yu, Mingli wrote: > > From: Mingli Yu > > Fixes: >/usr/lib/gcc/x86_64-redhat-linux/13/include/avx512fintrin.h:314:1: error: > inlining failed in call to 'always_inline' '_mm512_setzero_ps': target > specific option mismatch >314 | _mm512_setzero_ps (void) >| ^ >numpy/core/src/umath/simd.inc.src:977:20: note: called from here >977 | @vtype@ zeros = _mm512_setzero_@vsuffix@(); >|^~~ >numpy/core/src/umath/simd.inc.src:596:1: error: inlining failed in call to > ‘always_inline’ ‘avx512_get_full_load_mask_ps’: target specific option > mismatch >596 | avx512_get_full_load_mask_ps(void) >| ^~~~ > numpy/core/src/umath/simd.inc.src:976:27: note: called from here >976 | @mask@ load_mask = avx512_get_full_load_mask_@vsuffix@(); >| ^~ > > Signed-off-by: Mingli Yu > --- > .../0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git > a/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch > > b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch > index d733dda333..73c9c79bdd 100644 > --- > a/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch > +++ > b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch > @@ -117,7 +117,7 @@ index d6c9a7e..39aec9a 100644 > > #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined > NPY_HAVE_SSE2_INTRINSICS > -static NPY_GCC_OPT_3 NPY_INLINE NPY_GCC_TARGET_AVX512F void > -+static NPY_GCC_OPT_3 inline NPY_GCC_TARGET_AVX512F void > ++static inline NPY_GCC_TARGET_AVX512F void > AVX512F_@func@_@TYPE@(@type@ * op, > @type@ * ip, > const npy_intp array_size, > @@ -126,7 +126,7 @@ index d6c9a7e..39aec9a 100644 > > #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined > NPY_HAVE_SSE2_INTRINSICS > -static NPY_GCC_OPT_3 NPY_INLINE NPY_GCC_TARGET_AVX512F void > -+static NPY_GCC_OPT_3 inline NPY_GCC_TARGET_AVX512F void > ++static inline NPY_GCC_TARGET_AVX512F void > AVX512F_absolute_@TYPE@(@type@ * op, > @type@ * ip, > const npy_intp array_size, > -- > 2.25.1 > > > > -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#187404): https://lists.openembedded.org/g/openembedded-core/message/187404 Mute This Topic: https://lists.openembedded.org/mt/101231101/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 v2] fixup! python3-numpy: remove NPY_INLINE, use inline instead
From: Mingli Yu Fixes: /usr/lib/gcc/x86_64-redhat-linux/13/include/avx512fintrin.h:314:1: error: inlining failed in call to 'always_inline' '_mm512_setzero_ps': target specific option mismatch 314 | _mm512_setzero_ps (void) | ^ numpy/core/src/umath/simd.inc.src:977:20: note: called from here 977 | @vtype@ zeros = _mm512_setzero_@vsuffix@(); |^~~ numpy/core/src/umath/simd.inc.src:596:1: error: inlining failed in call to ‘always_inline’ ‘avx512_get_full_load_mask_ps’: target specific option mismatch 596 | avx512_get_full_load_mask_ps(void) | ^~~~ numpy/core/src/umath/simd.inc.src:976:27: note: called from here 976 | @mask@ load_mask = avx512_get_full_load_mask_@vsuffix@(); | ^~ Signed-off-by: Mingli Yu --- .../0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch index d733dda333..73c9c79bdd 100644 --- a/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch +++ b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch @@ -117,7 +117,7 @@ index d6c9a7e..39aec9a 100644 #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS -static NPY_GCC_OPT_3 NPY_INLINE NPY_GCC_TARGET_AVX512F void -+static NPY_GCC_OPT_3 inline NPY_GCC_TARGET_AVX512F void ++static inline NPY_GCC_TARGET_AVX512F void AVX512F_@func@_@TYPE@(@type@ * op, @type@ * ip, const npy_intp array_size, @@ -126,7 +126,7 @@ index d6c9a7e..39aec9a 100644 #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS -static NPY_GCC_OPT_3 NPY_INLINE NPY_GCC_TARGET_AVX512F void -+static NPY_GCC_OPT_3 inline NPY_GCC_TARGET_AVX512F void ++static inline NPY_GCC_TARGET_AVX512F void AVX512F_absolute_@TYPE@(@type@ * op, @type@ * ip, const npy_intp array_size, -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#187402): https://lists.openembedded.org/g/openembedded-core/message/187402 Mute This Topic: https://lists.openembedded.org/mt/101231101/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] fixup! python3-numpy: remove NPY_INLINE, use inline instead
From: Mingli Yu Fixes: /usr/lib/gcc/x86_64-redhat-linux/13/include/avx512fintrin.h:314:1: error: inlining failed in call to 'always_inline' '_mm512_setzero_ps': target specific option mismatch 314 | _mm512_setzero_ps (void) | ^ numpy/core/src/umath/simd.inc.src:977:20: note: called from here 977 | @vtype@ zeros = _mm512_setzero_@vsuffix@(); |^~~ numpy/core/src/umath/simd.inc.src:596:1: error: inlining failed in call to ‘always_inline’ ‘avx512_get_full_load_mask_ps’: target specific option mismatch 596 | avx512_get_full_load_mask_ps(void) | ^~~~ numpy/core/src/umath/simd.inc.src:976:27: note: called from here 976 | @mask@ load_mask = avx512_get_full_load_mask_@vsuffix@(); | ^~ --- .../0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch index d733dda333..73c9c79bdd 100644 --- a/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch +++ b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch @@ -117,7 +117,7 @@ index d6c9a7e..39aec9a 100644 #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS -static NPY_GCC_OPT_3 NPY_INLINE NPY_GCC_TARGET_AVX512F void -+static NPY_GCC_OPT_3 inline NPY_GCC_TARGET_AVX512F void ++static inline NPY_GCC_TARGET_AVX512F void AVX512F_@func@_@TYPE@(@type@ * op, @type@ * ip, const npy_intp array_size, @@ -126,7 +126,7 @@ index d6c9a7e..39aec9a 100644 #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS -static NPY_GCC_OPT_3 NPY_INLINE NPY_GCC_TARGET_AVX512F void -+static NPY_GCC_OPT_3 inline NPY_GCC_TARGET_AVX512F void ++static inline NPY_GCC_TARGET_AVX512F void AVX512F_absolute_@TYPE@(@type@ * op, @type@ * ip, const npy_intp array_size, -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#187401): https://lists.openembedded.org/g/openembedded-core/message/187401 Mute This Topic: https://lists.openembedded.org/mt/101231058/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] webkitgtk: Add opengl to REQUIRED_DISTRO_FEATURES
From: Mingli Yu webkitgtk depends on gtk4 which has the below logic, so add the same logic for webkitgtk. REQUIRED_DISTRO_FEATURES = "opengl" Fixes: ERROR: Nothing PROVIDES 'gtk4' (but /build/layers/oe-core/meta/recipes-sato/webkit/webkitgtk_2.40.5.bb DEPENDS on or otherwise requires it) gtk4 was skipped: missing required distro feature 'opengl' (not in DISTRO_FEATURES) ERROR: Required build target 'meta-world-pkgdata' has no buildable providers. Missing or unbuildable dependency chain was: ['meta-world-pkgdata', 'webkitgtk', 'gtk4'] Signed-off-by: Mingli Yu --- meta/recipes-sato/webkit/webkitgtk_2.40.5.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-sato/webkit/webkitgtk_2.40.5.bb b/meta/recipes-sato/webkit/webkitgtk_2.40.5.bb index 7bf32e8610..39bb6a476f 100644 --- a/meta/recipes-sato/webkit/webkitgtk_2.40.5.bb +++ b/meta/recipes-sato/webkit/webkitgtk_2.40.5.bb @@ -20,7 +20,7 @@ SRC_URI[sha256sum] = "7de051a263668621d91a61a5eb1c3771d1a7cec900043d4afef06c326c inherit cmake pkgconfig gobject-introspection perlnative features_check upstream-version-is-even gi-docgen ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}" -REQUIRED_DISTRO_FEATURES = "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'opengl', '', d)}" +REQUIRED_DISTRO_FEATURES = "opengl" CVE_PRODUCT = "webkitgtk webkitgtk\+" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#186818): https://lists.openembedded.org/g/openembedded-core/message/186818 Mute This Topic: https://lists.openembedded.org/mt/101005835/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 v4] qemu: Add qemu-common package
Hi Richard, On 8/14/23 17:25, Richard Purdie wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Mon, 2023-08-14 at 17:19 +0800, Yu, Mingli wrote: Ping. https://lists.openembedded.org/g/openembedded-core/message/184574 """ So why not just add: RRECOMMENDS:${PN} += "${PN}-system-all ${PN}-user-all" as I think we've then covered all the options we need? """ I still haven't seen an answer to this? Sorry for noise, have ever answered this question in another thread "[PATCH v3] qemu: Add qemu-common package". If just add RRECOMMENDS:${PN} += "${PN}-system-all ${PN}-user-all" by default, then how about the user who want only install qemu-system-aarch64-7.2.0-r0.corei7_64.rpm still install all qemu binaries as qemu-system-aarch64 rdepends on qemu which RRECOMMENDS qemu-system-all and qemu-user-all(https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db). So it's better make qemu as meta package to keep backward compatibility for user who install qemu can install all qemu binaries as before and also can meet the need for user who want just install qemu arm64 emulation rpm such as qemu-system-aarch64-7.2.0-r0.corei7_64.rpm(https://patchwork.yoctoproject.org/project/oe-core/patch/20230717071114.2734859-1-mingli...@eng.windriver.com/) via adding IMAGE_INSTALL:append = " qemu-system-aarch64" into conf/local.conf. Thanks, I don't like the fact we've messed this packaging around multiple times and still don't seem clear on the problem(s) we're solving. Cheers, Richard Thanks, On 7/17/23 15:11, Yu, Mingli wrote: From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- v3->v4: remove the added native-sdk dependency. meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.3.bb | 2 +- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 16581db69d..76560f454d 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -225,15 +225,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -241,15 +244,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|i
Re: [OE-core] [PATCH v4] qemu: Add qemu-common package
Ping. Thanks, On 7/17/23 15:11, Yu, Mingli wrote: From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- v3->v4: remove the added native-sdk dependency. meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.3.bb | 2 +- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 16581db69d..76560f454d 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -225,15 +225,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -241,15 +244,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.3.bb b/meta/recipes-devtools/qemu/qemu_8.0.3.bb index 42e133967e..5d3c47c3b0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.3.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.3.bb @@ -8,7 +8,7 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}" -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#185926): https://lists.openembedded.org/g/openembedded-core/message/185926 Mute This Topic: https://lists.openembedded.org/mt/100190357/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] qemuppc64: Set the default memory to 512M
On 8/2/23 16:32, Alexander Kanavin wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Wed, 2 Aug 2023 at 10:30, Yu, Mingli wrote: Did a simple check against core-image-full-cmdline with qemuppc64 just now and it can boot successfully with the default 256M memory. But it failed to boot with my customized image as the attached messages(/var/log/messages). If not change the default memory, how to resolve the OOM issue? Any hints? You can set QB_MEM directly in the recipe of the customized image? Oe-core does this in several images which have specific requirements for larger RAM amounts (e.g. test images where the tests require it). You can grep meta/ for examples. Thanks for the hints! I will have a try. Thanks, Alex -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#185453): https://lists.openembedded.org/g/openembedded-core/message/185453 Mute This Topic: https://lists.openembedded.org/mt/100479675/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] qemuppc64: Set the default memory to 512M
From: Mingli Yu When use 256M memory, it issues below OOM, so update the default memory to 512M to make the runqemu "runqemu slirp nographic qemuppc64" works well. [ 26.878923] Call Trace: [ 26.878994] [c34835d0] [c106e058] dump_stack_lvl+0x6c/0x9c (unreliable) [ 26.880196] [c3483600] [c03772d8] dump_header+0x64/0x2a4 [ 26.880312] [c3483680] [c0375d00] oom_kill_process+0x2e0/0x2f0 [ 26.880415] [c34836c0] [c03767b8] out_of_memory+0x138/0x7b0 [ 26.880472] [c3483770] [c03f91c4] __alloc_pages+0xda4/0x1430 [ 26.880549] [c3483970] [c0412738] alloc_pages+0xd8/0x210 [ 26.880604] [c34839b0] [c03694e4] filemap_alloc_folio+0x104/0x1d0 [ 26.880672] [c3483a50] [c036dcec] __filemap_get_folio+0x17c/0x490 [ 26.880730] [c3483b00] [c036e184] filemap_fault+0x184/0xaa0 [ 26.880782] [c3483bc0] [c03c3700] __do_fault+0x60/0x100 [ 26.880839] [c3483bf0] [c03cb0ac] __handle_mm_fault+0xb8c/0x1010 [ 26.880900] [c3483ce0] [c03cb6f0] handle_mm_fault+0x1c0/0x290 [ 26.880959] [c3483d30] [c006c3e4] ___do_page_fault+0x284/0xa50 [ 26.881042] [c3483de0] [c006ce90] do_page_fault+0x50/0x110 [ 26.881095] [c3483e10] [c0008c84] instruction_access_common_virt+0x194/0x1a0 [ 26.881183] --- interrupt: 400 at 0x7fffbbbcdb08 [ 26.881538] NIP: 7fffbbbcdb08 LR: 7fffbbb76b60 CTR: 7fffbbbcdb08 [ 26.881613] REGS: c3483e80 TRAP: 0400 Not tainted (6.1.38-yocto-standard) [ 26.881710] MSR: 80004280f033 CR: 48004882 XER: 20040003 [ 26.881928] CFAR: 7fffbbaae610 IRQMASK: 0 [ 26.881928] GPR00: 7fffbbb76b44 7fffe6621060 7fffbbcb7a00 000122a4b680 [ 26.881928] GPR04: 0002 2029 0009 [ 26.881928] GPR08: 000122a569a0 0001 44004883 [ 26.881928] GPR12: 7fffbbbcdb08 7fffbbd615e0 [ 26.881928] GPR16: [ 26.881928] GPR20: 7fffe66214b8 000122a5e340 [ 26.881928] GPR24: 074f 7fffe6621120 00012299d020 7fffe662113d [ 26.881928] GPR28: 7fffe6621100 0003 0001 000122972600 [ 26.882587] NIP [7fffbbbcdb08] 0x7fffbbbcdb08 [ 26.882640] LR [7fffbbb76b60] 0x7fffbbb76b60 [ 26.882702] --- interrupt: 400 [ 26.900248] Mem-Info: [ 26.907378] active_anon:65 inactive_anon:1134 isolated_anon:0 [ 26.907378] active_file:7 inactive_file:22 isolated_file:0 [ 26.907378] unevictable:0 dirty:0 writeback:0 [ 26.907378] slab_reclaimable:226 slab_unreclaimable:528 [ 26.907378] mapped:36 shmem:239 pagetables:67 [ 26.907378] sec_pagetables:0 bounce:0 [ 26.907378] kernel_misc_reclaimable:0 [ 26.907378] free:77 free_pcp:6 free_cma:0 [ 26.907799] Node 0 active_anon:4160kB inactive_anon:72576kB active_file:448kB inactive_file:1408kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:2304kB dirty:0kB writeback:0kB shmem:15296kB writeback_tmp:0kB kernel_stack:1744kB pagetables:4288kB sec_pagetables:0kB all_unreclaimable? no [ 26.908057] Node 0 Normal free:4928kB boost:0kB min:1536kB low:1920kB high:2304kB reserved_highatomic:0KB active_anon:4160kB inactive_anon:72768kB active_file:704kB inactive_file:2048kB unevictable:0kB writepending:0kB present:262144kB managed:163008kB mlocked:0kB bounce:0kB free_pcp:448kB local_pcp:384kB free_cma:0kB [ 26.908374] lowmem_reserve[]: 0 0 [ 26.908516] Node 0 Normal: 39*64kB (UM) 5*128kB (ME) 7*256kB (UE) 0*512kB 0*1024kB 0*2048kB 0*4096kB 0*8192kB 0*16384kB = 4928kB [ 26.908956] 296 total pagecache pages [ 26.909050] 0 pages in swap cache [ 26.909102] Free swap = 0kB [ 26.909150] Total swap = 0kB [ 26.909268] 4096 pages RAM [ 26.909303] 0 pages HighMem/MovableOnly [ 26.909343] 1549 pages reserved [ 26.909453] Tasks state (memory values in pages): [ 26.909498] [ pid ] uid tgid total_vm rss pgtables_bytes swapents oom_score_adj name [ 26.909777] [125] 998 125 104 21222720 0 rpcbind [ 26.919186] [126] 0 126 430 66235520 -250 systemd-journal [ 26.919387] [145] 0 145 471 60238080 -1000 systemd-udevd [ 26.919478] [150] 989 150 307 56235520 0 systemd-resolve [ 26.919547] [156] 988 156 1458 56238080 0 systemd-timesyn [ 26.919616] [176] 0 176 62 13217600 0 atd [ 26.919676] [177] 995 177 133 31225280 0 avahi-daemon [
[OE-core] [mickledore][PATCH] ruby: Fix CVE-2023-36617
From: Mingli Yu Backport two patches [1] [2] to fix CVE-2023-36617 [3]. [1] https://github.com/ruby/uri/commit/9010ee2536adda10a0555ae1ed6fe2f5808e6bf1 [2] https://github.com/ruby/uri/commit/9d7bcef1e6ad23c9c6e4932f297fb737888144c8 [3] https://www.ruby-lang.org/en/news/2023/06/29/redos-in-uri-CVE-2023-36617/ Signed-off-by: Mingli Yu --- .../ruby/ruby/CVE-2023-36617_1.patch | 56 +++ .../ruby/ruby/CVE-2023-36617_2.patch | 52 + meta/recipes-devtools/ruby/ruby_3.2.2.bb | 2 + 3 files changed, 110 insertions(+) create mode 100644 meta/recipes-devtools/ruby/ruby/CVE-2023-36617_1.patch create mode 100644 meta/recipes-devtools/ruby/ruby/CVE-2023-36617_2.patch diff --git a/meta/recipes-devtools/ruby/ruby/CVE-2023-36617_1.patch b/meta/recipes-devtools/ruby/ruby/CVE-2023-36617_1.patch new file mode 100644 index 00..17c7e30176 --- /dev/null +++ b/meta/recipes-devtools/ruby/ruby/CVE-2023-36617_1.patch @@ -0,0 +1,56 @@ +From 2ebb50d2dc302917a6f57c1239dc9e700dfe0e34 Mon Sep 17 00:00:00 2001 +From: Nobuyoshi Nakada +Date: Thu, 27 Jul 2023 15:53:01 +0800 +Subject: [PATCH] Fix quadratic backtracking on invalid relative URI + +https://hackerone.com/reports/1958260 + +CVE: CVE-2023-36617 + +Upstream-Status: Backport [https://github.com/ruby/uri/commit/9010ee2536adda10a0555ae1ed6fe2f5808e6bf1] + +Signed-off-by: Mingli Yu +--- + lib/uri/rfc2396_parser.rb | 4 ++-- + test/uri/test_parser.rb | 12 + 2 files changed, 14 insertions(+), 2 deletions(-) + +diff --git a/lib/uri/rfc2396_parser.rb b/lib/uri/rfc2396_parser.rb +index 76a8f99..00c66cf 100644 +--- a/lib/uri/rfc2396_parser.rb b/lib/uri/rfc2396_parser.rb +@@ -497,8 +497,8 @@ module URI + ret = {} + + # for URI::split +- ret[:ABS_URI] = Regexp.new('\A\s*' + pattern[:X_ABS_URI] + '\s*\z', Regexp::EXTENDED) +- ret[:REL_URI] = Regexp.new('\A\s*' + pattern[:X_REL_URI] + '\s*\z', Regexp::EXTENDED) ++ ret[:ABS_URI] = Regexp.new('\A\s*+' + pattern[:X_ABS_URI] + '\s*\z', Regexp::EXTENDED) ++ ret[:REL_URI] = Regexp.new('\A\s*+' + pattern[:X_REL_URI] + '\s*\z', Regexp::EXTENDED) + + # for URI::extract + ret[:URI_REF] = Regexp.new(pattern[:URI_REF]) +diff --git a/test/uri/test_parser.rb b/test/uri/test_parser.rb +index 72fb590..721e05e 100644 +--- a/test/uri/test_parser.rb b/test/uri/test_parser.rb +@@ -79,4 +79,16 @@ class URI::TestParser < Test::Unit::TestCase + assert_equal([nil, nil, "example.com", nil, nil, "", nil, nil, nil], URI.split("//example.com")) + assert_equal([nil, nil, "[0::0]", nil, nil, "", nil, nil, nil], URI.split("//[0::0]")) + end ++ ++ def test_rfc2822_parse_relative_uri ++pre = ->(length) { ++ " " * length + "\0" ++} ++parser = URI::RFC2396_Parser.new ++assert_linear_performance((1..5).map {|i| 10**i}, pre: pre) do |uri| ++ assert_raise(URI::InvalidURIError) do ++parser.split(uri) ++ end ++end ++ end + end +-- +2.25.1 + diff --git a/meta/recipes-devtools/ruby/ruby/CVE-2023-36617_2.patch b/meta/recipes-devtools/ruby/ruby/CVE-2023-36617_2.patch new file mode 100644 index 00..7c51deaa42 --- /dev/null +++ b/meta/recipes-devtools/ruby/ruby/CVE-2023-36617_2.patch @@ -0,0 +1,52 @@ +From eea5868120509c245216c4b5c2d4b5db1c593d0e Mon Sep 17 00:00:00 2001 +From: Nobuyoshi Nakada +Date: Thu, 27 Jul 2023 16:16:30 +0800 +Subject: [PATCH] Fix quadratic backtracking on invalid port number + +https://hackerone.com/reports/1958260 + +CVE: CVE-2023-36617 + +Upstream-Status: Backport [https://github.com/ruby/uri/commit/9d7bcef1e6ad23c9c6e4932f297fb737888144c8] + +Signed-off-by: Mingli Yu +--- + lib/uri/rfc3986_parser.rb | 2 +- + test/uri/test_parser.rb | 10 ++ + 2 files changed, 11 insertions(+), 1 deletion(-) + +diff --git a/lib/uri/rfc3986_parser.rb b/lib/uri/rfc3986_parser.rb +index dd24a40..9b1663d 100644 +--- a/lib/uri/rfc3986_parser.rb b/lib/uri/rfc3986_parser.rb +@@ -100,7 +100,7 @@ module URI + QUERY: /\A(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*\z/, + FRAGMENT: /\A(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*\z/, + OPAQUE: /\A(?:[^\/].*)?\z/, +-PORT: /\A[\x09\x0a\x0c\x0d ]*\d*[\x09\x0a\x0c\x0d ]*\z/, ++PORT: /\A[\x09\x0a\x0c\x0d ]*+\d*[\x09\x0a\x0c\x0d ]*\z/, + } + end + +diff --git a/test/uri/test_parser.rb b/test/uri/test_parser.rb +index 721e05e..cee0acb 100644 +--- a/test/uri/test_parser.rb b/test/uri/test_parser.rb +@@ -91,4 +91,14 @@ class URI::TestParser < Test::Unit::TestCase + end + end + end ++ ++ def test_rfc3986_port_check ++pre = ->(length) {"\t" * length + "a"} ++uri = URI.parse("http://my.example.com;) ++assert_linear_performance((1..5).map {|i| 10**i}, pre: pre) do |port| ++ assert_raise(URI::InvalidComponentError) do ++uri.port = port ++ end ++end ++ end + end +-- +2.25.1 + diff --git a/meta/recipes-devtools/ruby/ruby_3.2.2.bb
Re: [OE-core] [PATCH v4] qemu: Add qemu-common package
Ping. Thanks, On 7/17/23 15:11, Yu, Mingli wrote: From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- v3->v4: remove the added native-sdk dependency. meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.3.bb | 2 +- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 16581db69d..76560f454d 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -225,15 +225,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -241,15 +244,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.3.bb b/meta/recipes-devtools/qemu/qemu_8.0.3.bb index 42e133967e..5d3c47c3b0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.3.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.3.bb @@ -8,7 +8,7 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}" -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184908): https://lists.openembedded.org/g/openembedded-core/message/184908 Mute This Topic: https://lists.openembedded.org/mt/100190357/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] cups: Fix CVE-2023-34241
From: Mingli Yu Backport patch [1] to fix CVE-2023-34241. [1] https://github.com/OpenPrinting/cups/commit/9809947a959e18409dcf562a3466ef246cb90cb2 Signed-off-by: Mingli Yu --- meta/recipes-extended/cups/cups.inc | 1 + .../cups/cups/CVE-2023-34241.patch| 70 +++ 2 files changed, 71 insertions(+) create mode 100644 meta/recipes-extended/cups/cups/CVE-2023-34241.patch diff --git a/meta/recipes-extended/cups/cups.inc b/meta/recipes-extended/cups/cups.inc index d77758fd3f..c6a676b747 100644 --- a/meta/recipes-extended/cups/cups.inc +++ b/meta/recipes-extended/cups/cups.inc @@ -16,6 +16,7 @@ SRC_URI = "${GITHUB_BASE_URI}/download/v${PV}/cups-${PV}-source.tar.gz \ file://volatiles.99_cups \ file://cups-volatiles.conf \ file://CVE-2023-32324.patch \ + file://CVE-2023-34241.patch \ " GITHUB_BASE_URI = "https://github.com/OpenPrinting/cups/releases; diff --git a/meta/recipes-extended/cups/cups/CVE-2023-34241.patch b/meta/recipes-extended/cups/cups/CVE-2023-34241.patch new file mode 100644 index 00..4950ca341d --- /dev/null +++ b/meta/recipes-extended/cups/cups/CVE-2023-34241.patch @@ -0,0 +1,70 @@ +From ffd290b4ab247f82722927ba9b21358daa16dbf1 Mon Sep 17 00:00:00 2001 +From: Rose <83477269+ataridre...@users.noreply.github.com> +Date: Thu, 1 Jun 2023 11:33:39 -0400 +Subject: [PATCH] Log result of httpGetHostname BEFORE closing the connection + +httpClose frees the memory of con->http. This is problematic because httpGetHostname then tries to access the memory it points to. + +We have to log the hostname first. + +CVE: CVE-2023-34241 + +Upstream-Status: Backport [https://github.com/OpenPrinting/cups/commit/9809947a959e18409dcf562a3466ef246cb90cb2] + +Signed-off-by: Mingli Yu +--- + scheduler/client.c | 16 +++- + 1 file changed, 7 insertions(+), 9 deletions(-) + +diff --git a/scheduler/client.c b/scheduler/client.c +index 91e441188..327473a4d 100644 +--- a/scheduler/client.c b/scheduler/client.c +@@ -193,13 +193,11 @@ cupsdAcceptClient(cupsd_listener_t *lis)/* I - Listener socket */ +/* + * Can't have an unresolved IP address with double-lookups enabled... + */ +- +-httpClose(con->http); +- + cupsdLogClient(con, CUPSD_LOG_WARN, +-"Name lookup failed - connection from %s closed!", ++"Name lookup failed - closing connection from %s!", + httpGetHostname(con->http, NULL, 0)); + ++httpClose(con->http); + free(con); + return; + } +@@ -235,11 +233,11 @@ cupsdAcceptClient(cupsd_listener_t *lis)/* I - Listener socket */ + * with double-lookups enabled... + */ + +- httpClose(con->http); +- + cupsdLogClient(con, CUPSD_LOG_WARN, +- "IP lookup failed - connection from %s closed!", ++ "IP lookup failed - closing connection from %s!", + httpGetHostname(con->http, NULL, 0)); ++ ++ httpClose(con->http); + free(con); + return; + } +@@ -256,11 +254,11 @@ cupsdAcceptClient(cupsd_listener_t *lis)/* I - Listener socket */ + + if (!hosts_access(_req)) + { +-httpClose(con->http); +- + cupsdLogClient(con, CUPSD_LOG_WARN, + "Connection from %s refused by /etc/hosts.allow and " + "/etc/hosts.deny rules.", httpGetHostname(con->http, NULL, 0)); ++ ++httpClose(con->http); + free(con); + return; + } +-- +2.25.1 + -- 2.35.5 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184867): https://lists.openembedded.org/g/openembedded-core/message/184867 Mute This Topic: https://lists.openembedded.org/mt/100366862/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 v3] qemu: Add qemu-common package
Hi Richard, On 7/19/23 18:08, Richard Purdie wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Wed, 2023-07-19 at 17:39 +0800, Yu, Mingli wrote: On 7/19/23 17:24, Richard Purdie wrote: It is relevant, this is because of the dependency that this gets built and fails. I've seen v4 but didn't have the time to test it yet. I've still not seen an answer to Ross' question or mine about why we can't just add a couple of dependencies and resolve things that way. Sorry for delayed respond! Have added qemu-common to make qemu as meta package to keep backward compatibility. For user who install qemu rpm such as qemu-7.2.0-r0.corei7_64.rpm, it still pull in all of things as before. For user who cares the rpm size, can just choose to install the needed qemu arch rpms such as qemu-system-aarch64-7.2.0-r0.corei7_64.rpm. So why not just add: RRECOMMENDS:${PN} += "${PN}-system-all ${PN}-user-all" as I think we've then covered all the options we need? If just add RRECOMMENDS:${PN} += "${PN}-system-all ${PN}-user-all" by default, then how about the user who want only install qemu-system-aarch64-7.2.0-r0.corei7_64.rpm still install all qemu binaries as qemu-system-aarch64 rdepends on qemu which RRECOMMENDS qemu-system-all and qemu-user-all(https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db). So it's better make qemu as meta package to keep backward compatibility for user who install qemu can install all qemu binaries as before and also can meet the need for user who want just install qemu arm64 emulation rpm such as qemu-system-aarch64-7.2.0-r0.corei7_64.rpm(https://patchwork.yoctoproject.org/project/oe-core/patch/20230717071114.2734859-1-mingli...@eng.windriver.com/) via adding IMAGE_INSTALL:append = " qemu-system-aarch64" into conf/local.conf. Thanks, Cheers, Richard -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184619): https://lists.openembedded.org/g/openembedded-core/message/184619 Mute This Topic: https://lists.openembedded.org/mt/100054994/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 v3] qemu: Add qemu-common package
Hi Richard and Ross, On 7/19/23 17:24, Richard Purdie wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Wed, 2023-07-19 at 11:20 +0200, Alexandre Belloni via lists.openembedded.org wrote: On 19/07/2023 17:10:37+0800, Yu, Mingli wrote: Hi Alex, On 7/17/23 20:46, Alexandre Belloni wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On 17/07/2023 15:10:35+0800, Yu, Mingli wrote: Hi Alex, On 7/16/23 19:47, Alexandre Belloni wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. Hello, This causes the following meta-mingw error on the AB: https://autobuilder.yoctoproject.org/typhoon/#/builders/89/builds/7501/steps/12/logs/stdio I didn't find the core-image-mingw-sdktest recipe which I noticed in the above log, so I cannot reproduce the issue as you mentioned. As stated above, this is part of meta-mingw: https://git.yoctoproject.org/meta-mingw/tree/recipes-core/images?h=master-next Thanks for your pointer! BTW, the below error which in https://autobuilder.yoctoproject.org/typhoon/#/builders/89/builds/7501/steps/12/logs/stdio seems irrelevant to the added nativesdk dependency though I have removed the nativesdk dependency in https://patchwork.yoctoproject.org/project/oe-core/patch/20230717071114.2734859-1-mingli...@eng.windriver.com/. /home/pokybuild/yocto-worker/meta-mingw/build/build/tmp/work/i686-nativesdk-mingw32-w64-mingw32/nativesdk-ncurses/6.4-r0/recipe-sysroot-native/usr/bin/i686-w64-mingw32/../../libexec/i686-w64-mingw32/gcc/i686-w64-mingw32/13.1.1/ld: ../obj_s/lib_kernel.o:lib_kernel.c:(.text+0x5c): undefined reference to `_nc_mingw_tcflush' /home/pokybuild/yocto-worker/meta-mingw/build/build/tmp/work/i686-nativesdk-mingw32-w64-mingw32/nativesdk-ncurses/6.4-r0/recipe-sysroot-native/usr/bin/i686-w64-mingw32/../../libexec/i686-w64-mingw32/gcc/i686-w64-mingw32/13.1.1/ld: ../obj_s/lib_ttyflags.o:lib_ttyflags.c:(.text+0x2c): undefined reference to `_nc_mingw_tcgetattr' /home/pokybuild/yocto-worker/meta-mingw/build/build/tmp/work/i686-nativesdk-mingw32-w64-mingw32/nativesdk-ncurses/6.4-r0/recipe-sysroot-native/usr/bin/i686-w64-mingw32/../../libexec/i686-w64-mingw32/gcc/i686-w64-mingw32/13.1.1/ld: ../obj_s/lib_ttyflags.o:lib_ttyflags.c:(.text+0xbb): undefined reference to `_nc_mingw_tcsetattr' It is relevant, this is because of the dependency that this gets built and fails. I've seen v4 but didn't have the time to test it yet. I've still not seen an answer to Ross' question or mine about why we can't just add a couple of dependencies and resolve things that way. Sorry for delayed respond! Have added qemu-common to make qemu as meta package to keep backward compatibility. For user who install qemu rpm such as qemu-7.2.0-r0.corei7_64.rpm, it still pull in all of things as before. For user who cares the rpm size, can just choose to install the needed qemu arch rpms such as qemu-system-aarch64-7.2.0-r0.corei7_64.rpm. Thanks, Cheers, Richard -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184573): https://lists.openembedded.org/g/openembedded-core/message/184573 Mute This Topic: https://lists.openembedded.org/mt/100054994/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 v3] qemu: Add qemu-common package
Hi Alex, On 7/17/23 20:46, Alexandre Belloni wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On 17/07/2023 15:10:35+0800, Yu, Mingli wrote: Hi Alex, On 7/16/23 19:47, Alexandre Belloni wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. Hello, This causes the following meta-mingw error on the AB: https://autobuilder.yoctoproject.org/typhoon/#/builders/89/builds/7501/steps/12/logs/stdio I didn't find the core-image-mingw-sdktest recipe which I noticed in the above log, so I cannot reproduce the issue as you mentioned. As stated above, this is part of meta-mingw: https://git.yoctoproject.org/meta-mingw/tree/recipes-core/images?h=master-next Thanks for your pointer! BTW, the below error which in https://autobuilder.yoctoproject.org/typhoon/#/builders/89/builds/7501/steps/12/logs/stdio seems irrelevant to the added nativesdk dependency though I have removed the nativesdk dependency in https://patchwork.yoctoproject.org/project/oe-core/patch/20230717071114.2734859-1-mingli...@eng.windriver.com/. | /home/pokybuild/yocto-worker/meta-mingw/build/build/tmp/work/i686-nativesdk-mingw32-w64-mingw32/nativesdk-ncurses/6.4-r0/recipe-sysroot-native/usr/bin/i686-w64-mingw32/../../libexec/i686-w64-mingw32/gcc/i686-w64-mingw32/13.1.1/ld: ../obj_s/lib_kernel.o:lib_kernel.c:(.text+0x5c): undefined reference to `_nc_mingw_tcflush' | /home/pokybuild/yocto-worker/meta-mingw/build/build/tmp/work/i686-nativesdk-mingw32-w64-mingw32/nativesdk-ncurses/6.4-r0/recipe-sysroot-native/usr/bin/i686-w64-mingw32/../../libexec/i686-w64-mingw32/gcc/i686-w64-mingw32/13.1.1/ld: ../obj_s/lib_ttyflags.o:lib_ttyflags.c:(.text+0x2c): undefined reference to `_nc_mingw_tcgetattr' | /home/pokybuild/yocto-worker/meta-mingw/build/build/tmp/work/i686-nativesdk-mingw32-w64-mingw32/nativesdk-ncurses/6.4-r0/recipe-sysroot-native/usr/bin/i686-w64-mingw32/../../libexec/i686-w64-mingw32/gcc/i686-w64-mingw32/13.1.1/ld: ../obj_s/lib_ttyflags.o:lib_ttyflags.c:(.text+0xbb): undefined reference to `_nc_mingw_tcsetattr' Thanks, Thanks, This is due to the added native-sdk dependency. On 10/07/2023 18:32:18+0800, Yu, Mingli wrote: From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.0.bb | 3 ++- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a5bdeef66d..94624163d0 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -226,15 +226,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -242,15 +245,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages =
[OE-core] [mickledore][PATCH] acpica: Update SRC_URI
From: Mingli Yu Update the SRC_URI to fix the do_fetch warning. $ wget https://acpica.org/sites/acpica/files/acpica-unix-20220331.tar.gz --2023-07-19 02:45:33-- https://acpica.org/sites/acpica/files/acpica-unix-20220331.tar.gz Resolving acpica.org... 20.29.206.128 Connecting to acpica.org|20.29.206.128|:443... connected. HTTP request sent, awaiting response... 301 Moved Permanently Location: https://www.intel.com/content/www/us/en/developer/topic-technology/open/acpica/overview.html [following] --2023-07-19 02:45:33-- https://www.intel.com/content/www/us/en/developer/topic-technology/open/acpica/overview.html Resolving www.intel.com... 23.72.14.54 Connecting to www.intel.com|23.72.14.54|:443... connected. HTTP request sent, awaiting response... 403 Forbidden 2023-07-19 02:45:34 ERROR 403: Forbidden. $ wget https://downloadmirror.intel.com/774879/acpica-unix-20220331.tar.gz --2023-07-19 02:46:04-- https://downloadmirror.intel.com/774879/acpica-unix-20220331.tar.gz Resolving downloadmirror.intel.com... 18.164.154.85, 18.164.154.5, 18.164.154.74, ... Connecting to downloadmirror.intel.com|18.164.154.85|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 1911044 (1.8M) [application/gzip] Saving to: ‘acpica-unix-20220331.tar.gz’ acpica-unix-20220331.tar.gz 100%[=>] 1.82M 1.61MB/sin 1.1s 2023-07-19 02:46:06 (1.61 MB/s) - ‘acpica-unix-20220331.tar.gz’ saved [1911044/1911044] Signed-off-by: Mingli Yu --- meta/recipes-extended/acpica/acpica_20220331.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-extended/acpica/acpica_20220331.bb b/meta/recipes-extended/acpica/acpica_20220331.bb index 2c554f863a..73b9154ee7 100644 --- a/meta/recipes-extended/acpica/acpica_20220331.bb +++ b/meta/recipes-extended/acpica/acpica_20220331.bb @@ -16,7 +16,7 @@ COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux" DEPENDS = "m4-native flex-native bison-native" -SRC_URI = "https://acpica.org/sites/acpica/files/acpica-unix-${PV}.tar.gz; +SRC_URI = "https://downloadmirror.intel.com/774879/acpica-unix-${PV}.tar.gz; SRC_URI[sha256sum] = "acaff68b14f1e0804ebbfc4b97268a4ccbefcfa053b02ed9924f2b14d8a98e21" UPSTREAM_CHECK_URI = "https://acpica.org/downloads; -- 2.35.5 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184565): https://lists.openembedded.org/g/openembedded-core/message/184565 Mute This Topic: https://lists.openembedded.org/mt/100229117/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 v4] qemu: Add qemu-common package
From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- v3->v4: remove the added native-sdk dependency. meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.3.bb | 2 +- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 16581db69d..76560f454d 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -225,15 +225,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -241,15 +244,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.3.bb b/meta/recipes-devtools/qemu/qemu_8.0.3.bb index 42e133967e..5d3c47c3b0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.3.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.3.bb @@ -8,7 +8,7 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184432): https://lists.openembedded.org/g/openembedded-core/message/184432 Mute This Topic: https://lists.openembedded.org/mt/100190357/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 v3] qemu: Add qemu-common package
Hi Alex, On 7/16/23 19:47, Alexandre Belloni wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. Hello, This causes the following meta-mingw error on the AB: https://autobuilder.yoctoproject.org/typhoon/#/builders/89/builds/7501/steps/12/logs/stdio I didn't find the core-image-mingw-sdktest recipe which I noticed in the above log, so I cannot reproduce the issue as you mentioned. Thanks, This is due to the added native-sdk dependency. On 10/07/2023 18:32:18+0800, Yu, Mingli wrote: From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.0.bb | 3 ++- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a5bdeef66d..94624163d0 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -226,15 +226,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -242,15 +245,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.0.bb b/meta/recipes-devtools/qemu/qemu_8.0.0.bb index 42e133967e..412c2bc7f0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.0.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.0.bb @@ -8,7 +8,8 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" +RDEPENDS:${PN}-common:class-nativesdk += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BB
Re: [OE-core] [PATCH v3] qemu: Add qemu-common package
On 7/11/23 04:47, Alexandre Belloni wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. Hello, On 10/07/2023 18:32:18+0800, Yu, Mingli wrote: From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- Please insert a changelog between your patch versions here, especially since you are sending v3 while v2 is under tessting. Will insert changelog next time. Also, don't put subsequent version in the same thread as v1, this may cause your patches to be ignored as they appear in an old thread. Got it. Thanks, meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.0.bb | 3 ++- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a5bdeef66d..94624163d0 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -226,15 +226,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -242,15 +245,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.0.bb b/meta/recipes-devtools/qemu/qemu_8.0.0.bb index 42e133967e..412c2bc7f0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.0.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.0.bb @@ -8,7 +8,8 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" +RDEPENDS:${PN}-common:class-nativesdk += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capst
[OE-core] [PATCH v3] qemu: Add qemu-common package
From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.0.bb | 3 ++- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a5bdeef66d..94624163d0 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -226,15 +226,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${bindir}/* ${includedir}/* ${libexecdir}/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -242,15 +245,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.0.bb b/meta/recipes-devtools/qemu/qemu_8.0.0.bb index 42e133967e..412c2bc7f0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.0.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.0.bb @@ -8,7 +8,8 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" +RDEPENDS:${PN}-common:class-nativesdk += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184068): https://lists.openembedded.org/g/openembedded-core/message/184068 Mute This Topic: https://lists.openembedded.org/mt/100054994/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] qemu: Add qemu-common package
From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.0.bb | 3 ++- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a5bdeef66d..e87e4ad667 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -226,15 +226,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "${prefix}/bin/* ${prefix}/include/* ${prefix}/libexec/* ${datadir}/* ${localstatedir}" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -242,15 +245,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.0.bb b/meta/recipes-devtools/qemu/qemu_8.0.0.bb index 42e133967e..412c2bc7f0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.0.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.0.bb @@ -8,7 +8,8 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" +RDEPENDS:${PN}-common:class-nativesdk += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#184060): https://lists.openembedded.org/g/openembedded-core/message/184060 Mute This Topic: https://lists.openembedded.org/mt/100053609/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] python3-numpy: remove NPY_INLINE, use inline instead
From: Mingli Yu The build fails when DEBUG_BUILD is enabled with GCC-13 as [1] and [2]. Fixes: | numpy/core/src/umath/simd.inc.src:977:20: note: called from here | 977 | @vtype@ zeros = _mm512_setzero_@vsuffix@(); |^~~ | numpy/core/src/umath/simd.inc.src:596:1: error: inlining failed in call to ‘always_inline’ ‘avx512_get_full_load_mask_ps’: target specific option mismatch 596 | avx512_get_full_load_mask_ps(void) | ^~~~ | numpy/core/src/umath/simd.inc.src:976:27: note: called from here 976 | @mask@ load_mask = avx512_get_full_load_mask_@vsuffix@(); | ^~ | /usr/lib/gcc/x86_64-redhat-linux/13/include/avx512fintrin.h:6499:1: error: inlining failed in call to ‘always_inline’ ‘_mm512_loadu_si512’: target specific option mismatch Reference: https://github.com/numpy/numpy/pull/22674/commits/3947b1a023a07a55522de65b4d302339bac2bad7 [1] https://git.openembedded.org/openembedded-core/commit/?id=8596678667797971559aed962b1c204266032186 [2] http://errors.yoctoproject.org/Errors/Details/689841/ Signed-off-by: Mingli Yu --- inc.src-Change-NPY_INLINE-to-inline.patch | 135 ++ .../python/python3-numpy_1.24.2.bb| 1 + 2 files changed, 136 insertions(+) create mode 100644 meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch diff --git a/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch new file mode 100644 index 00..d733dda333 --- /dev/null +++ b/meta/recipes-devtools/python/python3-numpy/0001-simd.inc.src-Change-NPY_INLINE-to-inline.patch @@ -0,0 +1,135 @@ +From f2a722aa30a29709bb9b5f60fc6d20a10fe6b4f5 Mon Sep 17 00:00:00 2001 +From: Mingli Yu +Date: Wed, 28 Jun 2023 17:58:52 +0800 +Subject: [PATCH] simd.inc.src: Change NPY_INLINE to inline +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Fixes: + | numpy/core/src/umath/simd.inc.src:977:20: note: called from here + | 977 | @vtype@ zeros = _mm512_setzero_@vsuffix@(); + |^~~ + | numpy/core/src/umath/simd.inc.src:596:1: error: inlining failed in call to ‘always_inline’ ‘avx512_get_full_load_mask_ps’: target specific option mismatch + 596 | avx512_get_full_load_mask_ps(void) + | ^~~~ + | numpy/core/src/umath/simd.inc.src:976:27: note: called from here + 976 | @mask@ load_mask = avx512_get_full_load_mask_@vsuffix@(); + | ^~ + | /usr/lib/gcc/x86_64-redhat-linux/13/include/avx512fintrin.h:6499:1: error: inlining failed in call to ‘always_inline’ ‘_mm512_loadu_si512’: target specific option mismatch + +Upstream-Status: Inappropriate [The file simd.inc.src have been removed in new version as + https://github.com/numpy/numpy/commit/640e85017aa8eac3e9be68b475acf27d623b16b7] + +Signed-off-by: Mingli Yu +--- + numpy/core/src/umath/simd.inc.src | 24 + 1 file changed, 12 insertions(+), 12 deletions(-) + +diff --git a/numpy/core/src/umath/simd.inc.src b/numpy/core/src/umath/simd.inc.src +index d6c9a7e..39aec9a 100644 +--- a/numpy/core/src/umath/simd.inc.src b/numpy/core/src/umath/simd.inc.src +@@ -61,11 +61,11 @@ + */ + + #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS +-static NPY_INLINE NPY_GCC_TARGET_AVX512F void ++static inline NPY_GCC_TARGET_AVX512F void + AVX512F_@func@_@TYPE@(@type@*, @type@*, const npy_intp n, const npy_intp stride); + #endif + +-static NPY_INLINE int ++static inline int + run_unary_avx512f_@func@_@TYPE@(char **args, const npy_intp *dimensions, const npy_intp *steps) + { + #if defined HAVE_ATTRIBUTE_TARGET_AVX512F_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS +@@ -99,11 +99,11 @@ run_unary_avx512f_@func@_@TYPE@(char **args, const npy_intp *dimensions, const n + */ + + #if defined HAVE_ATTRIBUTE_TARGET_AVX512_SKX_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS && @EXISTS@ +-static NPY_INLINE NPY_GCC_TARGET_AVX512_SKX void ++static inline NPY_GCC_TARGET_AVX512_SKX void + AVX512_SKX_@func@_@TYPE@(npy_bool*, @type@*, const npy_intp n, const npy_intp stride); + #endif + +-static NPY_INLINE int ++static inline int + run_@func@_avx512_skx_@TYPE@(char **args, npy_intp const *dimensions, npy_intp const *steps) + { + #if defined HAVE_ATTRIBUTE_TARGET_AVX512_SKX_WITH_INTRINSICS && defined NPY_HAVE_SSE2_INTRINSICS && @EXISTS@ +@@ -144,7 +144,7 @@ sse2_@func@_@TYPE@(@type@ *, @type@ *, const npy_intp n); + + #endif + +-static NPY_INLINE int ++static inline int + run_@name@_simd_@func@_@TYPE@(char **args, npy_intp const *dimensions, npy_intp const
Re: [OE-core] [PATCH] qemu: Install the default qemu emulation rpm
Please ignore this patch and use the patch "qemu: Add qemu-common package" instead. And the patch "qemu: Add qemu-common package" fix the backward compatibility as https://patchwork.yoctoproject.org/project/oe-core/patch/20230627105627.2583973-1-mingli...@eng.windriver.com/. Thanks, On 6/15/23 16:17, Yu, Mingli wrote: From: Mingli Yu The qemu rpm can be split or not via customize PACKAGESPLITFUNCS and there is no specific qemu emulation rpm installed when we choose split the qemu rpms now. To gurantee the basic usage, install the qemu emulation rpm which corresponding to the target arch by default when split the qemu rpm. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 7d39f0a25d..c9df43a5a2 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -248,6 +248,9 @@ python split_qemu_packages () { mipspackage = d.getVar('PN') + "-user-mips" if mipspackage in ' '.join(userpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') + +targetarch = "${@'i386' if d.getVar('TARGET_ARCH') in ['x86', 'i486', 'i586', 'i686'] else d.getVar('TARGET_ARCH').replace('_', '-')}" +d.appendVar('RRECOMMENDS:' + d.getVar('PN'), ' ' + d.getVar('PN') + '-user-' + targetarch + ' ' + d.getVar('PN') + '-system-' + targetarch) } # Put the guest agent in a separate package -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#183604): https://lists.openembedded.org/g/openembedded-core/message/183604 Mute This Topic: https://lists.openembedded.org/mt/99544571/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] qemu: Add qemu-common package
From: Mingli Yu We split the qemu package [1] to add support to make user can install one qemu arch emulation rpm to ease the concerns who care much about the rpm size in embedded device. But for the user who only install the qemu-*.rpm can't do anything except they install the qemu emulation rpm like qemu-system-x86-64-*.rpm explicitly. So add qemu-common package to package all thing into qemu-common when not split the package, and package only the basic into qemu-common and other arch related to each qemu arch emulation rpm when split the package to fix the backward compatibility. qenu-*.rpm which is meta package rdepends on qemu-common and the available qemu arch emulation rpm like qemu-system-x86-64-*.rpm and etc. [1] https://git.openembedded.org/openembedded-core/commit/?id=893846ead7ee54d53e9076150cd655e0c8bca5db Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 23 --- meta/recipes-devtools/qemu/qemu_8.0.0.bb | 2 +- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a5bdeef66d..9f8bba4785 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -226,15 +226,18 @@ PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," PACKAGECONFIG[debuginfo] = "--enable-libdw,--disable-libdw,elfutils" -INSANE_SKIP:${PN} = "arch" +INSANE_SKIP:${PN}-common = "arch" FILES:${PN} += "${datadir}/icons" # For user who want to install all arch packages -PACKAGES =+ "${PN}-system-all ${PN}-user-all" +PACKAGES =+ "${PN}-common" +RDEPENDS:${PN} += "${PN}-common" -ALLOW_EMPTY:${PN}-system-all = "1" -ALLOW_EMPTY:${PN}-user-all = "1" +ALLOW_EMPTY:${PN} = "1" +FILES:${PN} = "" + +FILES:${PN}-common = "/usr/* /var" PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" @@ -242,15 +245,13 @@ PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { archdir = d.expand('${bindir}/') -syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) -if syspackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) +subpackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') -userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) -if userpackages: -d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +subpackages += do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True, extra_depends='${PN}-common') +if subpackages: +d.appendVar('RDEPENDS:' + d.getVar('PN'), ' ' + ' '.join(subpackages)) mipspackage = d.getVar('PN') + "-user-mips" -if mipspackage in ' '.join(userpackages): +if mipspackage in ' '.join(subpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') } diff --git a/meta/recipes-devtools/qemu/qemu_8.0.0.bb b/meta/recipes-devtools/qemu/qemu_8.0.0.bb index 42e133967e..5d3c47c3b0 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.0.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.0.bb @@ -8,7 +8,7 @@ DEPENDS:append:libc-musl = " libucontext" CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}" -RDEPENDS:${PN}:class-target += "bash" +RDEPENDS:${PN}-common:class-target += "bash" EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#183484): https://lists.openembedded.org/g/openembedded-core/message/183484 Mute This Topic: https://lists.openembedded.org/mt/99806906/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] qemu: Install the default qemu emulation rpm
Ping. Thanks, On 6/15/23 16:17, Yu, Mingli wrote: From: Mingli Yu The qemu rpm can be split or not via customize PACKAGESPLITFUNCS and there is no specific qemu emulation rpm installed when we choose split the qemu rpms now. To gurantee the basic usage, install the qemu emulation rpm which corresponding to the target arch by default when split the qemu rpm. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 7d39f0a25d..c9df43a5a2 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -248,6 +248,9 @@ python split_qemu_packages () { mipspackage = d.getVar('PN') + "-user-mips" if mipspackage in ' '.join(userpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') + +targetarch = "${@'i386' if d.getVar('TARGET_ARCH') in ['x86', 'i486', 'i586', 'i686'] else d.getVar('TARGET_ARCH').replace('_', '-')}" +d.appendVar('RRECOMMENDS:' + d.getVar('PN'), ' ' + d.getVar('PN') + '-user-' + targetarch + ' ' + d.getVar('PN') + '-system-' + targetarch) } # Put the guest agent in a separate package -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#183404): https://lists.openembedded.org/g/openembedded-core/message/183404 Mute This Topic: https://lists.openembedded.org/mt/99544571/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] qemu: Add qemu-user-* and qemu-system-* to PACKAGES_DYNAMIC
From: Mingli Yu Fixes: Add below line to conf/local.conf IMAGE_INSTALL:append = " qemu-system-aarch64" $ bitbake core-image-base ERROR: Required build target 'core-image-base' has no buildable providers. Missing or unbuildable dependency chain was: ['core-image-base', 'qemu-system-aarch64'] Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 6acda61425..a5bdeef66d 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -236,6 +236,8 @@ PACKAGES =+ "${PN}-system-all ${PN}-user-all" ALLOW_EMPTY:${PN}-system-all = "1" ALLOW_EMPTY:${PN}-user-all = "1" +PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" + PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { -- 2.35.5 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#183403): https://lists.openembedded.org/g/openembedded-core/message/183403 Mute This Topic: https://lists.openembedded.org/mt/99782486/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] qemu: Add qemu-user-* and qemu-system-* to PACKAGES_DYNAMIC
From: Mingli Yu Fixes: Add below line to conf/local.conf IMAGE_INSTALL:append = " qemu-system-aarch64 $ bitbake core-image-base ERROR: Required build target 'core-image-base' has no buildable providers. Missing or unbuildable dependency chain was: ['core-image-base', 'qemu-system-aarch64'] Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 6acda61425..a5bdeef66d 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -236,6 +236,8 @@ PACKAGES =+ "${PN}-system-all ${PN}-user-all" ALLOW_EMPTY:${PN}-system-all = "1" ALLOW_EMPTY:${PN}-user-all = "1" +PACKAGES_DYNAMIC += "^${PN}-user-.* ^${PN}-system-.*" + PACKAGESPLITFUNCS =+ "split_qemu_packages" python split_qemu_packages () { -- 2.35.5 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#183402): https://lists.openembedded.org/g/openembedded-core/message/183402 Mute This Topic: https://lists.openembedded.org/mt/99782461/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] u-boot-tools: Use PATH_MAX for path length
From: Mingli Yu Fixes: | uboot-mkimage -D "-I dts -O dtb -p 2000" -F -k "/buildarea1/test/wr_build/wrtestLTS_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/layers/xilinx-zynqmp/zynqmp_keys/fitImage-rsa2048-keys" -K "u-boot.dtb" -r /buildarea1/test/wr_build/wrtestLTS_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/build/tmp-glibc/work/xilinx_zynqmp-wrs-linux/u-boot-xlnx/1_v2023.01-xilinx-v2023.1+gitAUTOINC+40a08d69e7-r0/build/fitImage-linux | /buildarea1/test/wr_build/wrtestLTS_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/build/tmp-glibc/work/xilinx_zynqmp-wrs-linux/u-boot-xlnx/1_v2023.01-xilinx-v2023.1+gitAUTOINC+40a08d69e7-r0/build/fitImage-linux: Image file name (uboot-mkimage) too long, can't create tmpfile. Signed-off-by: Mingli Yu --- ...mkimage-Use-PATH_MAX-for-path-length.patch | 40 +++ .../u-boot/u-boot-tools_2023.04.bb| 4 ++ 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch diff --git a/meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch b/meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch new file mode 100644 index 00..9f38736bcd --- /dev/null +++ b/meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch @@ -0,0 +1,40 @@ +From dcd3d272975863128e25a4e25453cb6521cddc53 Mon Sep 17 00:00:00 2001 +From: Mingli Yu +Date: Wed, 14 Jun 2023 16:09:59 +0800 +Subject: [PATCH] mkimage: Use PATH_MAX for path length + +Fixed when build xilinx_zynqmp in long directory ( >256): + | /buildarea1/testtest/wr_build/wr1023test_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/build/tmp-glibc/work/xilinx_zynqmp-wrs-linux/u-boot-xlnx/1_v2023.01-xilinx-v2023.1+gitAUTOINC+40a08d69e7-r0/build/fitImage-linux: Image file name (uboot-mkimage) too long, can't create tmpfile. + | Error: Bad parameters for FIT image type + +Upstream-Status: Submitted [https://patchwork.ozlabs.org/project/uboot/patch/20230619062250.3244894-1-mingli...@eng.windriver.com/] + +Signed-off-by: Mingli Yu +--- + tools/mkimage.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/tools/mkimage.h b/tools/mkimage.h +index f5ca65e2ed..d92a3ff811 100644 +--- a/tools/mkimage.h b/tools/mkimage.h +@@ -17,6 +17,7 @@ + #include + #include + #include ++#include + #include + #include "fdt_host.h" + #include "imagetool.h" +@@ -44,7 +45,7 @@ static inline ulong map_to_sysmem(void *ptr) + #define ALLOC_CACHE_ALIGN_BUFFER(type, name, size) type name[size] + + #define MKIMAGE_TMPFILE_SUFFIX".tmp" +-#define MKIMAGE_MAX_TMPFILE_LEN 256 ++#define MKIMAGE_MAX_TMPFILE_LEN PATH_MAX + #define MKIMAGE_DEFAULT_DTC_OPTIONS "-I dts -O dtb -p 500" + #define MKIMAGE_MAX_DTC_CMDLINE_LEN 2 * MKIMAGE_MAX_TMPFILE_LEN + 35 + +-- +2.25.1 + diff --git a/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb b/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb index 7eaf721ca8..b77a49af87 100644 --- a/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb +++ b/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb @@ -1,2 +1,6 @@ require u-boot-common.inc require u-boot-tools.inc + +SRC_URI += " \ +file://0001-mkimage-Use-PATH_MAX-for-path-length.patch \ +" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#183129): https://lists.openembedded.org/g/openembedded-core/message/183129 Mute This Topic: https://lists.openembedded.org/mt/99637403/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] u-boot-tools: u-boot-tools: Use PATH_MAX for path length
From: Mingli Yu Fixes: | uboot-mkimage -D "-I dts -O dtb -p 2000" -F -k "/buildarea1/test/wr_build/wrtestLTS_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/layers/xilinx-zynqmp/zynqmp_keys/fitImage-rsa2048-keys" -K "u-boot.dtb" -r /buildarea1/test/wr_build/wrtestLTS_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/build/tmp-glibc/work/xilinx_zynqmp-wrs-linux/u-boot-xlnx/1_v2023.01-xilinx-v2023.1+gitAUTOINC+40a08d69e7-r0/build/fitImage-linux | /buildarea1/test/wr_build/wrtestLTS_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/build/tmp-glibc/work/xilinx_zynqmp-wrs-linux/u-boot-xlnx/1_v2023.01-xilinx-v2023.1+gitAUTOINC+40a08d69e7-r0/build/fitImage-linux: Image file name (uboot-mkimage) too long, can't create tmpfile. Signed-off-by: Mingli Yu --- ...mkimage-Use-PATH_MAX-for-path-length.patch | 40 +++ .../u-boot/u-boot-tools_2023.04.bb| 4 ++ 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch diff --git a/meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch b/meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch new file mode 100644 index 00..9f38736bcd --- /dev/null +++ b/meta/recipes-bsp/u-boot/files/0001-mkimage-Use-PATH_MAX-for-path-length.patch @@ -0,0 +1,40 @@ +From dcd3d272975863128e25a4e25453cb6521cddc53 Mon Sep 17 00:00:00 2001 +From: Mingli Yu +Date: Wed, 14 Jun 2023 16:09:59 +0800 +Subject: [PATCH] mkimage: Use PATH_MAX for path length + +Fixed when build xilinx_zynqmp in long directory ( >256): + | /buildarea1/testtest/wr_build/wr1023test_secureboot/test1-what/test2-what/test3-what/test4-what/test5-what/test6-what/test7-what/test8-what/test9-what/test10-what/test11-what/test12-what/build/tmp-glibc/work/xilinx_zynqmp-wrs-linux/u-boot-xlnx/1_v2023.01-xilinx-v2023.1+gitAUTOINC+40a08d69e7-r0/build/fitImage-linux: Image file name (uboot-mkimage) too long, can't create tmpfile. + | Error: Bad parameters for FIT image type + +Upstream-Status: Submitted [https://patchwork.ozlabs.org/project/uboot/patch/20230619062250.3244894-1-mingli...@eng.windriver.com/] + +Signed-off-by: Mingli Yu +--- + tools/mkimage.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/tools/mkimage.h b/tools/mkimage.h +index f5ca65e2ed..d92a3ff811 100644 +--- a/tools/mkimage.h b/tools/mkimage.h +@@ -17,6 +17,7 @@ + #include + #include + #include ++#include + #include + #include "fdt_host.h" + #include "imagetool.h" +@@ -44,7 +45,7 @@ static inline ulong map_to_sysmem(void *ptr) + #define ALLOC_CACHE_ALIGN_BUFFER(type, name, size) type name[size] + + #define MKIMAGE_TMPFILE_SUFFIX".tmp" +-#define MKIMAGE_MAX_TMPFILE_LEN 256 ++#define MKIMAGE_MAX_TMPFILE_LEN PATH_MAX + #define MKIMAGE_DEFAULT_DTC_OPTIONS "-I dts -O dtb -p 500" + #define MKIMAGE_MAX_DTC_CMDLINE_LEN 2 * MKIMAGE_MAX_TMPFILE_LEN + 35 + +-- +2.25.1 + diff --git a/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb b/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb index 7eaf721ca8..b77a49af87 100644 --- a/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb +++ b/meta/recipes-bsp/u-boot/u-boot-tools_2023.04.bb @@ -1,2 +1,6 @@ require u-boot-common.inc require u-boot-tools.inc + +SRC_URI += " \ +file://0001-mkimage-Use-PATH_MAX-for-path-length.patch \ +" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#183128): https://lists.openembedded.org/g/openembedded-core/message/183128 Mute This Topic: https://lists.openembedded.org/mt/99637342/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] qemu: Install the default qemu emulation rpm
From: Mingli Yu The qemu rpm can be split or not via customize PACKAGESPLITFUNCS and there is no specific qemu emulation rpm installed when we choose split the qemu rpms now. To gurantee the basic usage, install the qemu emulation rpm which corresponding to the target arch by default when split the qemu rpm. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index 7d39f0a25d..c9df43a5a2 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -248,6 +248,9 @@ python split_qemu_packages () { mipspackage = d.getVar('PN') + "-user-mips" if mipspackage in ' '.join(userpackages): d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') + +targetarch = "${@'i386' if d.getVar('TARGET_ARCH') in ['x86', 'i486', 'i586', 'i686'] else d.getVar('TARGET_ARCH').replace('_', '-')}" +d.appendVar('RRECOMMENDS:' + d.getVar('PN'), ' ' + d.getVar('PN') + '-user-' + targetarch + ' ' + d.getVar('PN') + '-system-' + targetarch) } # Put the guest agent in a separate package -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182837): https://lists.openembedded.org/g/openembedded-core/message/182837 Mute This Topic: https://lists.openembedded.org/mt/99544571/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] curl: Fix CVEs
From: Mingli Yu Backport patches to fix the below CVEs: CVE-2023-28319 CVE-2023-28320 CVE-2023-28321 CVE-2023-28322 Signed-off-by: Mingli Yu --- .../curl/curl/CVE-2023-28319.patch| 38 ++ .../curl/curl/CVE-2023-28320.patch| 88 .../curl/curl/CVE-2023-28321.patch| 111 + .../curl/curl/CVE-2023-28322.patch| 441 ++ meta/recipes-support/curl/curl_8.0.1.bb | 4 + 5 files changed, 682 insertions(+) create mode 100644 meta/recipes-support/curl/curl/CVE-2023-28319.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-28320.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-28321.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-28322.patch diff --git a/meta/recipes-support/curl/curl/CVE-2023-28319.patch b/meta/recipes-support/curl/curl/CVE-2023-28319.patch new file mode 100644 index 00..c843a18174 --- /dev/null +++ b/meta/recipes-support/curl/curl/CVE-2023-28319.patch @@ -0,0 +1,38 @@ +From 8e21b1a05f3c0ee098dbcb6c3d84cb61f102a122 Mon Sep 17 00:00:00 2001 +From: Daniel Stenberg +Date: Mon, 8 May 2023 14:33:54 +0200 +Subject: [PATCH] libssh2: free fingerprint better + +Reported-by: Wei Chong Tan +Closes #11088 + +CVE: CVE-2023-28319 + +Upstream-Status: Backport [https://github.com/curl/curl/commit/8e21b1a05f3c0ee098dbcb6c] + +Signed-off-by: Mingli Yu + +--- + lib/vssh/libssh2.c | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +diff --git a/lib/vssh/libssh2.c b/lib/vssh/libssh2.c +index bfcc94e16..dd39a844c 100644 +--- a/lib/vssh/libssh2.c b/lib/vssh/libssh2.c +@@ -728,11 +728,10 @@ static CURLcode ssh_check_fingerprint(struct Curl_easy *data) + */ + if((pub_pos != b64_pos) || +strncmp(fingerprint_b64, pubkey_sha256, pub_pos)) { +- free(fingerprint_b64); +- + failf(data, + "Denied establishing ssh session: mismatch sha256 fingerprint. " + "Remote %s is not equal to %s", fingerprint_b64, pubkey_sha256); ++ free(fingerprint_b64); + state(data, SSH_SESSION_FREE); + sshc->actualcode = CURLE_PEER_FAILED_VERIFICATION; + return sshc->actualcode; +-- +2.25.1 + diff --git a/meta/recipes-support/curl/curl/CVE-2023-28320.patch b/meta/recipes-support/curl/curl/CVE-2023-28320.patch new file mode 100644 index 00..c7cfd6a42f --- /dev/null +++ b/meta/recipes-support/curl/curl/CVE-2023-28320.patch @@ -0,0 +1,88 @@ +From 13718030ad4b3209a7583b4f27f683cd3a6fa5f2 Mon Sep 17 00:00:00 2001 +From: Harry Sintonen +Date: Tue, 25 Apr 2023 09:22:26 +0200 +Subject: [PATCH] hostip: add locks around use of global buffer for alarm() + +When building with the sync name resolver and timeout ability we now +require thread-safety to be present to enable it. + +Closes #11030 + +CVE: CVE-2023-28320 + +Upstream-Status: Backport [https://github.com/curl/curl/commit/13718030ad4b3209a7583b] + +Signed-off-by: Mingli Yu +--- + lib/hostip.c | 19 +++ + 1 file changed, 15 insertions(+), 4 deletions(-) + +diff --git a/lib/hostip.c b/lib/hostip.c +index 2381290fd..e410cda69 100644 +--- a/lib/hostip.c b/lib/hostip.c +@@ -70,12 +70,19 @@ + #include + #endif + +-#if defined(CURLRES_SYNCH) && \ +-defined(HAVE_ALARM) && defined(SIGALRM) && defined(HAVE_SIGSETJMP) ++#if defined(CURLRES_SYNCH) && \ ++ defined(HAVE_ALARM) &&\ ++ defined(SIGALRM) && \ ++ defined(HAVE_SIGSETJMP) &&\ ++ defined(GLOBAL_INIT_IS_THREADSAFE) + /* alarm-based timeouts can only be used with all the dependencies satisfied */ + #define USE_ALARM_TIMEOUT + #endif + ++#ifdef USE_ALARM_TIMEOUT ++#include "easy_lock.h" ++#endif ++ + #define MAX_HOSTCACHE_LEN (255 + 7) /* max FQDN + colon + port number + zero */ + + /* +@@ -254,11 +261,12 @@ void Curl_hostcache_prune(struct Curl_easy *data) + Curl_share_unlock(data, CURL_LOCK_DATA_DNS); + } + +-#ifdef HAVE_SIGSETJMP ++#ifdef USE_ALARM_TIMEOUT + /* Beware this is a global and unique instance. This is used to store the +return address that we can jump back to from inside a signal handler. This +is not thread-safe stuff. */ + sigjmp_buf curl_jmpenv; ++curl_simple_lock curl_jmpenv_lock; + #endif + + /* lookup address, returns entry if found and not stale */ +@@ -832,7 +840,6 @@ enum resolve_t Curl_resolv(struct Curl_easy *data, + static + void alarmfunc(int sig) + { +- /* this is for "-ansi -Wall -pedantic" to stop complaining! (rabe) */ + (void)sig; + siglongjmp(curl_jmpenv, 1); + } +@@ -912,6 +919,8 @@ enum resolve_t Curl_resolv_timeout(struct Curl_easy *data, + This should be the last thing we do before calling Curl_resolv(), + as otherwise we'd have to worry about variables that get modified + before we invoke Curl_resolv() (and thus use "volatile"). */ ++ curl_simple_lock_lock(_jmpenv_lock); ++ + if(sigsetjmp(curl_jmpenv, 1)) { + /*
Re: [OE-core] [PATCH v5] qemu: Split the qemu package
Okay, let us use v6 to track the patch. Thanks, From: Bruce Ashfield Sent: Friday, June 9, 2023 11:25 To: Yu, Mingli Cc: Richard Purdie ; openembedded-core@lists.openembedded.org Subject: Re: [OE-core] [PATCH v5] qemu: Split the qemu package CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Thu, Jun 8, 2023 at 10:01 PM Yu, Mingli mailto:mingli...@windriver.com>> wrote: Hi Bruce, I didn't reply the v1 patch directly and just include the comments and concerns when generate v2,v3,v4,v5 patch. I'm sorry the overrides for qemu split in meta-vir as https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc doesn't work if we make the qemu split change.<https://urldefense.com/v3/__https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc__;!!AjveYdw8EvQ!byty5y3CfmOOKUh8G_uYgU2QxFCl4KCFb-yjmzYuSrjQJ4NXaglf6vZ6IWtmyrHhPs4okTIp4TpusD8e4h8-YLvToqA$> <https://urldefense.com/v3/__https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc__;!!AjveYdw8EvQ!byty5y3CfmOOKUh8G_uYgU2QxFCl4KCFb-yjmzYuSrjQJ4NXaglf6vZ6IWtmyrHhPs4okTIp4TpusD8e4h8-YLvToqA$> Is it okay for you to install the qemu arch rpms you need or qemu-all(if you want all qemu binary) after the qemu split change?<https://urldefense.com/v3/__https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc__;!!AjveYdw8EvQ!byty5y3CfmOOKUh8G_uYgU2QxFCl4KCFb-yjmzYuSrjQJ4NXaglf6vZ6IWtmyrHhPs4okTIp4TpusD8e4h8-YLvToqA$> It actually isn't that. I want a different split of the packages. But I see your v6 is using the function variable, so I'll be able to remove it from processing and restore my existing package splits. Bruce <https://urldefense.com/v3/__https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc__;!!AjveYdw8EvQ!byty5y3CfmOOKUh8G_uYgU2QxFCl4KCFb-yjmzYuSrjQJ4NXaglf6vZ6IWtmyrHhPs4okTIp4TpusD8e4h8-YLvToqA$> Thanks, From: Bruce Ashfield mailto:bruce.ashfi...@gmail.com>> Sent: Friday, June 9, 2023 00:16 To: Richard Purdie mailto:richard.pur...@linuxfoundation.org>> Cc: Yu, Mingli mailto:mingli...@windriver.com>>; openembedded-core@lists.openembedded.org<mailto:openembedded-core@lists.openembedded.org> mailto:openembedded-core@lists.openembedded.org>> Subject: Re: [OE-core] [PATCH v5] qemu: Split the qemu package CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Thu, Jun 8, 2023 at 11:44 AM Richard Purdie mailto:richard.pur...@linuxfoundation.org>> wrote: On Thu, 2023-06-08 at 11:03 -0400, Bruce Ashfield wrote: > > > On Thu, Jun 8, 2023 at 9:55 AM Richard Purdie > mailto:richard.pur...@linuxfoundation.org>> > wrote: > > On Thu, 2023-06-08 at 09:33 -0400, Bruce Ashfield wrote: > > > At this point, you can probably see why I ended up using the > > > explicit > > > variables and overrides versus python when doing the > > > meta-virtualization splits. :) > > > > > > I have a few more comments that I made in v1, that I haven't seen > > > directly handled or replied to. > > > > > > My only remaining concern (and it may just be my own concern), is > > > that > > > there's no way to change this packaging split. Either you take > > > the > > > programatic split, or you take the -all packages. > > > > > > Other packages (glibc, kernel-modules) have a variable that > > > controls > > > whether the split happens or not, I'd like to see something > > > similar > > > here .. but I do realize that it makes test complexity more, and > > > that > > > Richard normally doesn't like conditionals like that. > > > > I only "like" conditionals if it is a code path that will be well > > travelled, otherwise we tend to find one of the paths is broken. I > > don't think we need to make this conditional. > > > > > Alternatively, did we rule out using PACKAGESPLITFUNCS to add the > > > splitting routine ? With that, we could remove the processing in > > > places we don't want it, in particular for the native/sdk builds, > > > as I > > > found that we really don't want the splitting of qemu in those > > > scenarios. > > > > > Can you think of a problem with the PACKAGESPLITFUNCS method for this > packaging split ? > > At least that way I could inhibit it from my oth
[OE-core] [PATCH v6] qemu: Split the qemu package
From: Mingli Yu Currently all files as below packaged into one package such as qemu-7.2.0-*.rpm. After the qemu package installed on the target, it will take up about 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. # ls tmp-glibc/work/core2-64-wrs-linux/qemu/7.2.0-r0/image/usr/bin/ qemu-aarch64 qemu-img qemu-mips64el qemu-ppc64 qemu-sh4qemu-system-loongarch64 qemu-system-ppc qemu-system-x86_64 qemu-arm qemu-io qemu-mipsel qemu-ppc64le qemu-storage-daemon qemu-system-mips qemu-system-ppc64 qemu-x86_64 qemu-edid qemu-loongarch64 qemu-mips.real qemu-pr-helper qemu-system-aarch64 qemu-system-mips64 qemu-system-riscv32 qemu-ga qemu-mips qemu-nbd qemu-riscv32qemu-system-arm qemu-system-mips64el qemu-system-riscv64 qemu-i386 qemu-mips64 qemu-ppc qemu-riscv64qemu-system-i386 qemu-system-mipsel qemu-system-sh4 Split the qemu package into qemu-7.2.0-*.rpm, qemu-system-*.rpm, qemu-user-*.rpm and etc. And let user can only choose the corresponding qemu arch package they want to install should ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm (qemu-7.2.0*.rpm) size from about 65M to about 19M and the size of the extracted qemu RPM decreased from about 464M to about 248M. For the users who want to install all arch packages, they can install qemu-system-all and qemu-user-all to meet their need. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 22 ++ 1 file changed, 22 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a87dee5c99..6acda61425 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -230,6 +230,28 @@ INSANE_SKIP:${PN} = "arch" FILES:${PN} += "${datadir}/icons" +# For user who want to install all arch packages +PACKAGES =+ "${PN}-system-all ${PN}-user-all" + +ALLOW_EMPTY:${PN}-system-all = "1" +ALLOW_EMPTY:${PN}-user-all = "1" + +PACKAGESPLITFUNCS =+ "split_qemu_packages" + +python split_qemu_packages () { +archdir = d.expand('${bindir}/') +syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) +if syspackages: +d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) + +userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) +if userpackages: +d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +mipspackage = d.getVar('PN') + "-user-mips" +if mipspackage in ' '.join(userpackages): +d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') +} + # Put the guest agent in a separate package PACKAGES =+ "${PN}-guest-agent" SUMMARY:${PN}-guest-agent = "QEMU guest agent" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182526): https://lists.openembedded.org/g/openembedded-core/message/182526 Mute This Topic: https://lists.openembedded.org/mt/99421260/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 v5] qemu: Split the qemu package
Hi Bruce, I didn't reply the v1 patch directly and just include the comments and concerns when generate v2,v3,v4,v5 patch. I'm sorry the overrides for qemu split in meta-vir as https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc doesn't work if we make the qemu split change.<https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc> <https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc> Is it okay for you to install the qemu arch rpms you need or qemu-all(if you want all qemu binary) after the qemu split change? <https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc> Thanks, From: Bruce Ashfield Sent: Friday, June 9, 2023 00:16 To: Richard Purdie Cc: Yu, Mingli ; openembedded-core@lists.openembedded.org Subject: Re: [OE-core] [PATCH v5] qemu: Split the qemu package CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Thu, Jun 8, 2023 at 11:44 AM Richard Purdie mailto:richard.pur...@linuxfoundation.org>> wrote: On Thu, 2023-06-08 at 11:03 -0400, Bruce Ashfield wrote: > > > On Thu, Jun 8, 2023 at 9:55 AM Richard Purdie > mailto:richard.pur...@linuxfoundation.org>> > wrote: > > On Thu, 2023-06-08 at 09:33 -0400, Bruce Ashfield wrote: > > > At this point, you can probably see why I ended up using the > > > explicit > > > variables and overrides versus python when doing the > > > meta-virtualization splits. :) > > > > > > I have a few more comments that I made in v1, that I haven't seen > > > directly handled or replied to. > > > > > > My only remaining concern (and it may just be my own concern), is > > > that > > > there's no way to change this packaging split. Either you take > > > the > > > programatic split, or you take the -all packages. > > > > > > Other packages (glibc, kernel-modules) have a variable that > > > controls > > > whether the split happens or not, I'd like to see something > > > similar > > > here .. but I do realize that it makes test complexity more, and > > > that > > > Richard normally doesn't like conditionals like that. > > > > I only "like" conditionals if it is a code path that will be well > > travelled, otherwise we tend to find one of the paths is broken. I > > don't think we need to make this conditional. > > > > > Alternatively, did we rule out using PACKAGESPLITFUNCS to add the > > > splitting routine ? With that, we could remove the processing in > > > places we don't want it, in particular for the native/sdk builds, > > > as I > > > found that we really don't want the splitting of qemu in those > > > scenarios. > > > > > Can you think of a problem with the PACKAGESPLITFUNCS method for this > packaging split ? > > At least that way I could inhibit it from my other layers, versus > with this prepend, I don't see any options to have my own package > splitting. We can do this in a PACKAGESPLITFUNCS function. I guess I'm just nervous of having too many different ways of packaging qemu as I was hoping we could get something which would work for all users. There are some very specific use cases for virtualization, where some separation models use different architectures for devices, even architectures that don't match the target (host in the running system). There are also some combinations of usermode and system, as well as support and firmware, etc. I can't see a clean/easy way to make the split being proposed here serve all those existing (and admittedly odd) case. Having a way to override it (even temporarily) is a better transition path for meta-virt. Bruce Cheers, Richard -- - 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 (#182524): https://lists.openembedded.org/g/openembedded-core/message/182524 Mute This Topic: https://lists.openembedded.org/mt/99401176/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 2/2] curl: Update from 8.1.0 to 8.1.1
From: Robert Joslyn This is a bugfix only release. Release notes: https://curl.se/changes.html#8_1_1 Signed-off-by: Robert Joslyn Signed-off-by: Richard Purdie Signed-off-by: Mingli Yu --- meta/recipes-support/curl/{curl_8.1.0.bb => curl_8.1.1.bb} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename meta/recipes-support/curl/{curl_8.1.0.bb => curl_8.1.1.bb} (98%) diff --git a/meta/recipes-support/curl/curl_8.1.0.bb b/meta/recipes-support/curl/curl_8.1.1.bb similarity index 98% rename from meta/recipes-support/curl/curl_8.1.0.bb rename to meta/recipes-support/curl/curl_8.1.1.bb index 0efd0de5c2..89ab61fc59 100644 --- a/meta/recipes-support/curl/curl_8.1.0.bb +++ b/meta/recipes-support/curl/curl_8.1.1.bb @@ -14,7 +14,7 @@ SRC_URI = " \ file://run-ptest \ file://disable-tests \ " -SRC_URI[sha256sum] = "6bd80ad4f07187015911216ee7185b90d285ac5162aed1bded144f9f93232a3c" +SRC_URI[sha256sum] = "08a948e061929645597c1ef7194e07b308b22084ff03fa7400b465e6c05149e5" # Curl has used many names over the years... CVE_PRODUCT = "haxx:curl haxx:libcurl curl:curl curl:libcurl libcurl:libcurl daniel_stenberg:curl" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182496): https://lists.openembedded.org/g/openembedded-core/message/182496 Mute This Topic: https://lists.openembedded.org/mt/99401643/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 1/2] curl: Update from 8.0.1 to 8.1.0
From: Robert Joslyn This is a feature and bugfix release. Release notes are available at: https://curl.se/changes.html#8_1_0 Signed-off-by: Robert Joslyn Signed-off-by: Alexandre Belloni Signed-off-by: Mingli Yu --- meta/recipes-support/curl/{curl_8.0.1.bb => curl_8.1.0.bb} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename meta/recipes-support/curl/{curl_8.0.1.bb => curl_8.1.0.bb} (98%) diff --git a/meta/recipes-support/curl/curl_8.0.1.bb b/meta/recipes-support/curl/curl_8.1.0.bb similarity index 98% rename from meta/recipes-support/curl/curl_8.0.1.bb rename to meta/recipes-support/curl/curl_8.1.0.bb index 5cf044615f..0efd0de5c2 100644 --- a/meta/recipes-support/curl/curl_8.0.1.bb +++ b/meta/recipes-support/curl/curl_8.1.0.bb @@ -14,7 +14,7 @@ SRC_URI = " \ file://run-ptest \ file://disable-tests \ " -SRC_URI[sha256sum] = "0a381cd82f4d00a9a334438b8ca239afea5bfefcfa9a1025f2bf118e79e0b5f0" +SRC_URI[sha256sum] = "6bd80ad4f07187015911216ee7185b90d285ac5162aed1bded144f9f93232a3c" # Curl has used many names over the years... CVE_PRODUCT = "haxx:curl haxx:libcurl curl:curl curl:libcurl libcurl:libcurl daniel_stenberg:curl" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182495): https://lists.openembedded.org/g/openembedded-core/message/182495 Mute This Topic: https://lists.openembedded.org/mt/99401642/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 v5] qemu: Split the qemu package
From: Mingli Yu Currently all files as below packaged into one package such as qemu-7.2.0-*.rpm. After the qemu package installed on the target, it will take up about 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. # ls tmp-glibc/work/core2-64-wrs-linux/qemu/7.2.0-r0/image/usr/bin/ qemu-aarch64 qemu-img qemu-mips64el qemu-ppc64 qemu-sh4qemu-system-loongarch64 qemu-system-ppc qemu-system-x86_64 qemu-arm qemu-io qemu-mipsel qemu-ppc64le qemu-storage-daemon qemu-system-mips qemu-system-ppc64 qemu-x86_64 qemu-edid qemu-loongarch64 qemu-mips.real qemu-pr-helper qemu-system-aarch64 qemu-system-mips64 qemu-system-riscv32 qemu-ga qemu-mips qemu-nbd qemu-riscv32qemu-system-arm qemu-system-mips64el qemu-system-riscv64 qemu-i386 qemu-mips64 qemu-ppc qemu-riscv64qemu-system-i386 qemu-system-mipsel qemu-system-sh4 Split the qemu package into qemu-7.2.0-*.rpm, qemu-system-*.rpm, qemu-user-*.rpm and etc. And let user can only choose the corresponding qemu arch package they want to install should ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm (qemu-7.2.0*.rpm) size from about 65M to about 13M and the size of the extracted qemu RPM decreased from about 464M to about 230M. For the users who want to install all arch packages, they can install qemu-system-all and qemu-user-all to meet their need. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 20 1 file changed, 20 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a87dee5c99..367b924f9c 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -230,6 +230,26 @@ INSANE_SKIP:${PN} = "arch" FILES:${PN} += "${datadir}/icons" +# For user who want to install all arch packages +PACKAGES =+ "${PN}-system-all ${PN}-user-all" + +ALLOW_EMPTY:${PN}-system-all = "1" +ALLOW_EMPTY:${PN}-user-all = "1" + +python populate_packages:prepend() { +archdir = d.expand('${bindir}/') +syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) +if syspackages: +d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) + +userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) +if userpackages: +d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +mipspackage = d.getVar('PN') + "-user-mips" +if mipspackage in ' '.join(userpackages): +d.appendVar('RDEPENDS:' + mipspackage, ' ' + d.getVar("MLPREFIX") + 'bash') +} + # Put the guest agent in a separate package PACKAGES =+ "${PN}-guest-agent" SUMMARY:${PN}-guest-agent = "QEMU guest agent" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182494): https://lists.openembedded.org/g/openembedded-core/message/182494 Mute This Topic: https://lists.openembedded.org/mt/99401176/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 v4] qemu: Split the qemu package
From: Mingli Yu Currently all files as below packaged into one package such as qemu-7.2.0-*.rpm. After the qemu package installed on the target, it will take up about 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. # ls tmp-glibc/work/core2-64-wrs-linux/qemu/7.2.0-r0/image/usr/bin/ qemu-aarch64 qemu-img qemu-mips64el qemu-ppc64 qemu-sh4qemu-system-loongarch64 qemu-system-ppc qemu-system-x86_64 qemu-arm qemu-io qemu-mipsel qemu-ppc64le qemu-storage-daemon qemu-system-mips qemu-system-ppc64 qemu-x86_64 qemu-edid qemu-loongarch64 qemu-mips.real qemu-pr-helper qemu-system-aarch64 qemu-system-mips64 qemu-system-riscv32 qemu-ga qemu-mips qemu-nbd qemu-riscv32qemu-system-arm qemu-system-mips64el qemu-system-riscv64 qemu-i386 qemu-mips64 qemu-ppc qemu-riscv64qemu-system-i386 qemu-system-mipsel qemu-system-sh4 Split the qemu package into qemu-7.2.0-*.rpm, qemu-system-*.rpm, qemu-user-*.rpm and etc. And let user can only choose the corresponding qemu arch package they want to install should ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm (qemu-7.2.0*.rpm) size from about 65M to about 19M and the size of the extracted qemu RPM decreased from about 464M to about 248M. For the users who want to install all arch packages, they can install qemu-system-all and qemu-user-all to meet their need. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 19 +++ 1 file changed, 19 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a87dee5c99..108dd0947a 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -230,6 +230,25 @@ INSANE_SKIP:${PN} = "arch" FILES:${PN} += "${datadir}/icons" +# For user who want to install all arch packages +PACKAGES =+ "${PN}-system-all ${PN}-user-all" + +ALLOW_EMPTY:${PN}-system-all = "1" +ALLOW_EMPTY:${PN}-user-all = "1" + +python populate_packages:prepend() { +archdir = d.expand('${bindir}/') +syspackages = do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) +if syspackages: +d.setVar('RDEPENDS:' + d.getVar('PN') + '-system-all', ' '.join(syspackages)) + +userpackages = do_split_packages(d, archdir, r'^qemu-((?!system|edid|ga|img|io|nbd|pr-helper|storage-daemon).*)$', '${PN}-user-%s', 'QEMU full user emulation binaries(%s)' , prepend=True) +if "qemu-user-mips" in ' '.join(userpackages): +d.appendVar('RDEPENDS:qemu-user-mips', ' '+ 'bash') +if userpackages: +d.setVar('RDEPENDS:' + d.getVar('PN') + '-user-all', ' '.join(userpackages)) +} + # Put the guest agent in a separate package PACKAGES =+ "${PN}-guest-agent" SUMMARY:${PN}-guest-agent = "QEMU guest agent" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182464): https://lists.openembedded.org/g/openembedded-core/message/182464 Mute This Topic: https://lists.openembedded.org/mt/99380658/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 v3] qemu: Split the qemu package
Hi Richard and Bruce, On 6/2/23 21:19, Richard Purdie wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Fri, 2023-06-02 at 09:08 -0400, Bruce Ashfield wrote: On Thu, Jun 1, 2023 at 10:37 PM Yu, Mingli wrote: From: Mingli Yu Currently all files as below packaged into one package such as qemu-7.2.0-*.rpm. After the qemu package installed on the target, it will take up about 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. # ls tmp-glibc/work/core2-64-wrs-linux/qemu/7.2.0-r0/image/usr/bin/ qemu-aarch64 qemu-img qemu-mips64el qemu-ppc64 qemu-sh4qemu-system-loongarch64 qemu-system-ppc qemu-system-x86_64 qemu-arm qemu-io qemu-mipsel qemu-ppc64le qemu-storage-daemon qemu-system-mips qemu-system-ppc64 qemu-x86_64 qemu-edid qemu-loongarch64 qemu-mips.real qemu-pr-helper qemu-system-aarch64 qemu-system-mips64 qemu-system-riscv32 qemu-ga qemu-mips qemu-nbd qemu-riscv32qemu-system-arm qemu-system-mips64el qemu-system-riscv64 qemu-i386 qemu-mips64 qemu-ppc qemu-riscv64qemu-system-i386 qemu-system-mipsel qemu-system-sh4 Split the qemu package into qemu-7.2.0-*.rpm, qemu-system-aarch64-7.2.0*.rpm, qemu-system-x86_64-7.2.0*.rpm and etc. And let user can only choose the corresponding qemu arch package they want to install should ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm (qemu-7.2.0*.rpm) size from about 65M to about 19M and the size of the extracted qemu RPM decreased from about 464M to about 248M. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 5 + 1 file changed, 5 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a87dee5c99..c6fd39aab6 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -230,6 +230,11 @@ INSANE_SKIP:${PN} = "arch" FILES:${PN} += "${datadir}/icons" +python populate_packages:prepend() { +archdir = d.expand('${bindir}/') +do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) +} I don't see a v3 changelog, but that does look like the unnecessary default runtime dependency is gone, but what would be the method of installing the packages if I have an image where I'd like the old non-split functionality ? Either a meta packages (qemu-system-all ?) or a way to override the functionality (a variable around the do_split call ?) are options to enable that sort of thing. As I mentioned before, there's a different expected split of the packages in some scenarios, and it would be ideal to not break those use cases. This is quite a common need for things which call do_split_packages, I'm starting to wonder if it should support some kind of "common" package as a parameter which it would add dependencies to? I'm trying to improve the package method to try to meet the need for both the user who cares about the rpm size and the user who want the old non-split functionality. And I just did a little search for the packages which use do_split_packages and didn't see there is any package which keep both split and no-split functionality and just only split. So I don't quite understand "This is quite a common need for things which call do_split_packages". BTW, if we still use the old non-split, is there any suitable method for the user who cares about the rpm size? Any suggestions? Thanks, Cheers, Richard -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182452): https://lists.openembedded.org/g/openembedded-core/message/182452 Mute This Topic: https://lists.openembedded.org/mt/99279217/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 v3] qemu: Split the qemu package
From: Mingli Yu Currently all files as below packaged into one package such as qemu-7.2.0-*.rpm. After the qemu package installed on the target, it will take up about 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. # ls tmp-glibc/work/core2-64-wrs-linux/qemu/7.2.0-r0/image/usr/bin/ qemu-aarch64 qemu-img qemu-mips64el qemu-ppc64 qemu-sh4qemu-system-loongarch64 qemu-system-ppc qemu-system-x86_64 qemu-arm qemu-io qemu-mipsel qemu-ppc64le qemu-storage-daemon qemu-system-mips qemu-system-ppc64 qemu-x86_64 qemu-edid qemu-loongarch64 qemu-mips.real qemu-pr-helper qemu-system-aarch64 qemu-system-mips64 qemu-system-riscv32 qemu-ga qemu-mips qemu-nbd qemu-riscv32qemu-system-arm qemu-system-mips64el qemu-system-riscv64 qemu-i386 qemu-mips64 qemu-ppc qemu-riscv64qemu-system-i386 qemu-system-mipsel qemu-system-sh4 Split the qemu package into qemu-7.2.0-*.rpm, qemu-system-aarch64-7.2.0*.rpm, qemu-system-x86_64-7.2.0*.rpm and etc. And let user can only choose the corresponding qemu arch package they want to install should ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm (qemu-7.2.0*.rpm) size from about 65M to about 19M and the size of the extracted qemu RPM decreased from about 464M to about 248M. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 5 + 1 file changed, 5 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a87dee5c99..c6fd39aab6 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -230,6 +230,11 @@ INSANE_SKIP:${PN} = "arch" FILES:${PN} += "${datadir}/icons" +python populate_packages:prepend() { +archdir = d.expand('${bindir}/') +do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)' , prepend=True) +} + # Put the guest agent in a separate package PACKAGES =+ "${PN}-guest-agent" SUMMARY:${PN}-guest-agent = "QEMU guest agent" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182138): https://lists.openembedded.org/g/openembedded-core/message/182138 Mute This Topic: https://lists.openembedded.org/mt/99279217/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] qemu: Split the qemu package
On 5/30/23 23:09, Bruce Ashfield wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Tue, May 30, 2023 at 10:54 AM Richard Purdie wrote: On Tue, 2023-05-30 at 16:33 +0200, Alexander Kanavin wrote: I might be missing something here, but can the free-form, anonymous python code block be avoided? Don't we have PACKAGES_DYNAMIC for this purpose? PACKAGES_DYNAMIC is for when we can't predict the packages a recipe might generate. A good example might be kernel modules. You're right that we could add a do_split_packages() call to the qemu recipe have have it generate these dynamically. The downside would be the namespacing as dynamic packages need to have specific namespaces (e.g. kernel-module-XXX). This means qemu-mips wouldn't be an option (conflicts with non dynamic packages like qemu- dbg). We could use a more specific prefix like qemu-system-XXX and qemu-user- XXX and use do_split_packages I did also wonder about using more specific inline python for some of this, things along the lines of: PACKAGES += '${@" ".join("qemu-system-" + x for x in d.getVar('QEMU_TARGETS').split())}' I'm also not a fan of the python code block. We do use do_split_packages() in other recipes like gstreamer to handle things like this. And in case anyone hasn't looked it up, this is the meta-virt solution: https://git.yoctoproject.org/meta-virtualization/tree/recipes-devtools/qemu/qemu-package-split.inc Thanks! I did see this before I send out https://patchwork.yoctoproject.org/project/oe-core/patch/20230530131708.1916975-1-mingli...@eng.windriver.com. Considering to dynamically generate the sub-packages via QEMU_TARGETS, so I use a python block and don't need the change the code even QEMU_TARGETS has some change. But I should let all sub-package to depend the qemu-7.2.0*.rpm. Thanks, Which I'll have to re-work once (if) something lands in core. It isn't suitable as-is, but it doesn't need any python code to suit the on-target system emulation needs of meta-virt. Bruce Cheers, Richard -- - 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 (#182094): https://lists.openembedded.org/g/openembedded-core/message/182094 Mute This Topic: https://lists.openembedded.org/mt/99219254/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] qemu: Split the qemu package
From: Mingli Yu Currently all files as below packaged into one package such as qemu-7.2.0-*.rpm. After the qemu package installed on the target, it will take up about 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. # ls tmp-glibc/work/core2-64-wrs-linux/qemu/7.2.0-r0/image/usr/bin/ qemu-aarch64 qemu-img qemu-mips64el qemu-ppc64 qemu-sh4qemu-system-loongarch64 qemu-system-ppc qemu-system-x86_64 qemu-arm qemu-io qemu-mipsel qemu-ppc64le qemu-storage-daemon qemu-system-mips qemu-system-ppc64 qemu-x86_64 qemu-edid qemu-loongarch64 qemu-mips.real qemu-pr-helper qemu-system-aarch64 qemu-system-mips64 qemu-system-riscv32 qemu-ga qemu-mips qemu-nbd qemu-riscv32qemu-system-arm qemu-system-mips64el qemu-system-riscv64 qemu-i386 qemu-mips64 qemu-ppc qemu-riscv64qemu-system-i386 qemu-system-mipsel qemu-system-sh4 Split the qemu package into qemu-7.2.0-*.rpm, qemu-system-aarch64-7.2.0*.rpm, qemu-system-x86_64-7.2.0*.rpm and etc. And let user can only choose the corresponding qemu arch package they want to install should ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm (qemu-7.2.0*.rpm) size from about 65M to about 19M and the size of the extracted qemu RPM decreased from about 464M to about 248M. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 5 + 1 file changed, 5 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a87dee5c99..e1ed3bbd4d 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -230,6 +230,11 @@ INSANE_SKIP:${PN} = "arch" FILES:${PN} += "${datadir}/icons" +python populate_packages:prepend() { +archdir = d.expand('${bindir}/') +do_split_packages(d, archdir, r'^qemu-system-(.*)$', '${PN}-system-%s', 'QEMU full system emulation binaries(%s)', extra_depends='${PN}', prepend=True) +} + # Put the guest agent in a separate package PACKAGES =+ "${PN}-guest-agent" SUMMARY:${PN}-guest-agent = "QEMU guest agent" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#182093): https://lists.openembedded.org/g/openembedded-core/message/182093 Mute This Topic: https://lists.openembedded.org/mt/99260306/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] qemu: Split the qemu package
From: Mingli Yu Currently all files packaged into one package such as qemu-7.2.0-*.rpm. After the qemu package installed on the target, it will take up 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. Split the qemu package into qemu-7.2.0-*.rpm, qemu-aarch64-7.2.0*.rpm, qemu-arm-7.2.0*.rpm, qemu-x86_64-7.2.0*.rpm and etc. And let user can only choose the corresponding qemu arch package they want to install should ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm(qemu-7.2.0*.rpm) size from about 65M to about 17M and the size of the extracted qemu RPM decreased from about 464M to about 248M. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu.inc | 19 +++ 1 file changed, 19 insertions(+) diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc index a87dee5c99..7302d63747 100644 --- a/meta/recipes-devtools/qemu/qemu.inc +++ b/meta/recipes-devtools/qemu/qemu.inc @@ -230,6 +230,25 @@ INSANE_SKIP:${PN} = "arch" FILES:${PN} += "${datadir}/icons" +python(){ +allarchs = d.getVar('QEMU_TARGETS').split() +packages = d.getVar('PACKAGES').split() +pn = d.getVar('PN') + +newpackages=[] +for arch in allarchs: +archpackage = 'qemu-' + arch +if archpackage not in packages: +newpackages.append(archpackage) +d.setVar('FILES:' + pn + "-" + arch, '${bindir}/qemu-' + arch) +d.appendVar('FILES:' + pn + "-" + arch, ' ' + '${bindir}/qemu-system-' + arch) +if arch == "mips": +d.appendVar('RDEPENDS:' + pn + '-' + arch, ' ' + 'bash') +packages = newpackages + packages +d.setVar('PACKAGES', ' '.join(packages)) +} + + # Put the guest agent in a separate package PACKAGES =+ "${PN}-guest-agent" SUMMARY:${PN}-guest-agent = "QEMU guest agent" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#181922): https://lists.openembedded.org/g/openembedded-core/message/181922 Mute This Topic: https://lists.openembedded.org/mt/99219254/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] qemu: Restrict the built qemu targets
From: Mingli Yu Now the QEMU_TARGETS used to set the supported built qemu targets both for "bitbake qemu-native" and "bitbake qemu". After the qemu package installed on the target, it will take up 464M which includes not only the one matches the arch of the target but aslo all available built qemu targets which set by QEMU_TARGETS. Making "bitbake qemu" to only build the arch matches the target should satisfy our usual need and ease the concerns who cares much about the size in embedded device as it decreases the qemu rpm size from about 65M to about 17M and the size of the extracted qemu RPM decreased from about 464M to about 248M. Signed-off-by: Mingli Yu --- meta/recipes-devtools/qemu/qemu-targets.inc | 15 +-- meta/recipes-devtools/qemu/qemu_8.0.0.bb| 2 +- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/meta/recipes-devtools/qemu/qemu-targets.inc b/meta/recipes-devtools/qemu/qemu-targets.inc index 24f9a03948..bd0b47a4e7 100644 --- a/meta/recipes-devtools/qemu/qemu-targets.inc +++ b/meta/recipes-devtools/qemu/qemu-targets.inc @@ -3,9 +3,20 @@ #mips mipsel mips64 mips64el ppc ppc64 ppc64abi32 ppcemb #riscv32 riscv64 sparc sparc32 sparc32plus -def get_qemu_target_list(d): +def get_qemu_target_list(d, target=False): import bb -archs = d.getVar('QEMU_TARGETS').split() +if target: +archs = [] +allarchs = d.getVar('QEMU_TARGETS').split() +if d.getVar("TARGET_ARCH") in ["x86", "i486", "i586", "i686"]: +machine_arch = "i386" +else: +machine_arch = d.getVar("TARGET_ARCH") +for arch in allarchs: +if arch in machine_arch: +archs.append(arch) +else: +archs = d.getVar('QEMU_TARGETS').split() tos = d.getVar('HOST_OS') softmmuonly = "" for arch in ['ppcemb', 'lm32']: diff --git a/meta/recipes-devtools/qemu/qemu_8.0.0.bb b/meta/recipes-devtools/qemu/qemu_8.0.0.bb index 42e133967e..6c25d99ade 100644 --- a/meta/recipes-devtools/qemu/qemu_8.0.0.bb +++ b/meta/recipes-devtools/qemu/qemu_8.0.0.bb @@ -10,7 +10,7 @@ CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', RDEPENDS:${PN}:class-target += "bash" -EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}" +EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d, target=True)}" EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}" EXTRA_OECONF:append:class-nativesdk = " --target-list=${@get_qemu_target_list(d)}" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#181773): https://lists.openembedded.org/g/openembedded-core/message/181773 Mute This Topic: https://lists.openembedded.org/mt/99150807/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] ruby: Fix CVE-2023-28755
From: Mingli Yu Backport patch [1] to fix CVE-2023-28755. [1] https://github.com/ruby/ruby/commit/8ce4ab146498879b65e22f1be951b25eebb79300 Signed-off-by: Mingli Yu --- .../ruby/ruby/CVE-2023-28755.patch| 68 +++ meta/recipes-devtools/ruby/ruby_3.1.3.bb | 1 + 2 files changed, 69 insertions(+) create mode 100644 meta/recipes-devtools/ruby/ruby/CVE-2023-28755.patch diff --git a/meta/recipes-devtools/ruby/ruby/CVE-2023-28755.patch b/meta/recipes-devtools/ruby/ruby/CVE-2023-28755.patch new file mode 100644 index 00..d611c41dcc --- /dev/null +++ b/meta/recipes-devtools/ruby/ruby/CVE-2023-28755.patch @@ -0,0 +1,68 @@ +From db4bb57d4af6d097a0c29490536793d95f1d8983 Mon Sep 17 00:00:00 2001 +From: Hiroshi SHIBATA +Date: Mon, 24 Apr 2023 08:27:24 + +Subject: [PATCH] Merge URI-0.12.1 + +CVE: CVE-2023-28755 + +Upstream-Status: Backport [https://github.com/ruby/ruby/commit/8ce4ab146498879b65e22f1be951b25eebb79300] + +Signed-off-by: Mingli Yu +--- + lib/uri/rfc3986_parser.rb | 4 ++-- + lib/uri/version.rb| 2 +- + test/uri/test_common.rb | 11 +++ + 3 files changed, 14 insertions(+), 3 deletions(-) + +diff --git a/lib/uri/rfc3986_parser.rb b/lib/uri/rfc3986_parser.rb +index 3e07de4..3c89311 100644 +--- a/lib/uri/rfc3986_parser.rb b/lib/uri/rfc3986_parser.rb +@@ -3,8 +3,8 @@ module URI + class RFC3986_Parser # :nodoc: + # URI defined in RFC3986 + # this regexp is modified not to host is not empty string +-RFC3986_URI = /\A(?(?[A-Za-z][+\-.0-9A-Za-z]*):(?\/\/(?(?:(?(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*)@)?(?(?\[(?:(?(?:\h{1,4}:){6}(?\h{1,4}:\h{1,4}|(?(?[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g\.\g\.\g))|::(?:\h{1,4}:){5}\g|\h{1,4}?::(?:\h{1,4}:){4}\g|(?:(?:\h{1,4}:)?\h{1,4})?::(?:\h{1,4}:){3}\g|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?v\h+\.[!$&-.0-;=A-Z_a-z~]+))\])|\g|(?(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])+))?(?::(?\d*))?)(?(?:\/(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*))*)|(?\/(?:(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])+)(?:\/\g)*)?)|(?\g(?:\/\g)*)|(?))(?:\?(?[^#]*))?(?:\#(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*))?)\z/ +-RFC3986_relative_ref = /\A(?(?\/\/(?(?:(?(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*)@)?(?(?\[(?(?:\h{1,4}:){6}(?\h{1,4}:\h{1,4}|(?(?[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g\.\g\.\g))|::(?:\h{1,4}:){5}\g|\h{1,4}?::(?:\h{1,4}:){4}\g|(?:(?:\h{1,4}:){,1}\h{1,4})?::(?:\h{1,4}:){3}\g|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?v\h+\.[!$&-.0-;=A-Z_a-z~]+)\])|\g|(?(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])+))?(?::(?\d*))?)(?(?:\/(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*))*)|(?\/(?:(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])+)(?:\/\g)*)?)|(?(?(?:%\h\h|[!$&-.0-9;=@-Z_a-z~])+)(?:\/\g)*)|(?))(?:\?(?[^#]*))?(?:\#(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*))?)\z/ ++RFC3986_URI = /\A(?(?[A-Za-z][+\-.0-9A-Za-z]*+):(?\/\/(?(?:(?(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*+)@)?(?(?\[(?:(?(?:\h{1,4}:){6}(?\h{1,4}:\h{1,4}|(?(?[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g\.\g\.\g))|::(?:\h{1,4}:){5}\g|\h{1,4}?::(?:\h{1,4}:){4}\g|(?:(?:\h{1,4}:)?\h{1,4})?::(?:\h{1,4}:){3}\g|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?v\h++\.[!$&-.0-;=A-Z_a-z~]++))\])|\g|(?(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])*+))(?::(?\d*+))?)(?(?:\/(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*+))*+)|(?\/(?:(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])++)(?:\/\g)*+)?)|(?\g(?:\/\g)*+)|(?))(?:\?(?[^#]*+))?(?:\#(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*+))?)\z/ ++RFC3986_relative_ref = /\A(?(?\/\/(?(?:(?(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*+)@)?(?(?\[(?:(?(?:\h{1,4}:){6}(?\h{1,4}:\h{1,4}|(?(?[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g\.\g\.\g))|::(?:\h{1,4}:){5}\g|\h{1,4}?::(?:\h{1,4}:){4}\g|(?:(?:\h{1,4}:){,1}\h{1,4})?::(?:\h{1,4}:){3}\g|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?v\h++\.[!$&-.0-;=A-Z_a-z~]++))\])|\g|(?(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])++))?(?::(?\d*+))?)(?(?:\/(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*+))*+)|(?\/(?:(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~])++)(?:\/\g)*+)?)|(?(?(?:%\h\h|[!$&-.0-9;=@-Z_a-z~])++)(?:\/\g)*+)|(?))(?:\?(?[^#]*+))?(?:\#(?(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*+))?)\z/ + attr_reader :regexp + + def initialize +diff --git a/lib/uri/version.rb b/lib/uri/version.rb +index 82188e2..7497a7d 100644 +--- a/lib/uri/version.rb b/lib/uri/version.rb +@@ -1,6 +1,6 @@ + module URI + # :stopdoc: +- VERSION_CODE = '001100'.freeze ++ VERSION_CODE = '001201'.freeze + VERSION = VERSION_CODE.scan(/../).collect{|n| n.to_i}.join('.').freeze + # :startdoc: + end +diff --git a/test/uri/test_common.rb
Re: [OE-core] [kirkstone][PATCH] curl: Fix CVE-2023-27536
On 4/18/23 00:42, Steve Sakoman wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. There is also a patch submitted today that fixes this CVE as well as two others: https://lists.openembedded.org/g/openembedded-core/message/180143 I'm fine with the patch as https://lists.openembedded.org/g/openembedded-core/message/180143. Thanks, Could you review the above patch and ack if you approve. It would be nice to fix all three patches in a single commit if possible. Thanks! Steve On Sun, Apr 16, 2023 at 8:22 PM Yu, Mingli wrote: From: Mingli Yu Backport patch [1] to fix CVE-2023-27536. [1] https://github.com/curl/curl/commit/cb49e67303dba Signed-off-by: Mingli Yu --- .../curl/curl/CVE-2023-27536.patch| 57 +++ meta/recipes-support/curl/curl_7.82.0.bb | 1 + 2 files changed, 58 insertions(+) create mode 100644 meta/recipes-support/curl/curl/CVE-2023-27536.patch diff --git a/meta/recipes-support/curl/curl/CVE-2023-27536.patch b/meta/recipes-support/curl/curl/CVE-2023-27536.patch new file mode 100644 index 00..842c70785a --- /dev/null +++ b/meta/recipes-support/curl/curl/CVE-2023-27536.patch @@ -0,0 +1,57 @@ +From 6b1ef6d5ebbfd5e68dea1eea2dc0c6cc4dc2e394 Mon Sep 17 00:00:00 2001 +From: Daniel Stenberg +Date: Mon, 17 Apr 2023 05:36:18 + +Subject: [PATCH] url: only reuse connections with same GSS delegation + +Reported-by: Harry Sintonen +Closes #10731 + +CVE: CVE-2023-27536 + +Upstream-Status: Backport [https://github.com/curl/curl/commit/cb49e67303dba] + +Signed-off-by: Mingli Yu +--- + lib/url.c | 6 ++ + lib/urldata.h | 1 + + 2 files changed, 7 insertions(+) + +diff --git a/lib/url.c b/lib/url.c +index df4377d..8c43c3b 100644 +--- a/lib/url.c b/lib/url.c +@@ -1350,6 +1350,11 @@ ConnectionExists(struct Curl_easy *data, + } + } + ++ /* GSS delegation differences do not actually affect every connection ++ and auth method, but this check takes precaution before efficiency */ ++ if(needle->gssapi_delegation != check->gssapi_delegation) ++continue; ++ + /* If multiplexing isn't enabled on the h2 connection and h1 is + explicitly requested, handle it: */ + if((needle->handler->protocol & PROTO_FAMILY_HTTP) && +@@ -1807,6 +1812,7 @@ static struct connectdata *allocate_conn(struct Curl_easy *data) + conn->fclosesocket = data->set.fclosesocket; + conn->closesocket_client = data->set.closesocket_client; + conn->lastused = Curl_now(); /* used now */ ++ conn->gssapi_delegation = data->set.gssapi_delegation; + + return conn; + error: +diff --git a/lib/urldata.h b/lib/urldata.h +index 69eb2ee..c2a7e6c 100644 +--- a/lib/urldata.h b/lib/urldata.h +@@ -1131,6 +1131,7 @@ struct connectdata { + int socks5_gssapi_enctype; + #endif + unsigned short localport; ++ unsigned char gssapi_delegation; /* inherited from set.gssapi_delegation */ + }; + + /* The end of connectdata. */ +-- +2.23.0 + diff --git a/meta/recipes-support/curl/curl_7.82.0.bb b/meta/recipes-support/curl/curl_7.82.0.bb index 945745cdde..888527857a 100644 --- a/meta/recipes-support/curl/curl_7.82.0.bb +++ b/meta/recipes-support/curl/curl_7.82.0.bb @@ -40,6 +40,7 @@ SRC_URI = "https://curl.se/download/${BP}.tar.xz \ file://CVE-2023-23914_5-4.patch \ file://CVE-2023-23914_5-5.patch \ file://CVE-2023-23916.patch \ + file://CVE-2023-27536.patch \ " SRC_URI[sha256sum] = "0aaa12d7bd04b0966254f2703ce80dd5c38dbbd76af0297d3d690cdce58a583c" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#180208): https://lists.openembedded.org/g/openembedded-core/message/180208 Mute This Topic: https://lists.openembedded.org/mt/98313621/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] report-error: make it catch ParseError error
From: Mingli Yu Make the report-error catch ParseError error as below and then we can check it directly via error report web. ParseError at /build/layers/oe-core/meta/recipes-support/curl/curl_7.88.1.bb:32: unparsed line: 'PACKAGECONFIG[ares] = "--enable-ares,--disable-ares,c-ares,,,threaded-resolver' Signed-off-by: Mingli Yu --- meta/classes/report-error.bbclass | 52 ++- 1 file changed, 31 insertions(+), 21 deletions(-) diff --git a/meta/classes/report-error.bbclass b/meta/classes/report-error.bbclass index 2b2ad56514..1452513a66 100644 --- a/meta/classes/report-error.bbclass +++ b/meta/classes/report-error.bbclass @@ -39,6 +39,19 @@ def get_conf_data(e, filename): jsonstring=jsonstring + line return jsonstring +def get_common_data(e): +data = {} +data['machine'] = e.data.getVar("MACHINE") +data['build_sys'] = e.data.getVar("BUILD_SYS") +data['distro'] = e.data.getVar("DISTRO") +data['target_sys'] = e.data.getVar("TARGET_SYS") +data['branch_commit'] = str(oe.buildcfg.detect_branch(e.data)) + ": " + str(oe.buildcfg.detect_revision(e.data)) +data['bitbake_version'] = e.data.getVar("BB_VERSION") +data['layer_version'] = get_layers_branch_rev(e.data) +data['local_conf'] = get_conf_data(e, 'local.conf') +data['auto_conf'] = get_conf_data(e, 'auto.conf') +return data + python errorreport_handler () { import json import codecs @@ -56,19 +69,10 @@ python errorreport_handler () { if isinstance(e, bb.event.BuildStarted): bb.utils.mkdirhier(logpath) data = {} -machine = e.data.getVar("MACHINE") -data['machine'] = machine -data['build_sys'] = e.data.getVar("BUILD_SYS") +data = get_common_data(e) data['nativelsb'] = nativelsb() -data['distro'] = e.data.getVar("DISTRO") -data['target_sys'] = e.data.getVar("TARGET_SYS") data['failures'] = [] data['component'] = " ".join(e.getPkgs()) -data['branch_commit'] = str(oe.buildcfg.detect_branch(e.data)) + ": " + str(oe.buildcfg.detect_revision(e.data)) -data['bitbake_version'] = e.data.getVar("BB_VERSION") -data['layer_version'] = get_layers_branch_rev(e.data) -data['local_conf'] = get_conf_data(e, 'local.conf') -data['auto_conf'] = get_conf_data(e, 'auto.conf') lock = bb.utils.lockfile(datafile + '.lock') errorreport_savedata(e, data, "error-report.txt") bb.utils.unlockfile(lock) @@ -110,19 +114,10 @@ python errorreport_handler () { elif isinstance(e, bb.event.NoProvider): bb.utils.mkdirhier(logpath) data = {} -machine = e.data.getVar("MACHINE") -data['machine'] = machine -data['build_sys'] = e.data.getVar("BUILD_SYS") +data = get_common_data(e) data['nativelsb'] = nativelsb() -data['distro'] = e.data.getVar("DISTRO") -data['target_sys'] = e.data.getVar("TARGET_SYS") data['failures'] = [] data['component'] = str(e._item) -data['branch_commit'] = str(oe.buildcfg.detect_branch(e.data)) + ": " + str(oe.buildcfg.detect_revision(e.data)) -data['bitbake_version'] = e.data.getVar("BB_VERSION") -data['layer_version'] = get_layers_branch_rev(e.data) -data['local_conf'] = get_conf_data(e, 'local.conf') -data['auto_conf'] = get_conf_data(e, 'auto.conf') taskdata={} taskdata['log'] = str(e) taskdata['package'] = str(e._item) @@ -132,6 +127,21 @@ python errorreport_handler () { errorreport_savedata(e, data, "error-report.txt") bb.utils.unlockfile(lock) +elif isinstance(e, bb.event.ParseError): +bb.utils.mkdirhier(logpath) +data = {} +data = get_common_data(e) +data['nativelsb'] = nativelsb() +data['failures'] = [] +data['component'] = "parse" +taskdata={} +taskdata['log'] = str(e._msg) +taskdata['task'] = str(e._msg) +data['failures'].append(taskdata) +lock = bb.utils.lockfile(datafile + '.lock') +errorreport_savedata(e, data, "error-report.txt") +bb.utils.unlockfile(lock) + elif isinstance(e, bb.event.BuildCompleted): lock = bb.utils.lockfile(datafile + '.lock') jsondata = json.loads(errorreport_getdata(e)) @@ -145,4 +155,4 @@ python errorreport_handler () { } addhandler errorreport_handler -errorreport_handler[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted bb.build.TaskFailed bb.event.NoProvider" +errorreport_handler[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted bb.build.TaskFailed bb.event.NoProvider
[OE-core] [kirkstone][PATCH] curl: Fix CVE-2023-27536
From: Mingli Yu Backport patch [1] to fix CVE-2023-27536. [1] https://github.com/curl/curl/commit/cb49e67303dba Signed-off-by: Mingli Yu --- .../curl/curl/CVE-2023-27536.patch| 57 +++ meta/recipes-support/curl/curl_7.82.0.bb | 1 + 2 files changed, 58 insertions(+) create mode 100644 meta/recipes-support/curl/curl/CVE-2023-27536.patch diff --git a/meta/recipes-support/curl/curl/CVE-2023-27536.patch b/meta/recipes-support/curl/curl/CVE-2023-27536.patch new file mode 100644 index 00..842c70785a --- /dev/null +++ b/meta/recipes-support/curl/curl/CVE-2023-27536.patch @@ -0,0 +1,57 @@ +From 6b1ef6d5ebbfd5e68dea1eea2dc0c6cc4dc2e394 Mon Sep 17 00:00:00 2001 +From: Daniel Stenberg +Date: Mon, 17 Apr 2023 05:36:18 + +Subject: [PATCH] url: only reuse connections with same GSS delegation + +Reported-by: Harry Sintonen +Closes #10731 + +CVE: CVE-2023-27536 + +Upstream-Status: Backport [https://github.com/curl/curl/commit/cb49e67303dba] + +Signed-off-by: Mingli Yu +--- + lib/url.c | 6 ++ + lib/urldata.h | 1 + + 2 files changed, 7 insertions(+) + +diff --git a/lib/url.c b/lib/url.c +index df4377d..8c43c3b 100644 +--- a/lib/url.c b/lib/url.c +@@ -1350,6 +1350,11 @@ ConnectionExists(struct Curl_easy *data, + } + } + ++ /* GSS delegation differences do not actually affect every connection ++ and auth method, but this check takes precaution before efficiency */ ++ if(needle->gssapi_delegation != check->gssapi_delegation) ++continue; ++ + /* If multiplexing isn't enabled on the h2 connection and h1 is + explicitly requested, handle it: */ + if((needle->handler->protocol & PROTO_FAMILY_HTTP) && +@@ -1807,6 +1812,7 @@ static struct connectdata *allocate_conn(struct Curl_easy *data) + conn->fclosesocket = data->set.fclosesocket; + conn->closesocket_client = data->set.closesocket_client; + conn->lastused = Curl_now(); /* used now */ ++ conn->gssapi_delegation = data->set.gssapi_delegation; + + return conn; + error: +diff --git a/lib/urldata.h b/lib/urldata.h +index 69eb2ee..c2a7e6c 100644 +--- a/lib/urldata.h b/lib/urldata.h +@@ -1131,6 +1131,7 @@ struct connectdata { + int socks5_gssapi_enctype; + #endif + unsigned short localport; ++ unsigned char gssapi_delegation; /* inherited from set.gssapi_delegation */ + }; + + /* The end of connectdata. */ +-- +2.23.0 + diff --git a/meta/recipes-support/curl/curl_7.82.0.bb b/meta/recipes-support/curl/curl_7.82.0.bb index 945745cdde..888527857a 100644 --- a/meta/recipes-support/curl/curl_7.82.0.bb +++ b/meta/recipes-support/curl/curl_7.82.0.bb @@ -40,6 +40,7 @@ SRC_URI = "https://curl.se/download/${BP}.tar.xz \ file://CVE-2023-23914_5-4.patch \ file://CVE-2023-23914_5-5.patch \ file://CVE-2023-23916.patch \ + file://CVE-2023-27536.patch \ " SRC_URI[sha256sum] = "0aaa12d7bd04b0966254f2703ce80dd5c38dbbd76af0297d3d690cdce58a583c" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#180120): https://lists.openembedded.org/g/openembedded-core/message/180120 Mute This Topic: https://lists.openembedded.org/mt/98313621/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] report-error: make it catch ParseError error
From: Mingli Yu Make the report-error catch ParseError error as below and then we can check it directly via error report web. ParseError at /build/layers/oe-core/meta/recipes-support/curl/curl_7.88.1.bb:32: unparsed line: 'PACKAGECONFIG[ares] = "--enable-ares,--disable-ares,c-ares,,,threaded-resolver' Signed-off-by: Mingli Yu --- meta/classes/report-error.bbclass | 26 +- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/meta/classes/report-error.bbclass b/meta/classes/report-error.bbclass index 2b2ad56514..041db44941 100644 --- a/meta/classes/report-error.bbclass +++ b/meta/classes/report-error.bbclass @@ -132,6 +132,30 @@ python errorreport_handler () { errorreport_savedata(e, data, "error-report.txt") bb.utils.unlockfile(lock) +elif isinstance(e, bb.event.ParseError): +bb.utils.mkdirhier(logpath) +data = {} +machine = e.data.getVar("MACHINE") +data['machine'] = machine +data['build_sys'] = e.data.getVar("BUILD_SYS") +data['nativelsb'] = nativelsb() +data['distro'] = e.data.getVar("DISTRO") +data['target_sys'] = e.data.getVar("TARGET_SYS") +data['failures'] = [] +data['component'] = "parse" +data['branch_commit'] = str(oe.buildcfg.detect_branch(e.data)) + ": " + str(oe.buildcfg.detect_revision(e.data)) +data['bitbake_version'] = e.data.getVar("BB_VERSION") +data['layer_version'] = get_layers_branch_rev(e.data) +data['local_conf'] = get_conf_data(e, 'local.conf') +data['auto_conf'] = get_conf_data(e, 'auto.conf') +taskdata={} +taskdata['log'] = str(e._msg) +taskdata['task'] = str(e._msg) +data['failures'].append(taskdata) +lock = bb.utils.lockfile(datafile + '.lock') +errorreport_savedata(e, data, "error-report.txt") +bb.utils.unlockfile(lock) + elif isinstance(e, bb.event.BuildCompleted): lock = bb.utils.lockfile(datafile + '.lock') jsondata = json.loads(errorreport_getdata(e)) @@ -145,4 +169,4 @@ python errorreport_handler () { } addhandler errorreport_handler -errorreport_handler[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted bb.build.TaskFailed bb.event.NoProvider" +errorreport_handler[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted bb.build.TaskFailed bb.event.NoProvider bb.event.ParseError" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#179984): https://lists.openembedded.org/g/openembedded-core/message/179984 Mute This Topic: https://lists.openembedded.org/mt/98254507/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] report-error: catch Nothing PROVIDES error
From: Mingli Yu Make the report-error catch Nothing PROVIDES error and then we can check it directly via error report web. Signed-off-by: Mingli Yu --- meta/classes/report-error.bbclass | 27 ++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/meta/classes/report-error.bbclass b/meta/classes/report-error.bbclass index 2f692fbbcc..2b2ad56514 100644 --- a/meta/classes/report-error.bbclass +++ b/meta/classes/report-error.bbclass @@ -107,6 +107,31 @@ python errorreport_handler () { errorreport_savedata(e, jsondata, "error-report.txt") bb.utils.unlockfile(lock) +elif isinstance(e, bb.event.NoProvider): +bb.utils.mkdirhier(logpath) +data = {} +machine = e.data.getVar("MACHINE") +data['machine'] = machine +data['build_sys'] = e.data.getVar("BUILD_SYS") +data['nativelsb'] = nativelsb() +data['distro'] = e.data.getVar("DISTRO") +data['target_sys'] = e.data.getVar("TARGET_SYS") +data['failures'] = [] +data['component'] = str(e._item) +data['branch_commit'] = str(oe.buildcfg.detect_branch(e.data)) + ": " + str(oe.buildcfg.detect_revision(e.data)) +data['bitbake_version'] = e.data.getVar("BB_VERSION") +data['layer_version'] = get_layers_branch_rev(e.data) +data['local_conf'] = get_conf_data(e, 'local.conf') +data['auto_conf'] = get_conf_data(e, 'auto.conf') +taskdata={} +taskdata['log'] = str(e) +taskdata['package'] = str(e._item) +taskdata['task'] = "Nothing provides " + "'" + str(e._item) + "'" +data['failures'].append(taskdata) +lock = bb.utils.lockfile(datafile + '.lock') +errorreport_savedata(e, data, "error-report.txt") +bb.utils.unlockfile(lock) + elif isinstance(e, bb.event.BuildCompleted): lock = bb.utils.lockfile(datafile + '.lock') jsondata = json.loads(errorreport_getdata(e)) @@ -120,4 +145,4 @@ python errorreport_handler () { } addhandler errorreport_handler -errorreport_handler[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted bb.build.TaskFailed" +errorreport_handler[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted bb.build.TaskFailed bb.event.NoProvider" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#179604): https://lists.openembedded.org/g/openembedded-core/message/179604 Mute This Topic: https://lists.openembedded.org/mt/98031351/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 v3] curl: Add fix for CVE-2023-23914, CVE-2023-23915
From: Pawan Badganchi Add below patches to fix CVE-2023-23914 [1], CVE-2023-23915 [2] CVE-2023-23914_5-1.patch CVE-2023-23914_5-2.patch CVE-2023-23914_5-3.patch CVE-2023-23914_5-4.patch CVE-2023-23914_5-5.patch [1] https://curl.se/docs/CVE-2023-23914.html [2] https://curl.se/docs/CVE-2023-23915.html Signed-off-by: Pawan Badganchi Signed-off-by: pawan Signed-off-by: Mingli Yu --- .../curl/curl/CVE-2023-23914_5-1.patch| 280 ++ .../curl/curl/CVE-2023-23914_5-2.patch| 23 ++ .../curl/curl/CVE-2023-23914_5-3.patch| 45 +++ .../curl/curl/CVE-2023-23914_5-4.patch| 48 +++ .../curl/curl/CVE-2023-23914_5-5.patch| 118 meta/recipes-support/curl/curl_7.82.0.bb | 5 + 6 files changed, 519 insertions(+) create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-2.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-3.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-4.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-5.patch diff --git a/meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch b/meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch new file mode 100644 index 00..d357cee76c --- /dev/null +++ b/meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch @@ -0,0 +1,280 @@ +From 076a2f629119222aeeb50f5a03bf9f9052fabb9a Mon Sep 17 00:00:00 2001 +From: Daniel Stenberg +Date: Tue, 27 Dec 2022 11:50:20 +0100 +Subject: [PATCH] share: add sharing of HSTS cache among handles + +Closes #10138 + +CVE: CVE-2023-23914 CVE-2023-23915 +Upstream-Status: Backport [https://github.com/curl/curl/commit/076a2f629119222aeeb50f5a03bf9f9052fabb9a] +Comment: Refreshed hunk from hsts.c and urldata.h +Signed-off-by: Pawan Badganchi +Signed-off-by: Mingli Yu +--- + include/curl/curl.h | 1 + + lib/hsts.c | 15 + + lib/hsts.h | 2 ++ + lib/setopt.c| 48 - + lib/share.c | 32 +-- + lib/share.h | 6 +++- + lib/transfer.c | 3 ++ + lib/url.c | 6 +++- + lib/urldata.h | 2 ++ + 9 files changed, 109 insertions(+), 11 deletions(-) + +--- a/include/curl/curl.h b/include/curl/curl.h +@@ -2953,6 +2953,7 @@ typedef enum { + CURL_LOCK_DATA_SSL_SESSION, + CURL_LOCK_DATA_CONNECT, + CURL_LOCK_DATA_PSL, ++ CURL_LOCK_DATA_HSTS, + CURL_LOCK_DATA_LAST + } curl_lock_data; + +--- a/lib/hsts.c b/lib/hsts.c +@@ -37,6 +37,7 @@ + #include "parsedate.h" + #include "rand.h" + #include "rename.h" ++#include "share.h" + #include "strtoofft.h" + + /* The last 3 #include files should be in this order */ +@@ -561,4 +562,18 @@ + return CURLE_OK; + } + ++void Curl_hsts_loadfiles(struct Curl_easy *data) ++{ ++ struct curl_slist *l = data->set.hstslist; ++ if(l) { ++Curl_share_lock(data, CURL_LOCK_DATA_HSTS, CURL_LOCK_ACCESS_SINGLE); ++ ++while(l) { ++ (void)Curl_hsts_loadfile(data, data->hsts, l->data); ++ l = l->next; ++} ++Curl_share_unlock(data, CURL_LOCK_DATA_HSTS); ++ } ++} ++ + #endif /* CURL_DISABLE_HTTP || CURL_DISABLE_HSTS */ +--- a/lib/hsts.h b/lib/hsts.h +@@ -59,9 +59,11 @@ CURLcode Curl_hsts_loadfile(struct Curl_ + struct hsts *h, const char *file); + CURLcode Curl_hsts_loadcb(struct Curl_easy *data, + struct hsts *h); ++void Curl_hsts_loadfiles(struct Curl_easy *data); + #else + #define Curl_hsts_cleanup(x) + #define Curl_hsts_loadcb(x,y) CURLE_OK + #define Curl_hsts_save(x,y,z) ++#define Curl_hsts_loadfiles(x) + #endif /* CURL_DISABLE_HTTP || CURL_DISABLE_HSTS */ + #endif /* HEADER_CURL_HSTS_H */ +--- a/lib/setopt.c b/lib/setopt.c +@@ -2260,9 +2260,14 @@ CURLcode Curl_vsetopt(struct Curl_easy * + data->cookies = NULL; + #endif + ++#ifndef CURL_DISABLE_HSTS ++ if(data->share->hsts == data->hsts) ++data->hsts = NULL; ++#endif ++#ifdef USE_SSL + if(data->share->sslsession == data->state.session) + data->state.session = NULL; +- ++#endif + #ifdef USE_LIBPSL + if(data->psl == >share->psl) + data->psl = data->multi? >multi->psl: NULL; +@@ -2296,10 +2301,19 @@ CURLcode Curl_vsetopt(struct Curl_easy * + data->cookies = data->share->cookies; + } + #endif /* CURL_DISABLE_HTTP */ ++#ifndef CURL_DISABLE_HSTS ++ if(data->share->hsts) { ++/* first free the private one if any */ ++Curl_hsts_cleanup(>hsts); ++data->hsts = data->share->hsts; ++ } ++#endif /* CURL_DISABLE_HTTP */ ++#ifdef USE_SSL + if(data->share->sslsession) { + data->set.general_ssl.max_ssl_sessions = data->share->max_ssl_sessions; + data->state.session =
[OE-core] [PATCH] mdadm: fix tests/00raid0
From: Mingli Yu Backport patch [1] to fix tests/00raid0. [1] https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=7539254342bc591717b0051734cc6c09c1b88640 Signed-off-by: Mingli Yu --- ...d-a-test-that-validates-raid0-with-l.patch | 41 +++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 1 + 2 files changed, 42 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch diff --git a/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch b/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch new file mode 100644 index 00..1c95834a7e --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch @@ -0,0 +1,41 @@ +From 7539254342bc591717b0051734cc6c09c1b88640 Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:13 -0600 +Subject: [PATCH] tests/00raid0: add a test that validates raid0 with layout + fails for 0.9 + +329dfc28debb disallows the creation of raid0 with layouts for 0.9 +metadata. This test confirms the new behavior. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=7539254342bc591717b0051734cc6c09c1b88640] + +Signed-off-by: Sudhakar Panneerselvam +Signed-off-by: Himanshu Madhani +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/00raid0 | 6 ++ + 1 file changed, 2 insertions(+), 4 deletions(-) + +diff --git a/tests/00raid0 b/tests/00raid0 +index 8bc18985..e6b21cc4 100644 +--- a/tests/00raid0 b/tests/00raid0 +@@ -6,11 +6,9 @@ check raid0 + testdev $md0 3 $mdsize2_l 512 + mdadm -S $md0 + +-# now with version-0.90 superblock ++# verify raid0 with layouts fail for 0.90 + mdadm -CR $md0 -e0.90 -l0 -n4 $dev0 $dev1 $dev2 $dev3 +-check raid0 +-testdev $md0 4 $mdsize0 512 +-mdadm -S $md0 ++check opposite_result + + # now with no superblock + mdadm -B $md0 -l0 -n5 $dev0 $dev1 $dev2 $dev3 $dev4 +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/mdadm_4.2.bb b/meta/recipes-extended/mdadm/mdadm_4.2.bb index ffb42aa13a..14de9d88c2 100644 --- a/meta/recipes-extended/mdadm/mdadm_4.2.bb +++ b/meta/recipes-extended/mdadm/mdadm_4.2.bb @@ -28,6 +28,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \ file://0001-Define-alignof-using-_Alignof-when-using-C11-or-newe.patch \ file://0001-mdadm-Fix-optional-write-behind-parameter.patch \ file://0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch \ + file://0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch \ file://0001-tests-fix-raid0-tests-for-0.90-metadata.patch \ file://0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch \ file://0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch \ -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#178752): https://lists.openembedded.org/g/openembedded-core/message/178752 Mute This Topic: https://lists.openembedded.org/mt/97671806/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 3/3] mdadm: Fix raid0 tests
From: Mingli Yu Backport patches to fix raid0 tests: tests/00raid0 tests/00readonly tests/03r0assem tests/04r0update tests/04update-metadata Signed-off-by: Mingli Yu --- ...d-a-test-that-validates-raid0-with-l.patch | 41 +++ ...-Run-udevadm-settle-before-setting-r.patch | 39 +++ ...metadata-avoid-passing-chunk-size-to.patch | 41 +++ ...ts-fix-raid0-tests-for-0.90-metadata.patch | 102 ++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 4 + 5 files changed, 227 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch diff --git a/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch b/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch new file mode 100644 index 00..1c95834a7e --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch @@ -0,0 +1,41 @@ +From 7539254342bc591717b0051734cc6c09c1b88640 Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:13 -0600 +Subject: [PATCH] tests/00raid0: add a test that validates raid0 with layout + fails for 0.9 + +329dfc28debb disallows the creation of raid0 with layouts for 0.9 +metadata. This test confirms the new behavior. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=7539254342bc591717b0051734cc6c09c1b88640] + +Signed-off-by: Sudhakar Panneerselvam +Signed-off-by: Himanshu Madhani +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/00raid0 | 6 ++ + 1 file changed, 2 insertions(+), 4 deletions(-) + +diff --git a/tests/00raid0 b/tests/00raid0 +index 8bc18985..e6b21cc4 100644 +--- a/tests/00raid0 b/tests/00raid0 +@@ -6,11 +6,9 @@ check raid0 + testdev $md0 3 $mdsize2_l 512 + mdadm -S $md0 + +-# now with version-0.90 superblock ++# verify raid0 with layouts fail for 0.90 + mdadm -CR $md0 -e0.90 -l0 -n4 $dev0 $dev1 $dev2 $dev3 +-check raid0 +-testdev $md0 4 $mdsize0 512 +-mdadm -S $md0 ++check opposite_result + + # now with no superblock + mdadm -B $md0 -l0 -n5 $dev0 $dev1 $dev2 $dev3 $dev4 +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch new file mode 100644 index 00..c621c082e8 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch @@ -0,0 +1,39 @@ +From 39b381252c32275079344d30de18b76fda4bba26 Mon Sep 17 00:00:00 2001 +From: Logan Gunthorpe +Date: Wed, 27 Jul 2022 15:52:45 -0600 +Subject: [PATCH] tests/00readonly: Run udevadm settle before setting ro + +In some recent kernel versions, 00readonly fails with: + + mdadm: failed to set readonly for /dev/md0: Device or resource busy + ERROR: array is not read-only! + +This was traced down to a race condition with udev holding a reference +to the block device at the same time as trying to set it read only. + +To fix this, call udevadm settle before setting the array read only. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=39b381252c32275079344d30de18b76fda4bba26] + +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/00readonly | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/tests/00readonly b/tests/00readonly +index 39202487..afe243b3 100644 +--- a/tests/00readonly b/tests/00readonly +@@ -12,6 +12,7 @@ do + $dev1 $dev2 $dev3 $dev4 --assume-clean + check nosync + check $level ++ udevadm settle + mdadm -ro $md0 + check readonly + state=$(cat /sys/block/md0/md/array_state) +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch new file mode 100644 index 00..9098fb2540 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch @@ -0,0 +1,41 @@ +From de045db607b1ac4b70fc2a8878463e029c2ab1dc Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:15 -0600 +Subject: [PATCH] tests/04update-metadata: avoid passing chunk size to raid1 +
[OE-core] [kirkstone][PATCH v2] mdadm: Fix raid0 tests
From: Mingli Yu Backport patches to fix raid0 tests: tests/00raid0 tests/00readonly tests/03r0assem tests/04r0update tests/04update-metadata Signed-off-by: Mingli Yu --- ...d-a-test-that-validates-raid0-with-l.patch | 41 +++ ...-Run-udevadm-settle-before-setting-r.patch | 39 +++ ...metadata-avoid-passing-chunk-size-to.patch | 41 +++ ...ts-fix-raid0-tests-for-0.90-metadata.patch | 102 ++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 4 + 5 files changed, 227 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch diff --git a/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch b/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch new file mode 100644 index 00..1c95834a7e --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-00raid0-add-a-test-that-validates-raid0-with-l.patch @@ -0,0 +1,41 @@ +From 7539254342bc591717b0051734cc6c09c1b88640 Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:13 -0600 +Subject: [PATCH] tests/00raid0: add a test that validates raid0 with layout + fails for 0.9 + +329dfc28debb disallows the creation of raid0 with layouts for 0.9 +metadata. This test confirms the new behavior. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=7539254342bc591717b0051734cc6c09c1b88640] + +Signed-off-by: Sudhakar Panneerselvam +Signed-off-by: Himanshu Madhani +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/00raid0 | 6 ++ + 1 file changed, 2 insertions(+), 4 deletions(-) + +diff --git a/tests/00raid0 b/tests/00raid0 +index 8bc18985..e6b21cc4 100644 +--- a/tests/00raid0 b/tests/00raid0 +@@ -6,11 +6,9 @@ check raid0 + testdev $md0 3 $mdsize2_l 512 + mdadm -S $md0 + +-# now with version-0.90 superblock ++# verify raid0 with layouts fail for 0.90 + mdadm -CR $md0 -e0.90 -l0 -n4 $dev0 $dev1 $dev2 $dev3 +-check raid0 +-testdev $md0 4 $mdsize0 512 +-mdadm -S $md0 ++check opposite_result + + # now with no superblock + mdadm -B $md0 -l0 -n5 $dev0 $dev1 $dev2 $dev3 $dev4 +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch new file mode 100644 index 00..c621c082e8 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch @@ -0,0 +1,39 @@ +From 39b381252c32275079344d30de18b76fda4bba26 Mon Sep 17 00:00:00 2001 +From: Logan Gunthorpe +Date: Wed, 27 Jul 2022 15:52:45 -0600 +Subject: [PATCH] tests/00readonly: Run udevadm settle before setting ro + +In some recent kernel versions, 00readonly fails with: + + mdadm: failed to set readonly for /dev/md0: Device or resource busy + ERROR: array is not read-only! + +This was traced down to a race condition with udev holding a reference +to the block device at the same time as trying to set it read only. + +To fix this, call udevadm settle before setting the array read only. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=39b381252c32275079344d30de18b76fda4bba26] + +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/00readonly | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/tests/00readonly b/tests/00readonly +index 39202487..afe243b3 100644 +--- a/tests/00readonly b/tests/00readonly +@@ -12,6 +12,7 @@ do + $dev1 $dev2 $dev3 $dev4 --assume-clean + check nosync + check $level ++ udevadm settle + mdadm -ro $md0 + check readonly + state=$(cat /sys/block/md0/md/array_state) +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch new file mode 100644 index 00..9098fb2540 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch @@ -0,0 +1,41 @@ +From de045db607b1ac4b70fc2a8878463e029c2ab1dc Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:15 -0600 +Subject: [PATCH] tests/04update-metadata: avoid passing chunk size to raid1 +
[OE-core] [kirkstone][PATCH 3/3] mdadm: Fix raid0 tests
From: Mingli Yu Backport patches to fix raid0 tests: tests/00raid0 tests/00readonly tests/03r0assem tests/04r0update tests/04update-metadata Signed-off-by: Mingli Yu --- ...-Run-udevadm-settle-before-setting-r.patch | 39 +++ ...metadata-avoid-passing-chunk-size-to.patch | 41 +++ ...ts-fix-raid0-tests-for-0.90-metadata.patch | 102 ++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 3 + 4 files changed, 185 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch diff --git a/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch new file mode 100644 index 00..c621c082e8 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch @@ -0,0 +1,39 @@ +From 39b381252c32275079344d30de18b76fda4bba26 Mon Sep 17 00:00:00 2001 +From: Logan Gunthorpe +Date: Wed, 27 Jul 2022 15:52:45 -0600 +Subject: [PATCH] tests/00readonly: Run udevadm settle before setting ro + +In some recent kernel versions, 00readonly fails with: + + mdadm: failed to set readonly for /dev/md0: Device or resource busy + ERROR: array is not read-only! + +This was traced down to a race condition with udev holding a reference +to the block device at the same time as trying to set it read only. + +To fix this, call udevadm settle before setting the array read only. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=39b381252c32275079344d30de18b76fda4bba26] + +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/00readonly | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/tests/00readonly b/tests/00readonly +index 39202487..afe243b3 100644 +--- a/tests/00readonly b/tests/00readonly +@@ -12,6 +12,7 @@ do + $dev1 $dev2 $dev3 $dev4 --assume-clean + check nosync + check $level ++ udevadm settle + mdadm -ro $md0 + check readonly + state=$(cat /sys/block/md0/md/array_state) +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch new file mode 100644 index 00..9098fb2540 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch @@ -0,0 +1,41 @@ +From de045db607b1ac4b70fc2a8878463e029c2ab1dc Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:15 -0600 +Subject: [PATCH] tests/04update-metadata: avoid passing chunk size to raid1 + +'04update-metadata' test fails with error, "specifying chunk size is +forbidden for this level" added by commit, 5b30a34aa4b5e. Hence, +correcting the test to ignore passing chunk size to raid1. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=de045db607b1ac4b70fc2a8878463e029c2ab1dc] + +Signed-off-by: Sudhakar Panneerselvam +Signed-off-by: Himanshu Madhani +[log...@deltatee.com: fix if/then style and dropped unrelated hunk] +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/04update-metadata | 6 +- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/tests/04update-metadata b/tests/04update-metadata +index 08c14af7..2b72a303 100644 +--- a/tests/04update-metadata b/tests/04update-metadata +@@ -11,7 +11,11 @@ dlist="$dev0 $dev1 $dev2 $dev3" + for ls in linear/4 raid1/1 raid5/3 raid6/2 + do + s=${ls#*/} l=${ls%/*} +- mdadm -CR --assume-clean -e 0.90 $md0 --level $l -n 4 -c 64 $dlist ++ if [[ $l == 'raid1' ]]; then ++ mdadm -CR --assume-clean -e 0.90 $md0 --level $l -n 4 $dlist ++ else ++ mdadm -CR --assume-clean -e 0.90 $md0 --level $l -n 4 -c 64 $dlist ++ fi + testdev $md0 $s 19904 64 + mdadm -S $md0 + mdadm -A $md0 --update=metadata $dlist +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch b/meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch new file mode 100644 index 00..d2e7d8ee50 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch @@ -0,0 +1,102 @@ +From 14c2161edb77d7294199e8aa7daa9f9d1d0ad5d7 Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:14 -0600 +Subject: [PATCH]
[OE-core] [kirkstone][PATCH 1/3] mdadm: Fix testcase 06wrmostly
From: Mingli Yu Backport patch [1] to fix the failure of the 06wrmostly test. [1] https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=41edf6f45895193f4a523cb0a08d639c9ff9ccc9 Signed-off-by: Mingli Yu --- ...-Fix-optional-write-behind-parameter.patch | 45 +++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 1 + 2 files changed, 46 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch diff --git a/meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch b/meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch new file mode 100644 index 00..186d1e76f2 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch @@ -0,0 +1,45 @@ +From 41edf6f45895193f4a523cb0a08d639c9ff9ccc9 Mon Sep 17 00:00:00 2001 +From: Logan Gunthorpe +Date: Wed, 22 Jun 2022 14:25:12 -0600 +Subject: [PATCH] mdadm: Fix optional --write-behind parameter + +The commit noted below changed the behaviour of --write-behind to +require an argument. This broke the 06wrmostly test with the error: + + mdadm: Invalid value for maximum outstanding write-behind writes: (null). + Must be between 0 and 16383. + +To fix this, check if optarg is NULL before parising it, as the origial +code did. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=41edf6f45895193f4a523cb0a08d639c9ff9ccc9] + +Fixes: 60815698c0ac ("Refactor parse_num and use it to parse optarg.") +Cc: Mateusz Grzonka +Signed-off-by: Logan Gunthorpe +Acked-by: Mariusz Tkaczyk +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + mdadm.c | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/mdadm.c b/mdadm.c +index d0c5e6de..56722ed9 100644 +--- a/mdadm.c b/mdadm.c +@@ -1201,8 +1201,9 @@ int main(int argc, char *argv[]) + case O(BUILD, WriteBehind): + case O(CREATE, WriteBehind): + s.write_behind = DEFAULT_MAX_WRITE_BEHIND; +- if (parse_num(_behind, optarg) != 0 || +- s.write_behind < 0 || s.write_behind > 16383) { ++ if (optarg && ++ (parse_num(_behind, optarg) != 0 || ++ s.write_behind < 0 || s.write_behind > 16383)) { + pr_err("Invalid value for maximum outstanding write-behind writes: %s.\n\tMust be between 0 and 16383.\n", + optarg); + exit(2); +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/mdadm_4.2.bb b/meta/recipes-extended/mdadm/mdadm_4.2.bb index 19035caaec..be08d512d7 100644 --- a/meta/recipes-extended/mdadm/mdadm_4.2.bb +++ b/meta/recipes-extended/mdadm/mdadm_4.2.bb @@ -24,6 +24,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \ file://0001-mdadm-skip-test-11spare-migration.patch \ file://0001-Fix-parsing-of-r-in-monitor-manager-mode.patch \ file://0001-Makefile-install-mdcheck.patch \ + file://0001-mdadm-Fix-optional-write-behind-parameter.patch \ " SRC_URI[sha256sum] = "461c215670864bb74a4d1a3620684aa2b2f8296dffa06743f26dda5557acf01d" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#178686): https://lists.openembedded.org/g/openembedded-core/message/178686 Mute This Topic: https://lists.openembedded.org/mt/97646566/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 2/3] mdadm: fix tests/02lineargrow
From: Mingli Yu Backport patch [1] to fix tests/02lineargrow. [1] https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=a2c832465fc75202e244327b2081231dfa974617 Signed-off-by: Mingli Yu --- ...ow-clear-the-superblock-at-every-ite.patch | 33 +++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 1 + 2 files changed, 34 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch diff --git a/meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch b/meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch new file mode 100644 index 00..1a7104b76d --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch @@ -0,0 +1,33 @@ +From a2c832465fc75202e244327b2081231dfa974617 Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:16 -0600 +Subject: [PATCH] tests/02lineargrow: clear the superblock at every iteration + +This fixes 02lineargrow test as prior metadata causes --add operation +to misbehave. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=a2c832465fc75202e244327b2081231dfa974617] + +Signed-off-by: Sudhakar Panneerselvam +Signed-off-by: Himanshu Madhani +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/02lineargrow | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/tests/02lineargrow b/tests/02lineargrow +index e05c219d..595bf9f2 100644 +--- a/tests/02lineargrow b/tests/02lineargrow +@@ -20,4 +20,6 @@ do + testdev $md0 3 $sz 1 + + mdadm -S $md0 ++ mdadm --zero /dev/loop2 ++ mdadm --zero /dev/loop3 + done +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/mdadm_4.2.bb b/meta/recipes-extended/mdadm/mdadm_4.2.bb index be08d512d7..120c7f582b 100644 --- a/meta/recipes-extended/mdadm/mdadm_4.2.bb +++ b/meta/recipes-extended/mdadm/mdadm_4.2.bb @@ -25,6 +25,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \ file://0001-Fix-parsing-of-r-in-monitor-manager-mode.patch \ file://0001-Makefile-install-mdcheck.patch \ file://0001-mdadm-Fix-optional-write-behind-parameter.patch \ + file://0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch \ " SRC_URI[sha256sum] = "461c215670864bb74a4d1a3620684aa2b2f8296dffa06743f26dda5557acf01d" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#178687): https://lists.openembedded.org/g/openembedded-core/message/178687 Mute This Topic: https://lists.openembedded.org/mt/97646568/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 3/3] mdadm: Fix raid0 tests
From: Mingli Yu Backport patches to fix raid0 tests: tests/00raid0 tests/00readonly tests/03r0assem tests/04r0update tests/04update-metadata Signed-off-by: Mingli Yu --- ...-Run-udevadm-settle-before-setting-r.patch | 39 +++ ...metadata-avoid-passing-chunk-size-to.patch | 41 +++ ...ts-fix-raid0-tests-for-0.90-metadata.patch | 102 ++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 3 + 4 files changed, 185 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch diff --git a/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch new file mode 100644 index 00..c621c082e8 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-00readonly-Run-udevadm-settle-before-setting-r.patch @@ -0,0 +1,39 @@ +From 39b381252c32275079344d30de18b76fda4bba26 Mon Sep 17 00:00:00 2001 +From: Logan Gunthorpe +Date: Wed, 27 Jul 2022 15:52:45 -0600 +Subject: [PATCH] tests/00readonly: Run udevadm settle before setting ro + +In some recent kernel versions, 00readonly fails with: + + mdadm: failed to set readonly for /dev/md0: Device or resource busy + ERROR: array is not read-only! + +This was traced down to a race condition with udev holding a reference +to the block device at the same time as trying to set it read only. + +To fix this, call udevadm settle before setting the array read only. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=39b381252c32275079344d30de18b76fda4bba26] + +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/00readonly | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/tests/00readonly b/tests/00readonly +index 39202487..afe243b3 100644 +--- a/tests/00readonly b/tests/00readonly +@@ -12,6 +12,7 @@ do + $dev1 $dev2 $dev3 $dev4 --assume-clean + check nosync + check $level ++ udevadm settle + mdadm -ro $md0 + check readonly + state=$(cat /sys/block/md0/md/array_state) +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch new file mode 100644 index 00..9098fb2540 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-04update-metadata-avoid-passing-chunk-size-to.patch @@ -0,0 +1,41 @@ +From de045db607b1ac4b70fc2a8878463e029c2ab1dc Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:15 -0600 +Subject: [PATCH] tests/04update-metadata: avoid passing chunk size to raid1 + +'04update-metadata' test fails with error, "specifying chunk size is +forbidden for this level" added by commit, 5b30a34aa4b5e. Hence, +correcting the test to ignore passing chunk size to raid1. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=de045db607b1ac4b70fc2a8878463e029c2ab1dc] + +Signed-off-by: Sudhakar Panneerselvam +Signed-off-by: Himanshu Madhani +[log...@deltatee.com: fix if/then style and dropped unrelated hunk] +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/04update-metadata | 6 +- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/tests/04update-metadata b/tests/04update-metadata +index 08c14af7..2b72a303 100644 +--- a/tests/04update-metadata b/tests/04update-metadata +@@ -11,7 +11,11 @@ dlist="$dev0 $dev1 $dev2 $dev3" + for ls in linear/4 raid1/1 raid5/3 raid6/2 + do + s=${ls#*/} l=${ls%/*} +- mdadm -CR --assume-clean -e 0.90 $md0 --level $l -n 4 -c 64 $dlist ++ if [[ $l == 'raid1' ]]; then ++ mdadm -CR --assume-clean -e 0.90 $md0 --level $l -n 4 $dlist ++ else ++ mdadm -CR --assume-clean -e 0.90 $md0 --level $l -n 4 -c 64 $dlist ++ fi + testdev $md0 $s 19904 64 + mdadm -S $md0 + mdadm -A $md0 --update=metadata $dlist +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch b/meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch new file mode 100644 index 00..d2e7d8ee50 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-fix-raid0-tests-for-0.90-metadata.patch @@ -0,0 +1,102 @@ +From 14c2161edb77d7294199e8aa7daa9f9d1d0ad5d7 Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:14 -0600 +Subject: [PATCH]
[OE-core] [PATCH 1/3] mdadm: Fix testcase 06wrmostly
From: Mingli Yu Backport patch [1] to fix the failure of the 06wrmostly test. [1] https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=41edf6f45895193f4a523cb0a08d639c9ff9ccc9 Signed-off-by: Mingli Yu --- ...-Fix-optional-write-behind-parameter.patch | 45 +++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 1 + 2 files changed, 46 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch diff --git a/meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch b/meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch new file mode 100644 index 00..186d1e76f2 --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-mdadm-Fix-optional-write-behind-parameter.patch @@ -0,0 +1,45 @@ +From 41edf6f45895193f4a523cb0a08d639c9ff9ccc9 Mon Sep 17 00:00:00 2001 +From: Logan Gunthorpe +Date: Wed, 22 Jun 2022 14:25:12 -0600 +Subject: [PATCH] mdadm: Fix optional --write-behind parameter + +The commit noted below changed the behaviour of --write-behind to +require an argument. This broke the 06wrmostly test with the error: + + mdadm: Invalid value for maximum outstanding write-behind writes: (null). + Must be between 0 and 16383. + +To fix this, check if optarg is NULL before parising it, as the origial +code did. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=41edf6f45895193f4a523cb0a08d639c9ff9ccc9] + +Fixes: 60815698c0ac ("Refactor parse_num and use it to parse optarg.") +Cc: Mateusz Grzonka +Signed-off-by: Logan Gunthorpe +Acked-by: Mariusz Tkaczyk +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + mdadm.c | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/mdadm.c b/mdadm.c +index d0c5e6de..56722ed9 100644 +--- a/mdadm.c b/mdadm.c +@@ -1201,8 +1201,9 @@ int main(int argc, char *argv[]) + case O(BUILD, WriteBehind): + case O(CREATE, WriteBehind): + s.write_behind = DEFAULT_MAX_WRITE_BEHIND; +- if (parse_num(_behind, optarg) != 0 || +- s.write_behind < 0 || s.write_behind > 16383) { ++ if (optarg && ++ (parse_num(_behind, optarg) != 0 || ++ s.write_behind < 0 || s.write_behind > 16383)) { + pr_err("Invalid value for maximum outstanding write-behind writes: %s.\n\tMust be between 0 and 16383.\n", + optarg); + exit(2); +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/mdadm_4.2.bb b/meta/recipes-extended/mdadm/mdadm_4.2.bb index 1c4397509b..cef9e18843 100644 --- a/meta/recipes-extended/mdadm/mdadm_4.2.bb +++ b/meta/recipes-extended/mdadm/mdadm_4.2.bb @@ -26,6 +26,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \ file://0001-Makefile-install-mdcheck.patch \ file://0001-restripe.c-Use-_FILE_OFFSET_BITS-to-enable-largefile.patch \ file://0001-Define-alignof-using-_Alignof-when-using-C11-or-newe.patch \ + file://0001-mdadm-Fix-optional-write-behind-parameter.patch \ " SRC_URI[sha256sum] = "461c215670864bb74a4d1a3620684aa2b2f8296dffa06743f26dda5557acf01d" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#178678): https://lists.openembedded.org/g/openembedded-core/message/178678 Mute This Topic: https://lists.openembedded.org/mt/97646400/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 2/3] mdadm: fix tests/02lineargrow
From: Mingli Yu Backport patch [1] to fix tests/02lineargrow. [1] https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=a2c832465fc75202e244327b2081231dfa974617 Signed-off-by: Mingli Yu --- ...ow-clear-the-superblock-at-every-ite.patch | 33 +++ meta/recipes-extended/mdadm/mdadm_4.2.bb | 1 + 2 files changed, 34 insertions(+) create mode 100644 meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch diff --git a/meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch b/meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch new file mode 100644 index 00..1a7104b76d --- /dev/null +++ b/meta/recipes-extended/mdadm/files/0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch @@ -0,0 +1,33 @@ +From a2c832465fc75202e244327b2081231dfa974617 Mon Sep 17 00:00:00 2001 +From: Sudhakar Panneerselvam +Date: Wed, 22 Jun 2022 14:25:16 -0600 +Subject: [PATCH] tests/02lineargrow: clear the superblock at every iteration + +This fixes 02lineargrow test as prior metadata causes --add operation +to misbehave. + +Upstream-Status: Backport [https://git.kernel.org/pub/scm/utils/mdadm/mdadm.git/commit/?id=a2c832465fc75202e244327b2081231dfa974617] + +Signed-off-by: Sudhakar Panneerselvam +Signed-off-by: Himanshu Madhani +Signed-off-by: Logan Gunthorpe +Signed-off-by: Jes Sorensen +Signed-off-by: Mingli Yu +--- + tests/02lineargrow | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/tests/02lineargrow b/tests/02lineargrow +index e05c219d..595bf9f2 100644 +--- a/tests/02lineargrow b/tests/02lineargrow +@@ -20,4 +20,6 @@ do + testdev $md0 3 $sz 1 + + mdadm -S $md0 ++ mdadm --zero /dev/loop2 ++ mdadm --zero /dev/loop3 + done +-- +2.25.1 + diff --git a/meta/recipes-extended/mdadm/mdadm_4.2.bb b/meta/recipes-extended/mdadm/mdadm_4.2.bb index cef9e18843..b5fbc5b18e 100644 --- a/meta/recipes-extended/mdadm/mdadm_4.2.bb +++ b/meta/recipes-extended/mdadm/mdadm_4.2.bb @@ -27,6 +27,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \ file://0001-restripe.c-Use-_FILE_OFFSET_BITS-to-enable-largefile.patch \ file://0001-Define-alignof-using-_Alignof-when-using-C11-or-newe.patch \ file://0001-mdadm-Fix-optional-write-behind-parameter.patch \ + file://0001-tests-02lineargrow-clear-the-superblock-at-every-ite.patch \ " SRC_URI[sha256sum] = "461c215670864bb74a4d1a3620684aa2b2f8296dffa06743f26dda5557acf01d" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#178679): https://lists.openembedded.org/g/openembedded-core/message/178679 Mute This Topic: https://lists.openembedded.org/mt/97646401/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 v2] curl: Add fix for CVE-2023-23914, CVE-2023-23915
From: Pawan Badganchi Add below patches to fix CVE-2023-23914 [1], CVE-2023-23915 [2] CVE-2023-23914_5-1.patch CVE-2023-23914_5-2.patch CVE-2023-23914_5-3.patch CVE-2023-23914_5-4.patch CVE-2023-23914_5-5.patch [1] https://curl.se/docs/CVE-2023-23914.html [2] https://curl.se/docs/CVE-2023-23915.html Signed-off-by: Pawan Badganchi Signed-off-by: pawan Signed-off-by: Mingli Yu --- .../curl/curl/CVE-2023-23914_5-1.patch| 305 ++ .../curl/curl/CVE-2023-23914_5-2.patch| 23 ++ .../curl/curl/CVE-2023-23914_5-3.patch| 45 +++ .../curl/curl/CVE-2023-23914_5-4.patch| 48 +++ .../curl/curl/CVE-2023-23914_5-5.patch| 118 +++ meta/recipes-support/curl/curl_7.82.0.bb | 5 + 6 files changed, 544 insertions(+) create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-2.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-3.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-4.patch create mode 100644 meta/recipes-support/curl/curl/CVE-2023-23914_5-5.patch diff --git a/meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch b/meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch new file mode 100644 index 00..94a2264a9f --- /dev/null +++ b/meta/recipes-support/curl/curl/CVE-2023-23914_5-1.patch @@ -0,0 +1,305 @@ +From 076a2f629119222aeeb50f5a03bf9f9052fabb9a Mon Sep 17 00:00:00 2001 +From: Daniel Stenberg +Date: Tue, 27 Dec 2022 11:50:20 +0100 +Subject: [PATCH] share: add sharing of HSTS cache among handles + +Closes #10138 + +CVE: CVE-2023-23914 CVE-2023-23915 +Upstream-Status: Backport [https://github.com/curl/curl/commit/076a2f629119222aeeb50f5a03bf9f9052fabb9a] +Comment: Refreshed hunk from hsts.c and urldata.h +Signed-off-by: Pawan Badganchi +Signed-off-by: Mingli Yu +--- + docs/libcurl/opts/CURLSHOPT_SHARE.3 | 4 +++ + docs/libcurl/symbols-in-versions| 1 + + include/curl/curl.h | 1 + + lib/hsts.c | 15 + + lib/hsts.h | 2 ++ + lib/setopt.c| 48 - + lib/share.c | 32 +-- + lib/share.h | 6 +++- + lib/transfer.c | 3 ++ + lib/url.c | 6 +++- + lib/urldata.h | 2 ++ + 11 files changed, 109 insertions(+), 11 deletions(-) + +--- a/docs/libcurl/opts/CURLSHOPT_SHARE.3 b/docs/libcurl/opts/CURLSHOPT_SHARE.3 +@@ -79,6 +79,10 @@ Added in 7.61.0. + + Note that when you use the multi interface, all easy handles added to the same + multi handle will share PSL cache by default without using this option. ++.IP CURL_LOCK_DATA_HSTS ++The in-memory HSTS cache. ++ ++Added in 7.88.0 + .SH PROTOCOLS + All + .SH EXAMPLE +--- a/docs/libcurl/symbols-in-versions b/docs/libcurl/symbols-in-versions +@@ -73,6 +73,7 @@ CURL_LOCK_ACCESS_SINGLE 7.10.3 + CURL_LOCK_DATA_CONNECT 7.10.3 + CURL_LOCK_DATA_COOKIE 7.10.3 + CURL_LOCK_DATA_DNS 7.10.3 ++CURL_LOCK_DATA_HSTS 7.88.0 + CURL_LOCK_DATA_NONE 7.10.3 + CURL_LOCK_DATA_PSL 7.61.0 + CURL_LOCK_DATA_SHARE7.10.4 +--- a/include/curl/curl.h b/include/curl/curl.h +@@ -2953,6 +2953,7 @@ typedef enum { + CURL_LOCK_DATA_SSL_SESSION, + CURL_LOCK_DATA_CONNECT, + CURL_LOCK_DATA_PSL, ++ CURL_LOCK_DATA_HSTS, + CURL_LOCK_DATA_LAST + } curl_lock_data; + +--- a/lib/hsts.c b/lib/hsts.c +@@ -37,6 +37,7 @@ + #include "parsedate.h" + #include "rand.h" + #include "rename.h" ++#include "share.h" + #include "strtoofft.h" + + /* The last 3 #include files should be in this order */ +@@ -561,4 +562,18 @@ + return CURLE_OK; + } + ++void Curl_hsts_loadfiles(struct Curl_easy *data) ++{ ++ struct curl_slist *l = data->set.hstslist; ++ if(l) { ++Curl_share_lock(data, CURL_LOCK_DATA_HSTS, CURL_LOCK_ACCESS_SINGLE); ++ ++while(l) { ++ (void)Curl_hsts_loadfile(data, data->hsts, l->data); ++ l = l->next; ++} ++Curl_share_unlock(data, CURL_LOCK_DATA_HSTS); ++ } ++} ++ + #endif /* CURL_DISABLE_HTTP || CURL_DISABLE_HSTS */ +--- a/lib/hsts.h b/lib/hsts.h +@@ -59,9 +59,11 @@ CURLcode Curl_hsts_loadfile(struct Curl_ + struct hsts *h, const char *file); + CURLcode Curl_hsts_loadcb(struct Curl_easy *data, + struct hsts *h); ++void Curl_hsts_loadfiles(struct Curl_easy *data); + #else + #define Curl_hsts_cleanup(x) + #define Curl_hsts_loadcb(x,y) CURLE_OK + #define Curl_hsts_save(x,y,z) ++#define Curl_hsts_loadfiles(x) + #endif /* CURL_DISABLE_HTTP || CURL_DISABLE_HSTS */ + #endif /* HEADER_CURL_HSTS_H */ +--- a/lib/setopt.c b/lib/setopt.c +@@ -2260,9 +2260,14 @@ CURLcode Curl_vsetopt(struct Curl_easy * + data->cookies = NULL; + #endif + ++#ifndef
[OE-core] [PATCH] mc: set ac_cv_path_PERL_FOR_BUILD
From: Mingli Yu After mc upgrade to 4.8.29, it introduces PERL_FOR_BUILD [1] and will result in the below build failure on some system when we build under a project with long path. | make[4]: Entering directory '/buildarea2/WTEST_Regression/Rerun/build_dir/02161802-multilib_pkgs_conflict/qemux86-64-standard-std-OE/build1/tmp-glibc/work/core2-64-wrs-linux/mc/4.8.29-r0/build/doc/hlp/es' make[4]: Nothing to be done for 'install-exec-am'. | ../../../src/man2hlp/man2hlp ../../../doc/man/es/mc.1 ../../../../mc-4.8.29/doc/hlp/es/xnc.hlp mc.hlp.es | ../../../src/man2hlp/man2hlp: line 32: use: command not found | ../../../src/man2hlp/man2hlp: line 33: use: command not found | ../../../src/man2hlp/man2hlp: line 36: syntax error near unexpected token `(' | ../../../src/man2hlp/man2hlp: line 36: `my %static = (' | make[4]: [Makefile:632: mc.hlp.es] Error 2 (ignored) $ head -n 5 tmp-glibc/work/core2-64-wrs-linux/mc/4.8.29-r0/build/src/man2hlp/man2hlp #! /buildarea2/WTEST_Regression/Rerun/build_dir/02161802-multilib_pkgs_conflict/qemux86-64-standard-std-OE/build1/tmp-glibc/hosttools/perl # # Man page to help file converter # Copyright (C) 1994, 1995, 1998, 2000, 2001, 2002, 2003, 2004, 2005, # 2007, 2010, 2011 It's beacause the shebang line exceeds 128 which is usually the max length. So set ac_cv_path_PERL_FOR_BUILD to fix the above issue and altogether to remove the build path issue. [1] https://github.com/MidnightCommander/mc/commit/6b67d231a2f447cf5f33180c618c2a67849e6d15 Signed-off-by: Mingli Yu --- meta/recipes-extended/mc/mc_4.8.29.bb | 1 + 1 file changed, 1 insertion(+) diff --git a/meta/recipes-extended/mc/mc_4.8.29.bb b/meta/recipes-extended/mc/mc_4.8.29.bb index c9db172183..7aac352ab5 100644 --- a/meta/recipes-extended/mc/mc_4.8.29.bb +++ b/meta/recipes-extended/mc/mc_4.8.29.bb @@ -32,6 +32,7 @@ EXTRA_OECONF = "--with-screen=ncurses --without-gpm-mouse --without-x --disable- EXTRANATIVEPATH += "file-native" CACHED_CONFIGUREVARS += "ac_cv_path_PERL='/usr/bin/env perl'" +CACHED_CONFIGUREVARS += "ac_cv_path_PERL_FOR_BUILD='/usr/bin/env perl'" CACHED_CONFIGUREVARS += "ac_cv_path_PYTHON='/usr/bin/env python'" CACHED_CONFIGUREVARS += "ac_cv_path_GREP='/usr/bin/env grep'" CACHED_CONFIGUREVARS += "mc_cv_have_zipinfo=yes" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#177603): https://lists.openembedded.org/g/openembedded-core/message/177603 Mute This Topic: https://lists.openembedded.org/mt/97178658/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] libportal: add opengl to REQUIRED_DISTRO_FEATURES
Ping. Thanks, On 1/9/23 17:10, Alexander Kanavin wrote: CAUTION: This email comes from a non Wind River email account! Do not click links or open attachments unless you recognize the sender and know the content is safe. On Mon, 9 Jan 2023 at 10:02, Yu, Mingli wrote: Sorry for noise! Originally, the patch is used to fix the yocto compliance issue. The libportal depends on gtk4 and there is a line "REQUIRED_DISTRO_FEATURES = "opengl"" as [1] in gtk4_4.8.2.bb. If not make opengl mandatory for libportal, how to solve the below yocto compliance issue? Any hints? ERROR: Nothing PROVIDES 'gtk4' (but /build/layers/oe-core/meta/recipes-gnome/libportal/libportal_0.6.bb DEPENDS on or otherwise requires it) gtk4 was skipped: missing required distro feature 'opengl' (not in DISTRO_FEATURES) ERROR: Required build target 'meta-world-pkgdata' has no buildable providers. Missing or unbuildable dependency chain was: ['meta-world-pkgdata', 'libportal', 'gtk4'] [1] https://git.openembedded.org/openembedded-core/tree/meta/recipes-gnome/gtk+/gtk4_4.8.2.bb#n55 Thanks for clarifying. Meanwhile there was a discussion in a different thread about this, so the patch is fine. Alex -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#177396): https://lists.openembedded.org/g/openembedded-core/message/177396 Mute This Topic: https://lists.openembedded.org/mt/96090762/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] glslang: branch rename master -> main
From: Mingli Yu Branch name is changed from master to main. Signed-off-by: Mingli Yu --- meta/recipes-graphics/glslang/glslang_1.3.236.0.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-graphics/glslang/glslang_1.3.236.0.bb b/meta/recipes-graphics/glslang/glslang_1.3.236.0.bb index 99eca6a6c1..22838dfc8c 100644 --- a/meta/recipes-graphics/glslang/glslang_1.3.236.0.bb +++ b/meta/recipes-graphics/glslang/glslang_1.3.236.0.bb @@ -9,7 +9,7 @@ LICENSE = "BSD-3-Clause & BSD-2-Clause & MIT & Apache-2.0 & GPL-3-with-bison-exc LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=2a2b5acd7bc4844964cfda45fe807dc3" SRCREV = "77551c429f86c0e077f26552b7c1c0f12a9f235e" -SRC_URI = "git://github.com/KhronosGroup/glslang.git;protocol=https;branch=master \ +SRC_URI = "git://github.com/KhronosGroup/glslang.git;protocol=https;branch=main \ file://0001-generate-glslang-pkg-config.patch" PE = "1" UPSTREAM_CHECK_GITTAGREGEX = "sdk-(?P\d+(\.\d+)+)" -- 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#176509): https://lists.openembedded.org/g/openembedded-core/message/176509 Mute This Topic: https://lists.openembedded.org/mt/96648451/21656 Group Owner: openembedded-core+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-