diff options
Diffstat (limited to 'poky/meta/recipes-devtools')
71 files changed, 822 insertions, 368 deletions
diff --git a/poky/meta/recipes-devtools/apt/apt_2.4.5.bb b/poky/meta/recipes-devtools/apt/apt_2.4.5.bb index 4b9f804039..ef85750b84 100644 --- a/poky/meta/recipes-devtools/apt/apt_2.4.5.bb +++ b/poky/meta/recipes-devtools/apt/apt_2.4.5.bb @@ -38,8 +38,6 @@ UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/a/apt/" # is considered stable, e.g. 1.0, 1.4, 1.8, 2.2, 2.6, etc. As there is no way # to express 'divisible by 4 plus 2' in regex (that I know of), let's hardcode a few. UPSTREAM_CHECK_REGEX = "[^\d\.](?P<pver>((2\.2)|(2\.6)|(3\.0)|(3\.4)|(3\.8)|(4\.2))(\.\d+)+)\.tar" -# needs be marked as unknown until 2.6 is out -UPSTREAM_VERSION_UNKNOWN = "1" inherit cmake perlnative bash-completion useradd @@ -126,6 +124,7 @@ do_install:append:class-native() { do_install:append:class-nativesdk() { customize_apt_conf_sample + rm -rf ${D}${localstatedir}/log } do_install:append:class-target() { diff --git a/poky/meta/recipes-devtools/binutils/binutils-2.39.inc b/poky/meta/recipes-devtools/binutils/binutils-2.39.inc index b040e57037..419571d56c 100644 --- a/poky/meta/recipes-devtools/binutils/binutils-2.39.inc +++ b/poky/meta/recipes-devtools/binutils/binutils-2.39.inc @@ -35,6 +35,7 @@ SRC_URI = "\ file://0014-CVE-2022-38128-1.patch \ file://0014-CVE-2022-38128-2.patch \ file://0014-CVE-2022-38128-3.patch \ + file://0015-CVE-2022-4285.patch \ " S = "${WORKDIR}/git" # Already in 2.39 branch diff --git a/poky/meta/recipes-devtools/binutils/binutils/0003-binutils-nativesdk-Search-for-alternative-ld.so.conf.patch b/poky/meta/recipes-devtools/binutils/binutils/0003-binutils-nativesdk-Search-for-alternative-ld.so.conf.patch index 4fe5520010..9c825df5ab 100644 --- a/poky/meta/recipes-devtools/binutils/binutils/0003-binutils-nativesdk-Search-for-alternative-ld.so.conf.patch +++ b/poky/meta/recipes-devtools/binutils/binutils/0003-binutils-nativesdk-Search-for-alternative-ld.so.conf.patch @@ -65,7 +65,7 @@ index bfa0d54753a..0d61a3209ec 100644 info.path = NULL; info.len = info.alloc = 0; - tmppath = concat (ld_sysroot, prefix, "/etc/ld.so.conf", -+ tmppath = concat (ld_sysconfdir, "/etc/ld.so.conf", ++ tmppath = concat (ld_sysconfdir, "/ld.so.conf", (const char *) NULL); if (!ldelf_parse_ld_so_conf (&info, tmppath)) { diff --git a/poky/meta/recipes-devtools/binutils/binutils/0015-CVE-2022-4285.patch b/poky/meta/recipes-devtools/binutils/binutils/0015-CVE-2022-4285.patch new file mode 100644 index 0000000000..46ec0b15a3 --- /dev/null +++ b/poky/meta/recipes-devtools/binutils/binutils/0015-CVE-2022-4285.patch @@ -0,0 +1,37 @@ +From 5c831a3c7f3ca98d6aba1200353311e1a1f84c70 Mon Sep 17 00:00:00 2001 +From: Nick Clifton <nickc@redhat.com> +Date: Wed, 19 Oct 2022 15:09:12 +0100 +Subject: [PATCH] Fix an illegal memory access when parsing an ELF file + containing corrupt symbol version information. + + PR 29699 + * elf.c (_bfd_elf_slurp_version_tables): Fail if the sh_info field + of the section header is zero. + +Upstream-Status: Backport +[https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=5c831a3c7f3ca98d6aba1200353311e1a1f84c70] + +Signed-off-by: Pgowda <pgowda.cve@gmail.com> +--- + bfd/ChangeLog | 6 ++++++ + bfd/elf.c | 4 +++- + 2 files changed, 9 insertions(+), 1 deletion(-) + +diff --git a/bfd/elf.c b/bfd/elf.c +index fe00e0f9189..7cd7febcf95 100644 +--- a/bfd/elf.c ++++ b/bfd/elf.c +@@ -8918,7 +8918,9 @@ _bfd_elf_slurp_version_tables (bfd *abfd, bool default_imported_symver) + bfd_set_error (bfd_error_file_too_big); + goto error_return_verref; + } +- elf_tdata (abfd)->verref = (Elf_Internal_Verneed *) bfd_alloc (abfd, amt); ++ if (amt == 0) ++ goto error_return_verref; ++ elf_tdata (abfd)->verref = (Elf_Internal_Verneed *) bfd_zalloc (abfd, amt); + if (elf_tdata (abfd)->verref == NULL) + goto error_return_verref; + +-- +2.31.1 + diff --git a/poky/meta/recipes-devtools/bootchart2/bootchart2/0001-bootchart2-support-usrmerge.patch b/poky/meta/recipes-devtools/bootchart2/bootchart2/0001-bootchart2-support-usrmerge.patch deleted file mode 100644 index 88597cf3a9..0000000000 --- a/poky/meta/recipes-devtools/bootchart2/bootchart2/0001-bootchart2-support-usrmerge.patch +++ /dev/null @@ -1,37 +0,0 @@ -From b6d1a1ff2de363b1b76c8c70f77ae56a4e4d4b56 Mon Sep 17 00:00:00 2001 -From: Changqing Li <changqing.li@windriver.com> -Date: Thu, 5 Sep 2019 18:37:31 +0800 -Subject: [PATCH] bootchart2: support usrmerge - -Upstream-Status: Inappropriate [oe-specific] - -Signed-off-by: Changqing Li <changqing.li@windriver.com> ---- - Makefile | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/Makefile b/Makefile -index 1cc2974..f988904 100644 ---- a/Makefile -+++ b/Makefile -@@ -36,7 +36,7 @@ endif - PY_SITEDIR ?= $(PY_LIBDIR)/site-packages - LIBC_A_PATH = /usr$(LIBDIR) - # Always lib, even on systems that otherwise use lib64 --SYSTEMD_UNIT_DIR = $(EARLY_PREFIX)/lib/systemd/system -+SYSTEMD_UNIT_DIR ?= $(EARLY_PREFIX)/lib/systemd/system - COLLECTOR = \ - collector/collector.o \ - collector/output.o \ -@@ -99,7 +99,7 @@ install-chroot: - install -d $(DESTDIR)$(PKGLIBDIR)/tmpfs - - install-collector: all install-chroot -- install -m 755 -D bootchartd $(DESTDIR)$(EARLY_PREFIX)/sbin/$(PROGRAM_PREFIX)bootchartd$(PROGRAM_SUFFIX) -+ install -m 755 -D bootchartd $(DESTDIR)${BASE_SBINDIR}/$(PROGRAM_PREFIX)bootchartd$(PROGRAM_SUFFIX) - install -m 644 -D bootchartd.conf $(DESTDIR)/etc/$(PROGRAM_PREFIX)bootchartd$(PROGRAM_SUFFIX).conf - install -m 755 -D bootchart-collector $(DESTDIR)$(PKGLIBDIR)/$(PROGRAM_PREFIX)bootchart$(PROGRAM_SUFFIX)-collector - --- -2.7.4 - diff --git a/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb b/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb index b4d5b7cd9b..297dbfb578 100644 --- a/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb +++ b/poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb @@ -93,7 +93,6 @@ UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.\d+)*)" SRC_URI = "git://github.com/xrmx/bootchart.git;branch=master;protocol=https \ file://bootchartd_stop.sh \ file://0001-collector-Allocate-space-on-heap-for-chunks.patch \ - file://0001-bootchart2-support-usrmerge.patch \ file://0001-bootchartd.in-make-sure-only-one-bootchartd-process.patch \ file://0001-Do-not-include-linux-fs.h.patch \ " @@ -120,12 +119,11 @@ UPDATERCPN = "bootchartd-stop-initscript" INITSCRIPT_NAME = "bootchartd_stop.sh" INITSCRIPT_PARAMS = "start 99 2 3 4 5 ." -EXTRA_OEMAKE = 'BASE_SBINDIR="${base_sbindir}"' - do_compile:prepend () { export PY_LIBDIR="${libdir}/${PYTHON_DIR}" export BINDIR="${bindir}" - export LIBDIR="${base_libdir}" + export LIBDIR="/${baselib}" + export EARLY_PREFIX="${root_prefix}" } do_install () { @@ -133,9 +131,8 @@ do_install () { export PY_LIBDIR="${libdir}/${PYTHON_DIR}" export BINDIR="${bindir}" export DESTDIR="${D}" - export LIBDIR="${base_libdir}" - export PKGLIBDIR="${base_libdir}/bootchart" - export SYSTEMD_UNIT_DIR="${systemd_system_unitdir}" + export LIBDIR="/${baselib}" + export EARLY_PREFIX="${root_prefix}" oe_runmake install NO_PYTHON_COMPILE=1 install -d ${D}${sysconfdir}/init.d diff --git a/poky/meta/recipes-devtools/cmake/cmake-native_3.24.0.bb b/poky/meta/recipes-devtools/cmake/cmake-native_3.24.2.bb index 722a486f20..bcc87eb8f2 100644 --- a/poky/meta/recipes-devtools/cmake/cmake-native_3.24.0.bb +++ b/poky/meta/recipes-devtools/cmake/cmake-native_3.24.2.bb @@ -32,6 +32,7 @@ CMAKE_EXTRACONF = "\ -DCMAKE_USE_SYSTEM_LIBRARY_EXPAT=0 \ -DENABLE_ACL=0 -DHAVE_ACL_LIBACL_H=0 \ -DHAVE_SYS_ACL_H=0 \ + -DCURL_LIBRARIES=-lcurl \ " do_configure () { diff --git a/poky/meta/recipes-devtools/cmake/cmake.inc b/poky/meta/recipes-devtools/cmake/cmake.inc index d64afffdc1..1ede8eee61 100644 --- a/poky/meta/recipes-devtools/cmake/cmake.inc +++ b/poky/meta/recipes-devtools/cmake/cmake.inc @@ -21,7 +21,7 @@ SRC_URI = "https://cmake.org/files/v${CMAKE_MAJOR_VERSION}/cmake-${PV}.tar.gz \ file://0004-Fail-silently-if-system-Qt-installation-is-broken.patch \ " -SRC_URI[sha256sum] = "c2b61f7cdecb1576cad25f918a8f42b8685d88a832fd4b62b9e0fa32e915a658" +SRC_URI[sha256sum] = "0d9020f06f3ddf17fb537dc228e1a56c927ee506b486f55fe2dc19f69bf0c8db" UPSTREAM_CHECK_REGEX = "cmake-(?P<pver>\d+(\.\d+)+)\.tar" diff --git a/poky/meta/recipes-devtools/cmake/cmake_3.24.0.bb b/poky/meta/recipes-devtools/cmake/cmake_3.24.2.bb index bb7ed83e30..bb7ed83e30 100644 --- a/poky/meta/recipes-devtools/cmake/cmake_3.24.0.bb +++ b/poky/meta/recipes-devtools/cmake/cmake_3.24.2.bb diff --git a/poky/meta/recipes-devtools/createrepo-c/createrepo-c/0001-include-rpm-rpmstring.h.patch b/poky/meta/recipes-devtools/createrepo-c/createrepo-c/0001-include-rpm-rpmstring.h.patch new file mode 100644 index 0000000000..a249eaf5a1 --- /dev/null +++ b/poky/meta/recipes-devtools/createrepo-c/createrepo-c/0001-include-rpm-rpmstring.h.patch @@ -0,0 +1,27 @@ +From 8defe6aaf91613c3fcb540df65a94cd56d377367 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Fri, 13 Jan 2023 13:21:51 -0800 +Subject: [PATCH 1/2] include rpm/rpmstring.h + +Its needed for rasprintf declaration + +Fixes +src/xml_file.c:341:36: error: call to undeclared functi +on 'rasprintf'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] + +Upstream-Status: Submitted [https://github.com/rpm-software-management/createrepo_c/pull/340] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + src/xml_file.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/src/xml_file.c ++++ b/src/xml_file.c +@@ -19,6 +19,7 @@ + + #include <glib.h> + #include <glib/gstdio.h> ++#include <rpm/rpmstring.h> + #include <assert.h> + #include "xml_file.h" + #include <errno.h> diff --git a/poky/meta/recipes-devtools/createrepo-c/createrepo-c_0.20.1.bb b/poky/meta/recipes-devtools/createrepo-c/createrepo-c_0.20.1.bb index d309bb895f..053198ca5e 100644 --- a/poky/meta/recipes-devtools/createrepo-c/createrepo-c_0.20.1.bb +++ b/poky/meta/recipes-devtools/createrepo-c/createrepo-c_0.20.1.bb @@ -6,6 +6,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" SRC_URI = "git://github.com/rpm-software-management/createrepo_c;branch=master;protocol=https \ file://0001-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch \ + file://0001-include-rpm-rpmstring.h.patch \ " SRCREV = "af14e164a3e4ab9dfaef1212e852b9ecebc326a2" diff --git a/poky/meta/recipes-devtools/fdisk/gptfdisk/0001-Updated-guid.cc-to-deal-with-minor-change-in-libuuid.patch b/poky/meta/recipes-devtools/fdisk/gptfdisk/0001-Updated-guid.cc-to-deal-with-minor-change-in-libuuid.patch new file mode 100644 index 0000000000..f358081092 --- /dev/null +++ b/poky/meta/recipes-devtools/fdisk/gptfdisk/0001-Updated-guid.cc-to-deal-with-minor-change-in-libuuid.patch @@ -0,0 +1,27 @@ +From c640d9011a8330ebaad501784fb0ee1ce5e7a5ef Mon Sep 17 00:00:00 2001 +From: Rod Smith <rodsmith@rodsbooks.com> +Date: Sat, 16 Apr 2022 09:32:04 -0400 +Subject: [PATCH] Updated guid.cc to deal with minor change in libuuid + +Upstream-Status: Backport [https://sourceforge.net/p/gptfdisk/code/ci/6a8416cbd12d55f882bb751993b94f72d338d96f/] +Signed-off-by: Peter Bergin <peter@berginkonsult.se> +--- + guid.cc | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/guid.cc b/guid.cc +index 1e73ab7..d3e4fd5 100644 +--- a/guid.cc ++++ b/guid.cc +@@ -141,7 +141,7 @@ void GUIDData::Zero(void) { + void GUIDData::Randomize(void) { + int i, uuidGenerated = 0; + +-#ifdef _UUID_UUID_H ++#if defined (_UUID_UUID_H) || defined (_UL_LIBUUID_UUID_H) + uuid_generate(uuidData); + ReverseBytes(&uuidData[0], 4); + ReverseBytes(&uuidData[4], 2); +-- +2.34.1 + diff --git a/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.9.bb b/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.9.bb index e473b9cd55..2c093c20ae 100644 --- a/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.9.bb +++ b/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.9.bb @@ -9,6 +9,7 @@ DEPENDS = "util-linux" SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${PV}/${BP}.tar.gz \ file://0001-gptcurses-correctly-include-curses.h.patch \ + file://0001-Updated-guid.cc-to-deal-with-minor-change-in-libuuid.patch \ " SRC_URI[sha256sum] = "dafead2693faeb8e8b97832b23407f6ed5b3219bc1784f482dd855774e2d50c2" diff --git a/poky/meta/recipes-devtools/gcc/gcc-shared-source.inc b/poky/meta/recipes-devtools/gcc/gcc-shared-source.inc index aac4b49313..03f520b093 100644 --- a/poky/meta/recipes-devtools/gcc/gcc-shared-source.inc +++ b/poky/meta/recipes-devtools/gcc/gcc-shared-source.inc @@ -9,3 +9,13 @@ SRC_URI = "" do_configure[depends] += "gcc-source-${PV}:do_preconfigure" do_populate_lic[depends] += "gcc-source-${PV}:do_unpack" +do_deploy_source_date_epoch[depends] += "gcc-source-${PV}:do_deploy_source_date_epoch" + +# Copy the SDE from the shared workdir to the recipe workdir +do_deploy_source_date_epoch () { + sde_file=${SDE_FILE} + sde_file=${sde_file#${WORKDIR}/} + mkdir -p ${SDE_DEPLOYDIR} $(dirname ${SDE_FILE}) + cp -p $(dirname ${S})/$sde_file ${SDE_DEPLOYDIR} + cp -p $(dirname ${S})/$sde_file ${SDE_FILE} +} diff --git a/poky/meta/recipes-devtools/gcc/gcc-source.inc b/poky/meta/recipes-devtools/gcc/gcc-source.inc index 224b7778ef..265bcf4bef 100644 --- a/poky/meta/recipes-devtools/gcc/gcc-source.inc +++ b/poky/meta/recipes-devtools/gcc/gcc-source.inc @@ -17,6 +17,13 @@ STAMPCLEAN = "${STAMPS_DIR}/work-shared/gcc-${PV}-*" INHIBIT_DEFAULT_DEPS = "1" DEPENDS = "" PACKAGES = "" +TARGET_ARCH = "allarch" +TARGET_AS_ARCH = "none" +TARGET_CC_ARCH = "none" +TARGET_LD_ARCH = "none" +TARGET_OS = "linux" +baselib = "lib" +PACKAGE_ARCH = "all" B = "${WORKDIR}/build" @@ -25,8 +32,6 @@ python do_preconfigure () { import subprocess cmd = d.expand('cd ${S} && PATH=${PATH} gnu-configize') subprocess.check_output(cmd, stderr=subprocess.STDOUT, shell=True) - # See 0044-gengtypes.patch, we need to regenerate this file - bb.utils.remove(d.expand("${S}/gcc/gengtype-lex.c")) cmd = d.expand("sed -i 's/BUILD_INFO=info/BUILD_INFO=/' ${S}/gcc/configure") subprocess.check_output(cmd, stderr=subprocess.STDOUT, shell=True) diff --git a/poky/meta/recipes-devtools/git/git_2.37.3.bb b/poky/meta/recipes-devtools/git/git_2.37.6.bb index 2eed85e807..302db215e2 100644 --- a/poky/meta/recipes-devtools/git/git_2.37.3.bb +++ b/poky/meta/recipes-devtools/git/git_2.37.6.bb @@ -31,6 +31,10 @@ CVE_PRODUCT = "git-scm:git" # in mirrored git repos. Most OE users wouldn't build the docs and # we don't see this as a major issue for our general users/usecases. CVE_CHECK_IGNORE += "CVE-2022-24975" +# This is specific to Git-for-Windows +CVE_CHECK_IGNORE += "CVE-2022-41953" +# specific to Git for Windows +CVE_CHECK_IGNORE += "CVE-2023-22743" PACKAGECONFIG ??= "expat curl" PACKAGECONFIG[cvsserver] = "" @@ -165,4 +169,4 @@ EXTRA_OECONF += "ac_cv_snprintf_returns_bogus=no \ " EXTRA_OEMAKE += "NO_GETTEXT=1" -SRC_URI[tarball.sha256sum] = "181f65587155ea48c682f63135678ec53055adf1532428752912d356e46b64a8" +SRC_URI[tarball.sha256sum] = "626e4c338f72b170e2b3afb1cb2161f6fbe4fb1d0749154f1ebfb5f0a57ec25f" diff --git a/poky/meta/recipes-devtools/go/go-1.19.inc b/poky/meta/recipes-devtools/go/go-1.19.7.inc index f733a807b4..7d76f34bdf 100644 --- a/poky/meta/recipes-devtools/go/go-1.19.inc +++ b/poky/meta/recipes-devtools/go/go-1.19.7.inc @@ -14,6 +14,5 @@ SRC_URI += "\ file://0001-exec.go-do-not-write-linker-flags-into-buildids.patch \ file://0001-src-cmd-dist-buildgo.go-do-not-hardcode-host-compile.patch \ file://filter-build-paths.patch \ - file://stack-protector.patch \ " -SRC_URI[main.sha256sum] = "9419cc70dc5a2523f29a77053cafff658ed21ef3561d9b6b020280ebceab28b9" +SRC_URI[main.sha256sum] = "775bdf285ceaba940da8a2fe20122500efd7a0b65dbcee85247854a8d7402633" diff --git a/poky/meta/recipes-devtools/go/go-binary-native_1.19.bb b/poky/meta/recipes-devtools/go/go-binary-native_1.19.7.bb index ca424a66b8..0e2c8f1b24 100644 --- a/poky/meta/recipes-devtools/go/go-binary-native_1.19.bb +++ b/poky/meta/recipes-devtools/go/go-binary-native_1.19.7.bb @@ -7,9 +7,10 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=5d4950ecb7b26d2c5e4e7b4e0dd74707" PROVIDES = "go-native" +# Checksums available at https://go.dev/dl/ SRC_URI = "https://dl.google.com/go/go${PV}.${BUILD_GOOS}-${BUILD_GOARCH}.tar.gz;name=go_${BUILD_GOTUPLE}" -SRC_URI[go_linux_amd64.sha256sum] = "464b6b66591f6cf055bc5df90a9750bf5fbc9d038722bb84a9d56a2bea974be6" -SRC_URI[go_linux_arm64.sha256sum] = "efa97fac9574fc6ef6c9ff3e3758fb85f1439b046573bf434cccb5e012bd00c8" +SRC_URI[go_linux_amd64.sha256sum] = "7a75720c9b066ae1750f6bcc7052aba70fa3813f4223199ee2a2315fd3eb533d" +SRC_URI[go_linux_arm64.sha256sum] = "071ea7bf386fdd08df524859b878d99fc359e491e7ad65c1c1cc55b67972c882" UPSTREAM_CHECK_URI = "https://golang.org/dl/" UPSTREAM_CHECK_REGEX = "go(?P<pver>\d+(\.\d+)+)\.linux" diff --git a/poky/meta/recipes-devtools/go/go-cross-canadian_1.19.bb b/poky/meta/recipes-devtools/go/go-cross-canadian_1.19.7.bb index 7ac9449e47..7ac9449e47 100644 --- a/poky/meta/recipes-devtools/go/go-cross-canadian_1.19.bb +++ b/poky/meta/recipes-devtools/go/go-cross-canadian_1.19.7.bb diff --git a/poky/meta/recipes-devtools/go/go-cross_1.19.bb b/poky/meta/recipes-devtools/go/go-cross_1.19.7.bb index 80b5a03f6c..80b5a03f6c 100644 --- a/poky/meta/recipes-devtools/go/go-cross_1.19.bb +++ b/poky/meta/recipes-devtools/go/go-cross_1.19.7.bb diff --git a/poky/meta/recipes-devtools/go/go-crosssdk.inc b/poky/meta/recipes-devtools/go/go-crosssdk.inc index cd23cca2fe..766938670a 100644 --- a/poky/meta/recipes-devtools/go/go-crosssdk.inc +++ b/poky/meta/recipes-devtools/go/go-crosssdk.inc @@ -4,6 +4,8 @@ DEPENDS = "go-native virtual/${TARGET_PREFIX}gcc-crosssdk virtual/nativesdk-${TA PN = "go-crosssdk-${SDK_SYS}" PROVIDES = "virtual/${TARGET_PREFIX}go-crosssdk" +export GOCACHE = "${B}/.cache" + do_configure[noexec] = "1" do_compile() { diff --git a/poky/meta/recipes-devtools/go/go-crosssdk_1.19.bb b/poky/meta/recipes-devtools/go/go-crosssdk_1.19.7.bb index 1857c8a577..1857c8a577 100644 --- a/poky/meta/recipes-devtools/go/go-crosssdk_1.19.bb +++ b/poky/meta/recipes-devtools/go/go-crosssdk_1.19.7.bb diff --git a/poky/meta/recipes-devtools/go/go-native_1.19.bb b/poky/meta/recipes-devtools/go/go-native_1.19.7.bb index ddf25b2c9b..ddf25b2c9b 100644 --- a/poky/meta/recipes-devtools/go/go-native_1.19.bb +++ b/poky/meta/recipes-devtools/go/go-native_1.19.7.bb diff --git a/poky/meta/recipes-devtools/go/go-runtime_1.19.bb b/poky/meta/recipes-devtools/go/go-runtime_1.19.7.bb index 63464a1501..63464a1501 100644 --- a/poky/meta/recipes-devtools/go/go-runtime_1.19.bb +++ b/poky/meta/recipes-devtools/go/go-runtime_1.19.7.bb diff --git a/poky/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch b/poky/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch index 8cbed93017..43be5cd2e8 100644 --- a/poky/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch +++ b/poky/meta/recipes-devtools/go/go/0001-cmd-go-make-content-based-hash-generation-less-pedan.patch @@ -1,4 +1,4 @@ -From a3db4da51df37d163ff9e8c1e1057280c648c545 Mon Sep 17 00:00:00 2001 +From fb22e586871cc6be0b7041e86d2daceee06ea568 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Mon, 28 Mar 2022 10:59:03 -0700 Subject: [PATCH] cmd/go: make content-based hash generation less pedantic @@ -32,13 +32,13 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com> 2 files changed, 34 insertions(+), 10 deletions(-) diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go -index 529351d..df791b0 100644 +index 81ee859..2db3898 100644 --- a/src/cmd/go/internal/envcmd/env.go +++ b/src/cmd/go/internal/envcmd/env.go @@ -176,7 +176,7 @@ func ExtraEnvVars() []cfg.EnvVar { func ExtraEnvVarsCostly() []cfg.EnvVar { - var b work.Builder - b.Init() + b := work.NewBuilder("") + - cppflags, cflags, cxxflags, fflags, ldflags, err := b.CFlags(&load.Package{}) + cppflags, cflags, cxxflags, fflags, ldflags, err := b.CFlags(&load.Package{}, false) if err != nil { @@ -74,7 +74,7 @@ index c88b315..a06455c 100644 + cppflags, cflags, cxxflags, fflags, ldflags, _ := b.CFlags(p, true) - ccExe := b.ccExe() -+ ccExe := filterCompilerFlags(b.ccExe()) ++ ccExe := filterCompilerFlags(b.ccExe(), true) fmt.Fprintf(h, "CC=%q %q %q %q\n", ccExe, cppflags, cflags, ldflags) // Include the C compiler tool ID so that if the C // compiler changes we rebuild the package. @@ -83,7 +83,7 @@ index c88b315..a06455c 100644 } if len(p.CXXFiles)+len(p.SwigCXXFiles) > 0 { - cxxExe := b.cxxExe() -+ cxxExe := filterCompilerFlags(b.cxxExe()) ++ cxxExe := filterCompilerFlags(b.cxxExe(), true) fmt.Fprintf(h, "CXX=%q %q\n", cxxExe, cxxflags) if cxxID, err := b.gccToolID(cxxExe[0], "c++"); err == nil { fmt.Fprintf(h, "CXX ID=%q\n", cxxID) @@ -91,7 +91,7 @@ index c88b315..a06455c 100644 } if len(p.FFiles) > 0 { - fcExe := b.fcExe() -+ fcExe := filterCompilerFlags(b.fcExe()) ++ fcExe := filterCompilerFlags(b.fcExe(), true) fmt.Fprintf(h, "FC=%q %q\n", fcExe, fflags) if fcID, err := b.gccToolID(fcExe[0], "f95"); err == nil { fmt.Fprintf(h, "FC ID=%q\n", fcID) @@ -104,20 +104,22 @@ index c88b315..a06455c 100644 } // Configuration specific to compiler toolchain. -@@ -2705,8 +2707,23 @@ func envList(key, def string) []string { +@@ -2705,8 +2707,25 @@ func envList(key, def string) []string { return args } +var filterFlags = os.Getenv("CGO_PEDANTIC") == "" + -+func filterCompilerFlags(flags []string) []string { ++func filterCompilerFlags(flags []string, keepfirst bool) []string { + var newflags []string ++ var realkeepfirst bool = keepfirst + if !filterFlags { + return flags + } + for _, flag := range flags { -+ if strings.HasPrefix(flag, "-m") { ++ if strings.HasPrefix(flag, "-m") || realkeepfirst { + newflags = append(newflags, flag) ++ realkeepfirst = false + } + } + return newflags @@ -129,21 +131,21 @@ index c88b315..a06455c 100644 defaults := "-g -O2" if cppflags, err = buildFlags("CPPFLAGS", "", p.CgoCPPFLAGS, checkCompilerFlags); err != nil { -@@ -2724,6 +2741,13 @@ func (b *Builder) CFlags(p *load.Package) (cppflags, cflags, cxxflags, fflags, l +@@ -2724,6 +2743,13 @@ func (b *Builder) CFlags(p *load.Package) (cppflags, cflags, cxxflags, fflags, l if ldflags, err = buildFlags("LDFLAGS", defaults, p.CgoLDFLAGS, checkLinkerFlags); err != nil { return } + if filtered { -+ cppflags = filterCompilerFlags(cppflags) -+ cflags = filterCompilerFlags(cflags) -+ cxxflags = filterCompilerFlags(cxxflags) -+ fflags = filterCompilerFlags(fflags) -+ ldflags = filterCompilerFlags(ldflags) ++ cppflags = filterCompilerFlags(cppflags, false) ++ cflags = filterCompilerFlags(cflags, false) ++ cxxflags = filterCompilerFlags(cxxflags, false) ++ fflags = filterCompilerFlags(fflags, false) ++ ldflags = filterCompilerFlags(ldflags, false) + } return } -@@ -2739,7 +2763,7 @@ var cgoRe = lazyregexp.New(`[/\\:]`) +@@ -2739,7 +2765,7 @@ var cgoRe = lazyregexp.New(`[/\\:]`) func (b *Builder) cgo(a *Action, cgoExe, objdir string, pcCFLAGS, pcLDFLAGS, cgofiles, gccfiles, gxxfiles, mfiles, ffiles []string) (outGo, outObj []string, err error) { p := a.Package @@ -152,7 +154,7 @@ index c88b315..a06455c 100644 if err != nil { return nil, nil, err } -@@ -3246,7 +3270,7 @@ func (b *Builder) swigIntSize(objdir string) (intsize string, err error) { +@@ -3246,7 +3272,7 @@ func (b *Builder) swigIntSize(objdir string) (intsize string, err error) { // Run SWIG on one SWIG input file. func (b *Builder) swigOne(a *Action, p *load.Package, file, objdir string, pcCFLAGS []string, cxx bool, intgosize string) (outGo, outC string, err error) { diff --git a/poky/meta/recipes-devtools/go/go/filter-build-paths.patch b/poky/meta/recipes-devtools/go/go/filter-build-paths.patch index a1aa37c2a4..280f911a21 100644 --- a/poky/meta/recipes-devtools/go/go/filter-build-paths.patch +++ b/poky/meta/recipes-devtools/go/go/filter-build-paths.patch @@ -8,7 +8,8 @@ embedded in the go binary so that builds are reproducible regardless of build location. This codepath is hit for statically linked go binaries such as those on mips/ppc. -Upstream-Status: Pending +Upstream-Status: Submitted [https://github.com/golang/go/pull/56410] + Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> --- diff --git a/poky/meta/recipes-devtools/go/go/stack-protector.patch b/poky/meta/recipes-devtools/go/go/stack-protector.patch deleted file mode 100644 index cc92a444a7..0000000000 --- a/poky/meta/recipes-devtools/go/go/stack-protector.patch +++ /dev/null @@ -1,32 +0,0 @@ -From c537b87782293fe222f2ef5eb1ae818092118e97 Mon Sep 17 00:00:00 2001 -From: Ian Lance Taylor <iant@golang.org> -Date: Sun, 07 Aug 2022 19:21:15 -0700 -Subject: [PATCH] runtime/cgo: add -fno-stack-protector to CFLAGS - -Some compilers default to having -fstack-protector on, which breaks -when using internal linking because the linker doesn't know how to -find the support functions. - -Fixes #52919 -Fixes #54313 - -Change-Id: I6f51d5e906503f61fc768ad8e30c163bad135087 -Upstream-Status: Submitted [https://github.com/golang/go/issues/54313] -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - -diff --git a/src/runtime/cgo/cgo.go b/src/runtime/cgo/cgo.go -index 298aa63..4b7046e 100644 ---- a/src/runtime/cgo/cgo.go -+++ b/src/runtime/cgo/cgo.go -@@ -23,7 +23,9 @@ - #cgo solaris LDFLAGS: -lxnet - #cgo solaris LDFLAGS: -lsocket - --#cgo CFLAGS: -Wall -Werror -+// We use -fno-stack-protector because internal linking won't find -+// the support functions. See issues #52919 and #54313. -+#cgo CFLAGS: -Wall -Werror -fno-stack-protector - - #cgo solaris CPPFLAGS: -D_POSIX_PTHREAD_SEMANTICS - diff --git a/poky/meta/recipes-devtools/go/go_1.19.bb b/poky/meta/recipes-devtools/go/go_1.19.7.bb index 98977673ee..587ee55944 100644 --- a/poky/meta/recipes-devtools/go/go_1.19.bb +++ b/poky/meta/recipes-devtools/go/go_1.19.7.bb @@ -12,7 +12,7 @@ export CXX_FOR_TARGET = "g++" # mips/rv64 doesn't support -buildmode=pie, so skip the QA checking for mips/riscv32 and its # variants. python() { - if 'mips' in d.getVar('TARGET_ARCH',True) or 'riscv32' in d.getVar('TARGET_ARCH',True): - d.appendVar('INSANE_SKIP:%s' % d.getVar('PN',True), " textrel") + if 'mips' in d.getVar('TARGET_ARCH') or 'riscv32' in d.getVar('TARGET_ARCH'): + d.appendVar('INSANE_SKIP:%s' % d.getVar('PN'), " textrel") } diff --git a/poky/meta/recipes-devtools/help2man/help2man_1.49.2.bb b/poky/meta/recipes-devtools/help2man/help2man_1.49.3.bb index 62e1f67b55..75931a511f 100644 --- a/poky/meta/recipes-devtools/help2man/help2man_1.49.2.bb +++ b/poky/meta/recipes-devtools/help2man/help2man_1.49.3.bb @@ -6,7 +6,7 @@ LICENSE = "GPL-3.0-only" LIC_FILES_CHKSUM = "file://COPYING;md5=1ebbd3e34237af26da5dc08a4e440464" SRC_URI = "${GNU_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz" -SRC_URI[sha256sum] = "9e2e0e213a7e0a36244eed6204d902b6504602a578b6ecd15268b1454deadd36" +SRC_URI[sha256sum] = "4d7e4fdef2eca6afe07a2682151cea78781e0a4e8f9622142d9f70c083a2fd4f" inherit autotools diff --git a/poky/meta/recipes-devtools/libcomps/libcomps/0001-libcomps-Use-Py_hash_t-instead-of-long-in-PyCOMPS_ha.patch b/poky/meta/recipes-devtools/libcomps/libcomps/0001-libcomps-Use-Py_hash_t-instead-of-long-in-PyCOMPS_ha.patch new file mode 100644 index 0000000000..dd9ebc8af4 --- /dev/null +++ b/poky/meta/recipes-devtools/libcomps/libcomps/0001-libcomps-Use-Py_hash_t-instead-of-long-in-PyCOMPS_ha.patch @@ -0,0 +1,66 @@ +From 26a9647c832de15248ee649e5b77075521f3d4f0 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Fri, 3 Mar 2023 08:37:35 -0800 +Subject: [PATCH] libcomps: Use Py_hash_t instead of long in PyCOMPS_hash() + +This function is used as a hashfunc callback in +_typeobject defined python3.11/cpython/object.h +compilers detect the protype mismatch for function pointers +with clang16+ + +Fixes +libcomps/src/python/src/pycomps_sequence.c:667:5: error: incompatible function pointer types initializing 'hashfunc' (aka 'int (*)(struct _object *)') with an expression of type 'long (*)(PyObject *)' (aka 'long (*)(struct _object *)') [-Wincompatible-function-pointer-types] + &PyCOMPS_hash, /*tp_hash */ + +Upstream-Status: Submitted [https://github.com/rpm-software-management/libcomps/pull/101] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + libcomps/src/python/src/pycomps_hash.c | 4 ++-- + libcomps/src/python/src/pycomps_hash.h | 2 +- + libcomps/src/python/src/pycomps_utils.h | 2 +- + 3 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/libcomps/src/python/src/pycomps_hash.c b/libcomps/src/python/src/pycomps_hash.c +index 474afd5..4577769 100644 +--- a/libcomps/src/python/src/pycomps_hash.c ++++ b/libcomps/src/python/src/pycomps_hash.c +@@ -20,9 +20,9 @@ + #include "pycomps_hash.h" + #include "pycomps_utils.h" + +-long PyCOMPS_hash(PyObject *self) { ++Py_hash_t PyCOMPS_hash(PyObject *self) { + char *cstr = NULL; +- long crc; ++ Py_hash_t crc; + + cstr = comps_object_tostr(((PyCompsObject*)self)->c_obj); + crc = crc32(0, cstr, strlen(cstr)); +diff --git a/libcomps/src/python/src/pycomps_hash.h b/libcomps/src/python/src/pycomps_hash.h +index b664cae..54e08d9 100644 +--- a/libcomps/src/python/src/pycomps_hash.h ++++ b/libcomps/src/python/src/pycomps_hash.h +@@ -26,6 +26,6 @@ + #include "pycomps_utils.h" + + +-long PyCOMPS_hash(PyObject *self); ++Py_hash_t PyCOMPS_hash(PyObject *self); + + #endif +diff --git a/libcomps/src/python/src/pycomps_utils.h b/libcomps/src/python/src/pycomps_utils.h +index ba9bc2f..b34e4dc 100644 +--- a/libcomps/src/python/src/pycomps_utils.h ++++ b/libcomps/src/python/src/pycomps_utils.h +@@ -137,7 +137,7 @@ COMPS_Object* __pycomps_bytes_in(PyObject *pobj); + PyObject* __pycomps_str_out(COMPS_Object *obj); + PyObject *str_to_unicode(void* str); + +-long PyCOMPS_hash(PyObject *self); ++Py_hash_t PyCOMPS_hash(PyObject *self); + + PyObject* PyCOMPSSeq_extra_get(PyObject *self, PyObject *key); + +-- +2.39.2 + diff --git a/poky/meta/recipes-devtools/libcomps/libcomps_0.1.19.bb b/poky/meta/recipes-devtools/libcomps/libcomps_0.1.19.bb index fa1fbc8f0d..f8063d9400 100644 --- a/poky/meta/recipes-devtools/libcomps/libcomps_0.1.19.bb +++ b/poky/meta/recipes-devtools/libcomps/libcomps_0.1.19.bb @@ -5,6 +5,7 @@ LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" SRC_URI = "git://github.com/rpm-software-management/libcomps.git;branch=master;protocol=https \ + file://0001-libcomps-Use-Py_hash_t-instead-of-long-in-PyCOMPS_ha.patch \ file://0002-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch \ " diff --git a/poky/meta/recipes-devtools/libdnf/libdnf/0001-libdnf-dnf-context.cpp-do-not-try-to-access-BDB-data.patch b/poky/meta/recipes-devtools/libdnf/libdnf/0001-libdnf-dnf-context.cpp-do-not-try-to-access-BDB-data.patch deleted file mode 100644 index 6f8a3dcb50..0000000000 --- a/poky/meta/recipes-devtools/libdnf/libdnf/0001-libdnf-dnf-context.cpp-do-not-try-to-access-BDB-data.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 2f7382b35d59fe08034603497e82ffb943fedef1 Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin <alex.kanavin@gmail.com> -Date: Wed, 30 Jun 2021 15:31:16 +0200 -Subject: [PATCH] libdnf/dnf-context.cpp: do not try to access BDB database - -Upstream-Status: Inappropriate [upstream needs to rework this to support -sqlite] -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - libdnf/dnf-context.cpp | 14 -------------- - 1 file changed, 14 deletions(-) - -diff --git a/libdnf/dnf-context.cpp b/libdnf/dnf-context.cpp -index 86f71a79..9cdcf769 100644 ---- a/libdnf/dnf-context.cpp -+++ b/libdnf/dnf-context.cpp -@@ -2264,20 +2264,6 @@ dnf_context_setup(DnfContext *context, - !dnf_context_set_os_release(context, error)) - return FALSE; - -- /* setup a file monitor on the rpmdb, if we're operating on the native / */ -- if (g_strcmp0(priv->install_root, "/") == 0) { -- rpmdb_path = g_build_filename(priv->install_root, "var/lib/rpm/Packages", NULL); -- file_rpmdb = g_file_new_for_path(rpmdb_path); -- priv->monitor_rpmdb = g_file_monitor_file(file_rpmdb, -- G_FILE_MONITOR_NONE, -- NULL, -- error); -- if (priv->monitor_rpmdb == NULL) -- return FALSE; -- g_signal_connect(priv->monitor_rpmdb, "changed", -- G_CALLBACK(dnf_context_rpmdb_changed_cb), context); -- } -- - /* copy any vendor distributed cached metadata */ - if (!dnf_context_copy_vendor_cache(context, error)) - return FALSE; diff --git a/poky/meta/recipes-devtools/libdnf/libdnf_0.69.0.bb b/poky/meta/recipes-devtools/libdnf/libdnf_0.70.0.bb index da2550d323..14d6a37de1 100644 --- a/poky/meta/recipes-devtools/libdnf/libdnf_0.69.0.bb +++ b/poky/meta/recipes-devtools/libdnf/libdnf_0.70.0.bb @@ -10,10 +10,9 @@ SRC_URI = "git://github.com/rpm-software-management/libdnf;branch=dnf-4-master;p file://0001-Get-parameters-for-both-libsolv-and-libsolvext-libdn.patch \ file://enable_test_data_dir_set.patch \ file://0001-drop-FindPythonInstDir.cmake.patch \ - file://0001-libdnf-dnf-context.cpp-do-not-try-to-access-BDB-data.patch \ " -SRCREV = "5c6d9cd6e5955e7038722f091396607c60fcbdd1" +SRCREV = "93759bc5cac262906e52b6a173d7b157914ec29e" UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(?!4\.90)\d+(\.\d+)+)" S = "${WORKDIR}/git" diff --git a/poky/meta/recipes-devtools/llvm/llvm/llvm-config b/poky/meta/recipes-devtools/llvm/llvm/llvm-config index a45f38c650..5e4ded2da5 100644 --- a/poky/meta/recipes-devtools/llvm/llvm/llvm-config +++ b/poky/meta/recipes-devtools/llvm/llvm/llvm-config @@ -29,6 +29,15 @@ for arg in "$@"; do --ldflags) output="${output} ${LDFLAGS}" ;; + --shared-mode) + output="${output} shared" + ;; + --libs) + output="${output} -lLLVM" + ;; + --link-shared) + break + ;; *) remain="${remain} ${arg}" ;; diff --git a/poky/meta/recipes-devtools/lua/lua_5.4.4.bb b/poky/meta/recipes-devtools/lua/lua_5.4.4.bb index 0b2e754b31..a39d888ec2 100644 --- a/poky/meta/recipes-devtools/lua/lua_5.4.4.bb +++ b/poky/meta/recipes-devtools/lua/lua_5.4.4.bb @@ -57,3 +57,6 @@ do_install_ptest () { } BBCLASSEXTEND = "native nativesdk" + +inherit multilib_script +MULTILIB_SCRIPTS = "${PN}-dev:${includedir}/luaconf.h" diff --git a/poky/meta/recipes-devtools/meson/meson/disable-rpath-handling.patch b/poky/meta/recipes-devtools/meson/meson/disable-rpath-handling.patch deleted file mode 100644 index 7aaed8b4a3..0000000000 --- a/poky/meta/recipes-devtools/meson/meson/disable-rpath-handling.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 18600f7a1cddf23aeabd188f86e66983f27ccfe3 Mon Sep 17 00:00:00 2001 -From: Richard Purdie <richard.purdie@linuxfoundation.org> -Date: Fri, 23 Nov 2018 15:28:28 +0000 -Subject: [PATCH] meson: Disable rpath stripping at install time - -We need to allow our rpaths generated through the compiler flags to make it into -our binaries. Therefore disable the meson manipulations of these unless there -is a specific directive to do something differently in the project. - -RP 2018/11/23 - -Upstream-Status: Submitted [https://github.com/mesonbuild/meson/issues/2567] ---- - mesonbuild/minstall.py | 7 +++++-- - 1 file changed, 5 insertions(+), 2 deletions(-) - -diff --git a/mesonbuild/minstall.py b/mesonbuild/minstall.py -index 7d0da13..17d50db 100644 ---- a/mesonbuild/minstall.py -+++ b/mesonbuild/minstall.py -@@ -718,8 +718,11 @@ class Installer: - if file_copied: - self.did_install_something = True - try: -- self.fix_rpath(outname, t.rpath_dirs_to_remove, install_rpath, final_path, -- install_name_mappings, verbose=False) -+ if install_rpath: -+ self.fix_rpath(outname, t.rpath_dirs_to_remove, install_rpath, final_path, -+ install_name_mappings, verbose=False) -+ else: -+ print("RPATH changes at install time disabled") - except SystemExit as e: - if isinstance(e.code, int) and e.code == 0: - pass --- -2.20.1 - diff --git a/poky/meta/recipes-devtools/meson/meson/meson-wrapper b/poky/meta/recipes-devtools/meson/meson/meson-wrapper index c62007f507..7455985297 100755 --- a/poky/meta/recipes-devtools/meson/meson/meson-wrapper +++ b/poky/meta/recipes-devtools/meson/meson/meson-wrapper @@ -5,7 +5,7 @@ if [ -z "$OECORE_NATIVE_SYSROOT" ]; then fi if [ -z "$SSL_CERT_DIR" ]; then - export SSL_CERT_DIR="${OECORE_NATIVE_SYSROOT}/etc/ssl/certs/" + export SSL_CERT_DIR="$OECORE_NATIVE_SYSROOT/etc/ssl/certs/" fi # If these are set to a cross-compile path, meson will get confused and try to @@ -13,7 +13,19 @@ fi # config is already in meson.cross. unset CC CXX CPP LD AR NM STRIP +case "$1" in +setup|configure|dist|install|introspect|init|test|wrap|subprojects|rewrite|compile|devenv|env2mfile|help) MESON_CMD="$1" ;; +*) echo meson-wrapper: Implicit setup command assumed; MESON_CMD=setup ;; +esac + +if [ "$MESON_CMD" = "setup" ]; then + MESON_SETUP_OPTS=" \ + --cross-file="$OECORE_NATIVE_SYSROOT/usr/share/meson/${TARGET_PREFIX}meson.cross" \ + --native-file="$OECORE_NATIVE_SYSROOT/usr/share/meson/meson.native" \ + " + echo meson-wrapper: Running meson with setup options: \"$MESON_SETUP_OPTS\" +fi + exec "$OECORE_NATIVE_SYSROOT/usr/bin/meson.real" \ - --cross-file "${OECORE_NATIVE_SYSROOT}/usr/share/meson/${TARGET_PREFIX}meson.cross" \ - --native-file "${OECORE_NATIVE_SYSROOT}/usr/share/meson/meson.native" \ - "$@" + "$@" \ + $MESON_SETUP_OPTS diff --git a/poky/meta/recipes-devtools/meson/meson_0.63.2.bb b/poky/meta/recipes-devtools/meson/meson_0.63.3.bb index 890faacec9..0d13448744 100644 --- a/poky/meta/recipes-devtools/meson/meson_0.63.2.bb +++ b/poky/meta/recipes-devtools/meson/meson_0.63.3.bb @@ -12,13 +12,12 @@ SRC_URI = "${GITHUB_BASE_URI}/download/${PV}/meson-${PV}.tar.gz \ file://meson-setup.py \ file://meson-wrapper \ file://0001-python-module-do-not-manipulate-the-environment-when.patch \ - file://disable-rpath-handling.patch \ file://0001-Make-CPU-family-warnings-fatal.patch \ file://0002-Support-building-allarch-recipes-again.patch \ file://0001-is_debianlike-always-return-False.patch \ file://0001-Check-for-clang-before-guessing-gcc-or-lcc.patch \ " -SRC_URI[sha256sum] = "16222f17ef76be0542c91c07994f9676ae879f46fc21c0c786a21ef2cb518bbf" +SRC_URI[sha256sum] = "519c0932e1a8b208741f0fdce90aa5c0b528dd297cf337009bf63539846ac056" inherit python_setuptools_build_meta github-releases diff --git a/poky/meta/recipes-devtools/mtd/mtd-utils/0001-tests-Remove-unused-linux-fs.h-header-from-includes.patch b/poky/meta/recipes-devtools/mtd/mtd-utils/0001-tests-Remove-unused-linux-fs.h-header-from-includes.patch deleted file mode 100644 index 73d4a8475f..0000000000 --- a/poky/meta/recipes-devtools/mtd/mtd-utils/0001-tests-Remove-unused-linux-fs.h-header-from-includes.patch +++ /dev/null @@ -1,31 +0,0 @@ -From 6fb10bd18488ed84776675bc1b2982800a51d839 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Sat, 6 Aug 2022 20:14:38 -0700 -Subject: [mtd-utils][PATCH] tests: Remove unused linux/fs.h header from includes - -This header is not needed, moreover it includes linux/mount.h which is -now in conflict[1] with glibc provided sys/mount.h from glibc 2.36 onwards - -[1] https://sourceware.org/glibc/wiki/Release/2.36 - -Upstream-Status: Submitted [https://lists.infradead.org/pipermail/linux-mtd/2022-August/094667.html] -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - tests/fs-tests/lib/tests.c | 1 - - 1 file changed, 1 deletion(-) - -diff --git a/tests/fs-tests/lib/tests.c b/tests/fs-tests/lib/tests.c -index d1a2e0c..3db0426 100644 ---- a/tests/fs-tests/lib/tests.c -+++ b/tests/fs-tests/lib/tests.c -@@ -35,7 +35,6 @@ - #include <sys/vfs.h> - #include <sys/mount.h> - #include <sys/statvfs.h> --#include <linux/fs.h> - #include <linux/jffs2.h> - - #include "tests.h" --- -2.37.1 - diff --git a/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb b/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb index 943666e529..2d76991d2f 100644 --- a/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb +++ b/poky/meta/recipes-devtools/mtd/mtd-utils_git.bb @@ -11,12 +11,10 @@ inherit autotools pkgconfig update-alternatives DEPENDS = "zlib e2fsprogs util-linux" RDEPENDS:mtd-utils-tests += "bash" -PV = "2.1.4" +PV = "2.1.5" -SRCREV = "c7f1bfa44a84d02061787e2f6093df5cc40b9f5c" -SRC_URI = "git://git.infradead.org/mtd-utils.git;branch=master \ - file://0001-tests-Remove-unused-linux-fs.h-header-from-includes.patch \ - " +SRCREV = "3f3b4cc6c3120107e7aaa21c6415772a255ac49c" +SRC_URI = "git://git.infradead.org/mtd-utils.git;branch=master" S = "${WORKDIR}/git" diff --git a/poky/meta/recipes-devtools/mtools/mtools/disable-hardcoded-configs.patch b/poky/meta/recipes-devtools/mtools/mtools/disable-hardcoded-configs.patch index 8f46174a5b..2d42fa531a 100644 --- a/poky/meta/recipes-devtools/mtools/mtools/disable-hardcoded-configs.patch +++ b/poky/meta/recipes-devtools/mtools/mtools/disable-hardcoded-configs.patch @@ -1,4 +1,4 @@ -From 3a05dc2c0acff1713dd44cef5e9f328f0706eb3e Mon Sep 17 00:00:00 2001 +From c496cad7b7a84e599f521f289648373df9fad80f Mon Sep 17 00:00:00 2001 From: Ed Bartosh <ed.bartosh@linux.intel.com> Date: Tue, 13 Jun 2017 14:55:52 +0300 Subject: [PATCH] Disabled reading host configs. @@ -12,10 +12,10 @@ Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> 1 file changed, 8 deletions(-) diff --git a/config.c b/config.c -index 630f99d..07dbf53 100644 +index 8c5fa83..346048b 100644 --- a/config.c +++ b/config.c -@@ -834,14 +834,6 @@ void read_config(void) +@@ -843,14 +843,6 @@ void read_config(void) memcpy(devices, const_devices, nr_const_devices*sizeof(struct device)); diff --git a/poky/meta/recipes-devtools/mtools/mtools_4.0.40.bb b/poky/meta/recipes-devtools/mtools/mtools_4.0.41.bb index 200c7c7681..29e7427a10 100644 --- a/poky/meta/recipes-devtools/mtools/mtools_4.0.40.bb +++ b/poky/meta/recipes-devtools/mtools/mtools_4.0.41.bb @@ -24,7 +24,7 @@ RRECOMMENDS:${PN}:libc-glibc = "\ glibc-gconv-ibm866 \ glibc-gconv-ibm869 \ " -SRC_URI[sha256sum] = "a22fca42354011dd2293a7f51f228b46ebbd802e7740b0975912afecb79d5df4" +SRC_URI[sha256sum] = "2542152264fb3eff7ed70662abf4f4eef8133bc37d0b7a686c240df2b5f80a13" SRC_URI = "${GNU_MIRROR}/mtools/mtools-${PV}.tar.bz2 \ file://mtools-makeinfo.patch \ diff --git a/poky/meta/recipes-devtools/opkg/opkg/0002-opkg-key-remove-no-options-flag-from-gpg-calls.patch b/poky/meta/recipes-devtools/opkg/opkg/0002-opkg-key-remove-no-options-flag-from-gpg-calls.patch new file mode 100644 index 0000000000..f216950002 --- /dev/null +++ b/poky/meta/recipes-devtools/opkg/opkg/0002-opkg-key-remove-no-options-flag-from-gpg-calls.patch @@ -0,0 +1,34 @@ +From a658e6402382250f0164c5b47b744740e04f3611 Mon Sep 17 00:00:00 2001 +From: Charlie Johnston <charlie.johnston@ni.com> +Date: Fri, 30 Dec 2022 15:21:14 -0600 +Subject: [PATCH] opkg-key: Remove --no-options flag from gpg calls. + +The opkg-key script was always passing the --no-options +flag to gpg, which uses /dev/null as the options file. +As a result, the opkg gpg.conf file was not getting +used. This change removes that flag so that gpg.conf +in the GPGHOMEDIR for opkg (currently /etc/opkg/gpg/) +will be used if present. + +Upstream-Status: Accepted [https://git.yoctoproject.org/opkg/commit/?id=cee294e72d257417b5e55ef7a76a0fd15313e46b] +Signed-off-by: Charlie Johnston <charlie.johnston@ni.com> +--- + utils/opkg-key | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/utils/opkg-key b/utils/opkg-key +index e395a59..8645ebc 100755 +--- a/utils/opkg-key ++++ b/utils/opkg-key +@@ -53,7 +53,7 @@ else + exit 1 + fi + +-GPG="$GPGCMD --no-options --homedir $GPGHOMEDIR" ++GPG="$GPGCMD --homedir $GPGHOMEDIR" + + # Gpg home dir isn't created automatically when --homedir option is used + if [ ! -e "$GPGHOMEDIR" ]; then +-- +2.30.2 + diff --git a/poky/meta/recipes-devtools/opkg/opkg_0.6.0.bb b/poky/meta/recipes-devtools/opkg/opkg_0.6.1.bb index 4cd589cd29..712f066f0e 100644 --- a/poky/meta/recipes-devtools/opkg/opkg_0.6.0.bb +++ b/poky/meta/recipes-devtools/opkg/opkg_0.6.1.bb @@ -15,10 +15,11 @@ PE = "1" SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz \ file://opkg.conf \ file://0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch \ + file://0002-opkg-key-remove-no-options-flag-from-gpg-calls.patch \ file://run-ptest \ " -SRC_URI[sha256sum] = "56844722eff237daf14aa6e681436f3245213c5590ed0cda37a79df637ff3a4c" +SRC_URI[sha256sum] = "e87fccb575c64d3ac0559444016a2795f12125986a0da896bab97c4a1a2f1b2a" # This needs to be before ptest inherit, otherwise all ptest files end packaged # in libopkg package if OPKGLIBDIR == libdir, because default @@ -47,7 +48,9 @@ EXTRA_OECONF:class-native = "--localstatedir=/${@os.path.relpath('${localstatedi do_install:append () { install -d ${D}${sysconfdir}/opkg install -m 0644 ${WORKDIR}/opkg.conf ${D}${sysconfdir}/opkg/opkg.conf - echo "option lists_dir ${OPKGLIBDIR}/opkg/lists" >>${D}${sysconfdir}/opkg/opkg.conf + echo "option lists_dir ${OPKGLIBDIR}/opkg/lists" >>${D}${sysconfdir}/opkg/opkg.conf + echo "option info_dir ${OPKGLIBDIR}/opkg/info" >>${D}${sysconfdir}/opkg/opkg.conf + echo "option status_file ${OPKGLIBDIR}/opkg/status" >>${D}${sysconfdir}/opkg/opkg.conf # We need to create the lock directory install -d ${D}${OPKGLIBDIR}/opkg diff --git a/poky/meta/recipes-devtools/pkgconf/pkgconf_1.9.3.bb b/poky/meta/recipes-devtools/pkgconf/pkgconf_1.9.4.bb index 453da89c3d..ab0f371093 100644 --- a/poky/meta/recipes-devtools/pkgconf/pkgconf_1.9.3.bb +++ b/poky/meta/recipes-devtools/pkgconf/pkgconf_1.9.4.bb @@ -20,7 +20,7 @@ SRC_URI = "\ file://pkg-config-native.in \ file://pkg-config-esdk.in \ " -SRC_URI[sha256sum] = "5fb355b487d54fb6d341e4f18d4e2f7e813a6622cf03a9e87affa6a40565699d" +SRC_URI[sha256sum] = "daccf1bbe5a30d149b556c7d2ffffeafd76d7b514e249271abdd501533c1d8ae" inherit autotools diff --git a/poky/meta/recipes-devtools/python/python3-mako_1.2.2.bb b/poky/meta/recipes-devtools/python/python3-mako_1.2.3.bb index e3774ee621..12acfee777 100644 --- a/poky/meta/recipes-devtools/python/python3-mako_1.2.2.bb +++ b/poky/meta/recipes-devtools/python/python3-mako_1.2.3.bb @@ -8,7 +8,7 @@ PYPI_PACKAGE = "Mako" inherit pypi python_setuptools_build_meta -SRC_URI[sha256sum] = "3724869b363ba630a272a5f89f68c070352137b8fd1757650017b7e06fda163f" +SRC_URI[sha256sum] = "7fde96466fcfeedb0eed94f187f20b23d85e4cb41444be0e542e2c8c65c396cd" RDEPENDS:${PN} = "${PYTHON_PN}-html \ ${PYTHON_PN}-markupsafe \ diff --git a/poky/meta/recipes-devtools/python/python3-pytest_7.1.3.bb b/poky/meta/recipes-devtools/python/python3-pytest_7.1.3.bb index 373f7f35fa..9710242655 100644 --- a/poky/meta/recipes-devtools/python/python3-pytest_7.1.3.bb +++ b/poky/meta/recipes-devtools/python/python3-pytest_7.1.3.bb @@ -26,7 +26,7 @@ RDEPENDS:${PN}:class-target += " \ ${PYTHON_PN}-py \ ${PYTHON_PN}-setuptools \ ${PYTHON_PN}-six \ - ${PYTHON_PN}-toml \ + ${PYTHON_PN}-tomli \ ${PYTHON_PN}-wcwidth \ " diff --git a/poky/meta/recipes-devtools/python/python3-setuptools/0001-Limit-the-amount-of-whitespace-to-search-backtrack.-.patch b/poky/meta/recipes-devtools/python/python3-setuptools/0001-Limit-the-amount-of-whitespace-to-search-backtrack.-.patch new file mode 100644 index 0000000000..20a13da7bc --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-setuptools/0001-Limit-the-amount-of-whitespace-to-search-backtrack.-.patch @@ -0,0 +1,31 @@ +From 9e9f617a83f6593b476669030b0347d48e831c3f Mon Sep 17 00:00:00 2001 +From: Narpat Mali <narpat.mali@windriver.com> +Date: Mon, 9 Jan 2023 14:45:05 +0000 +Subject: [PATCH] Limit the amount of whitespace to search/backtrack. Fixes + #3659. + +CVE: CVE-2022-40897 + +Upstream-Status: Backport [https://github.com/pypa/setuptools/commit/43a9c9bfa6aa626ec2a22540bea28d2ca77964be] + +Signed-off-by: Narpat Mali <narpat.mali@windriver.com> +--- + setuptools/package_index.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/setuptools/package_index.py b/setuptools/package_index.py +index 270e7f3..e93fcc6 100644 +--- a/setuptools/package_index.py ++++ b/setuptools/package_index.py +@@ -197,7 +197,7 @@ def unique_values(func): + return wrapper + + +-REL = re.compile(r"""<([^>]*\srel\s*=\s*['"]?([^'">]+)[^>]*)>""", re.I) ++REL = re.compile(r"""<([^>]*\srel\s{0,10}=\s{0,10}['"]?([^'" >]+)[^>]*)>""", re.I) + # this line is here to fix emacs' cruddy broken syntax highlighting + + +-- +2.34.1 + diff --git a/poky/meta/recipes-devtools/python/python3-setuptools_65.0.2.bb b/poky/meta/recipes-devtools/python/python3-setuptools_65.0.2.bb index 1a639ea333..d7cbb99c9d 100644 --- a/poky/meta/recipes-devtools/python/python3-setuptools_65.0.2.bb +++ b/poky/meta/recipes-devtools/python/python3-setuptools_65.0.2.bb @@ -9,7 +9,9 @@ inherit pypi python_setuptools_build_meta SRC_URI:append:class-native = " file://0001-conditionally-do-not-fetch-code-by-easy_install.patch" SRC_URI += "file://0001-change-shebang-to-python3.patch \ - file://0001-_distutils-sysconfig.py-make-it-possible-to-substite.patch" + file://0001-_distutils-sysconfig.py-make-it-possible-to-substite.patch \ + file://0001-Limit-the-amount-of-whitespace-to-search-backtrack.-.patch \ +" SRC_URI[sha256sum] = "101bf15ca723beef42c8db91a761f3748d4d697e17fae904db60c0b619d8d094" diff --git a/poky/meta/recipes-devtools/python/python3/get_module_deps3.py b/poky/meta/recipes-devtools/python/python3/get_module_deps3.py index 1f4c982aed..0ca687d2eb 100644 --- a/poky/meta/recipes-devtools/python/python3/get_module_deps3.py +++ b/poky/meta/recipes-devtools/python/python3/get_module_deps3.py @@ -56,7 +56,7 @@ if debug == True: try: m = importlib.import_module(current_module) # handle python packages which may not include all modules in the __init__ - if os.path.basename(m.__file__) == "__init__.py": + if hasattr(m, '__file__') and os.path.basename(m.__file__) == "__init__.py": modulepath = os.path.dirname(m.__file__) for i in os.listdir(modulepath): if i.startswith("_") or not(i.endswith(".py")): diff --git a/poky/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb b/poky/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb index aa9e499c77..e297586bbb 100644 --- a/poky/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb +++ b/poky/meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb @@ -7,7 +7,7 @@ LIC_FILES_CHKSUM = "file://${WORKDIR}/tunctl.c;endline=4;md5=ff3a09996bc5fff6bc5 SRC_URI = "\ file://tunctl.c \ - file://qemu-oe-bridge-helper \ + file://qemu-oe-bridge-helper.c \ " S = "${WORKDIR}" @@ -16,13 +16,13 @@ inherit native do_compile() { ${CC} ${CFLAGS} ${LDFLAGS} -Wall tunctl.c -o tunctl + ${CC} ${CFLAGS} ${LDFLAGS} -Wall qemu-oe-bridge-helper.c -o qemu-oe-bridge-helper } do_install() { install -d ${D}${bindir} install tunctl ${D}${bindir}/ - - install -m 755 ${WORKDIR}/qemu-oe-bridge-helper ${D}${bindir}/ + install qemu-oe-bridge-helper ${D}${bindir}/ } DEPENDS += "qemu-system-native" diff --git a/poky/meta/recipes-devtools/qemu/qemu-helper/qemu-oe-bridge-helper b/poky/meta/recipes-devtools/qemu/qemu-helper/qemu-oe-bridge-helper deleted file mode 100755 index f057d4eef0..0000000000 --- a/poky/meta/recipes-devtools/qemu/qemu-helper/qemu-oe-bridge-helper +++ /dev/null @@ -1,25 +0,0 @@ -#! /bin/sh -# Copyright 2020 Garmin Ltd. or its subsidiaries -# -# SPDX-License-Identifier: GPL-2.0 -# -# Attempts to find and exec the host qemu-bridge-helper program - -# If the QEMU_BRIDGE_HELPER variable is set by the user, exec it. -if [ -n "$QEMU_BRIDGE_HELPER" ]; then - exec "$QEMU_BRIDGE_HELPER" "$@" -fi - -# Search common paths for the helper program -BN="qemu-bridge-helper" -PATHS="/usr/libexec/ /usr/lib/qemu/" - -for p in $PATHS; do - if [ -e "$p/$BN" ]; then - exec "$p/$BN" "$@" - fi -done - -echo "$BN not found!" > /dev/stderr -exit 1 - diff --git a/poky/meta/recipes-devtools/qemu/qemu-helper/qemu-oe-bridge-helper.c b/poky/meta/recipes-devtools/qemu/qemu-helper/qemu-oe-bridge-helper.c new file mode 100644 index 0000000000..9434e1d269 --- /dev/null +++ b/poky/meta/recipes-devtools/qemu/qemu-helper/qemu-oe-bridge-helper.c @@ -0,0 +1,34 @@ +/* + * Copyright 2022 Garmin Ltd. or its subsidiaries + * + * SPDX-License-Identifier: GPL-2.0 + * + * Attempts to find and exec the host qemu-bridge-helper program + */ + +#include <stdio.h> +#include <unistd.h> +#include <stdlib.h> + +void try_program(char const* path, char** args) { + if (access(path, X_OK) == 0) { + execv(path, args); + } +} + +int main(int argc, char** argv) { + char* var; + + var = getenv("QEMU_BRIDGE_HELPER"); + if (var && var[0] != '\0') { + execvp(var, argv); + return 1; + } + + try_program("/usr/libexec/qemu-bridge-helper", argv); + try_program("/usr/lib/qemu/qemu-bridge-helper", argv); + + fprintf(stderr, "No bridge helper found\n"); + return 1; +} + diff --git a/poky/meta/recipes-devtools/qemu/qemu.inc b/poky/meta/recipes-devtools/qemu/qemu.inc index 612abd240a..f3237971ce 100644 --- a/poky/meta/recipes-devtools/qemu/qemu.inc +++ b/poky/meta/recipes-devtools/qemu/qemu.inc @@ -29,6 +29,8 @@ SRC_URI = "https://download.qemu.org/${BPN}-${PV}.tar.xz \ file://0010-hw-pvrdma-Protect-against-buggy-or-malicious-guest-d.patch \ file://0001-net-tulip-Restrict-DMA-engine-to-memories.patch \ file://arm-cpreg-fix.patch \ + file://CVE-2022-3165.patch \ + file://CVE-2022-4144.patch \ " UPSTREAM_CHECK_REGEX = "qemu-(?P<pver>\d+(\.\d+)+)\.tar" @@ -147,6 +149,7 @@ PACKAGECONFIG:remove:darwin = "kvm virglrenderer epoxy gtk+" PACKAGECONFIG:remove:mingw32 = "kvm virglrenderer epoxy gtk+" PACKAGECONFIG[sdl] = "--enable-sdl,--disable-sdl,libsdl2" +PACKAGECONFIG[png] = "--enable-png,--disable-png,libpng" PACKAGECONFIG[virtfs] = "--enable-virtfs --enable-attr --enable-cap-ng,--disable-virtfs,libcap-ng attr," PACKAGECONFIG[aio] = "--enable-linux-aio,--disable-linux-aio,libaio," PACKAGECONFIG[uring] = "--enable-linux-io-uring,--disable-linux-io-uring,liburing" @@ -198,6 +201,7 @@ PACKAGECONFIG[rdma] = "--enable-rdma,--disable-rdma" PACKAGECONFIG[vde] = "--enable-vde,--disable-vde" PACKAGECONFIG[slirp] = "--enable-slirp=internal,--disable-slirp" PACKAGECONFIG[brlapi] = "--enable-brlapi,--disable-brlapi" +PACKAGECONFIG[jack] = "--enable-jack,--disable-jack,jack," INSANE_SKIP:${PN} = "arch" diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2022-3165.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2022-3165.patch new file mode 100644 index 0000000000..3b4a6694c2 --- /dev/null +++ b/poky/meta/recipes-devtools/qemu/qemu/CVE-2022-3165.patch @@ -0,0 +1,59 @@ +CVE: CVE-2022-3165 +Upstream-Status: Backport +Signed-off-by: Ross Burton <ross.burton@arm.com> + +From d307040b18bfcb1393b910f1bae753d5c12a4dc7 Mon Sep 17 00:00:00 2001 +From: Mauro Matteo Cascella <mcascell@redhat.com> +Date: Sun, 25 Sep 2022 22:45:11 +0200 +Subject: [PATCH] ui/vnc-clipboard: fix integer underflow in + vnc_client_cut_text_ext + +Extended ClientCutText messages start with a 4-byte header. If len < 4, +an integer underflow occurs in vnc_client_cut_text_ext. The result is +used to decompress data in a while loop in inflate_buffer, leading to +CPU consumption and denial of service. Prevent this by checking dlen in +protocol_client_msg. + +Fixes: CVE-2022-3165 +Fixes: 0bf41cab93e5 ("ui/vnc: clipboard support") +Reported-by: TangPeng <tangpeng@qianxin.com> +Signed-off-by: Mauro Matteo Cascella <mcascell@redhat.com> +Message-Id: <20220925204511.1103214-1-mcascell@redhat.com> +Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> +--- + ui/vnc.c | 11 ++++++++--- + 1 file changed, 8 insertions(+), 3 deletions(-) + +diff --git a/ui/vnc.c b/ui/vnc.c +index 6a05d06147..acb3629cd8 100644 +--- a/ui/vnc.c ++++ b/ui/vnc.c +@@ -2442,8 +2442,8 @@ static int protocol_client_msg(VncState *vs, uint8_t *data, size_t len) + if (len == 1) { + return 8; + } ++ uint32_t dlen = abs(read_s32(data, 4)); + if (len == 8) { +- uint32_t dlen = abs(read_s32(data, 4)); + if (dlen > (1 << 20)) { + error_report("vnc: client_cut_text msg payload has %u bytes" + " which exceeds our limit of 1MB.", dlen); +@@ -2456,8 +2456,13 @@ static int protocol_client_msg(VncState *vs, uint8_t *data, size_t len) + } + + if (read_s32(data, 4) < 0) { +- vnc_client_cut_text_ext(vs, abs(read_s32(data, 4)), +- read_u32(data, 8), data + 12); ++ if (dlen < 4) { ++ error_report("vnc: malformed payload (header less than 4 bytes)" ++ " in extended clipboard pseudo-encoding."); ++ vnc_client_error(vs); ++ break; ++ } ++ vnc_client_cut_text_ext(vs, dlen, read_u32(data, 8), data + 12); + break; + } + vnc_client_cut_text(vs, read_u32(data, 4), data + 8); +-- +GitLab + diff --git a/poky/meta/recipes-devtools/qemu/qemu/CVE-2022-4144.patch b/poky/meta/recipes-devtools/qemu/qemu/CVE-2022-4144.patch new file mode 100644 index 0000000000..96052a19e8 --- /dev/null +++ b/poky/meta/recipes-devtools/qemu/qemu/CVE-2022-4144.patch @@ -0,0 +1,99 @@ +From 6dbbf055148c6f1b7d8a3251a65bd6f3d1e1f622 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= <philmd@linaro.org> +Date: Mon, 28 Nov 2022 21:27:40 +0100 +Subject: [PATCH] hw/display/qxl: Avoid buffer overrun in qxl_phys2virt + (CVE-2022-4144) +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Have qxl_get_check_slot_offset() return false if the requested +buffer size does not fit within the slot memory region. + +Similarly qxl_phys2virt() now returns NULL in such case, and +qxl_dirty_one_surface() aborts. + +This avoids buffer overrun in the host pointer returned by +memory_region_get_ram_ptr(). + +Fixes: CVE-2022-4144 (out-of-bounds read) +Reported-by: Wenxu Yin (@awxylitol) +Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1336 + +CVE: CVE-2022-4144 +Upstream-Status: Backport [https://gitlab.com/qemu-project/qemu/-/commit/6dbbf055148c6f1b7d8a3251a65bd6f3d1e1f622] +Comments: Deleted patch hunk in qxl.h,as it contains change +in comments which is not present in current version of qemu + +Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> +Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> +Message-Id: <20221128202741.4945-5-philmd@linaro.org> +Signed-off-by: Bhabu Bindu <bhabu.bindu@kpit.com> +--- + hw/display/qxl.c | 27 +++++++++++++++++++++++---- + 1 files changed, 23 insertions(+), 4 deletions(-) + +diff --git a/hw/display/qxl.c b/hw/display/qxl.c +index 231d733250..0b21626aad 100644 +--- a/hw/display/qxl.c ++++ b/hw/display/qxl.c +@@ -1424,11 +1424,13 @@ static void qxl_reset_surfaces(PCIQXLDevice *d) + + /* can be also called from spice server thread context */ + static bool qxl_get_check_slot_offset(PCIQXLDevice *qxl, QXLPHYSICAL pqxl, +- uint32_t *s, uint64_t *o) ++ uint32_t *s, uint64_t *o, ++ size_t size_requested) + { + uint64_t phys = le64_to_cpu(pqxl); + uint32_t slot = (phys >> (64 - 8)) & 0xff; + uint64_t offset = phys & 0xffffffffffff; ++ uint64_t size_available; + + if (slot >= NUM_MEMSLOTS) { + qxl_set_guest_bug(qxl, "slot too large %d >= %d", slot, +@@ -1452,6 +1454,23 @@ static bool qxl_get_check_slot_offset(PCIQXLDevice *qxl, QXLPHYSICAL pqxl, + slot, offset, qxl->guest_slots[slot].size); + return false; + } ++ size_available = memory_region_size(qxl->guest_slots[slot].mr); ++ if (qxl->guest_slots[slot].offset + offset >= size_available) { ++ qxl_set_guest_bug(qxl, ++ "slot %d offset %"PRIu64" > region size %"PRIu64"\n", ++ slot, qxl->guest_slots[slot].offset + offset, ++ size_available); ++ return false; ++ } ++ size_available -= qxl->guest_slots[slot].offset + offset; ++ if (size_requested > size_available) { ++ qxl_set_guest_bug(qxl, ++ "slot %d offset %"PRIu64" size %zu: " ++ "overrun by %"PRIu64" bytes\n", ++ slot, offset, size_requested, ++ size_requested - size_available); ++ return false; ++ } + + *s = slot; + *o = offset; +@@ -1471,7 +1490,7 @@ void *qxl_phys2virt(PCIQXLDevice *qxl, QXLPHYSICAL pqxl, int group_id, + offset = le64_to_cpu(pqxl) & 0xffffffffffff; + return (void *)(intptr_t)offset; + case MEMSLOT_GROUP_GUEST: +- if (!qxl_get_check_slot_offset(qxl, pqxl, &slot, &offset)) { ++ if (!qxl_get_check_slot_offset(qxl, pqxl, &slot, &offset, size)) { + return NULL; + } + ptr = memory_region_get_ram_ptr(qxl->guest_slots[slot].mr); +@@ -1937,9 +1956,9 @@ static void qxl_dirty_one_surface(PCIQXLDevice *qxl, QXLPHYSICAL pqxl, + uint32_t slot; + bool rc; + +- rc = qxl_get_check_slot_offset(qxl, pqxl, &slot, &offset); +- assert(rc == true); + size = (uint64_t)height * abs(stride); ++ rc = qxl_get_check_slot_offset(qxl, pqxl, &slot, &offset, size); ++ assert(rc == true); + trace_qxl_surfaces_dirty(qxl->id, offset, size); + qxl_set_dirty(qxl->guest_slots[slot].mr, + qxl->guest_slots[slot].offset + offset, diff --git a/poky/meta/recipes-devtools/quilt/quilt.inc b/poky/meta/recipes-devtools/quilt/quilt.inc index 07611e6d85..fce81016d8 100644 --- a/poky/meta/recipes-devtools/quilt/quilt.inc +++ b/poky/meta/recipes-devtools/quilt/quilt.inc @@ -12,6 +12,8 @@ SRC_URI = "${SAVANNAH_GNU_MIRROR}/quilt/quilt-${PV}.tar.gz \ file://Makefile \ file://test.sh \ file://0001-tests-Allow-different-output-from-mv.patch \ + file://fix-grep-3.8.patch \ + file://faildiff-order.patch \ " SRC_URI:append:class-target = " file://gnu_patch_test_fix_target.patch" diff --git a/poky/meta/recipes-devtools/quilt/quilt/faildiff-order.patch b/poky/meta/recipes-devtools/quilt/quilt/faildiff-order.patch new file mode 100644 index 0000000000..f22065a250 --- /dev/null +++ b/poky/meta/recipes-devtools/quilt/quilt/faildiff-order.patch @@ -0,0 +1,41 @@ +Upstream-Status: Backport +Signed-off-by: Ross Burton <ross.burton@arm.com> + +From 4dfe7f9e702c85243a71e4de267a13e434b6d6c2 Mon Sep 17 00:00:00 2001 +From: Jean Delvare <jdelvare@suse.de> +Date: Fri, 20 Jan 2023 12:56:08 +0100 +Subject: [PATCH] test: Fix a race condition + +The test suite does not differentiate between stdout and stderr. When +messages are printed to both, the order in which they will reach us +is apparently not guaranteed. Ideally this would be deterministic, but +until then, explicitly test stdout and stderr separately in the test +case itself. Otherwise the test suite fails randomly, which is a pain +for distribution package maintainers. + +This fixes bug #63651 reported by Ross Burton: +https://savannah.nongnu.org/bugs/index.php?63651 + +Signed-off-by: Jean Delvare <jdelvare@suse.de> +--- + test/faildiff.test | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/test/faildiff.test b/test/faildiff.test +index 5afb8e3..0444c15 100644 +--- a/test/faildiff.test ++++ b/test/faildiff.test +@@ -27,8 +27,9 @@ What happens on binary files? + > File test.bin added to patch %{P}test.diff + + $ printf "\\003\\000\\001" > test.bin +- $ quilt diff -pab --no-index ++ $ quilt diff -pab --no-index 2>/dev/null + >~ (Files|Binary files) a/test\.bin and b/test\.bin differ ++ $ quilt diff -pab --no-index >/dev/null + > Diff failed on file 'test.bin', aborting + $ echo %{?} + > 1 +-- +2.34.1 + diff --git a/poky/meta/recipes-devtools/quilt/quilt/fix-grep-3.8.patch b/poky/meta/recipes-devtools/quilt/quilt/fix-grep-3.8.patch new file mode 100644 index 0000000000..68a4b4c195 --- /dev/null +++ b/poky/meta/recipes-devtools/quilt/quilt/fix-grep-3.8.patch @@ -0,0 +1,144 @@ +From f73f8d7f71de2878d3f92881a5fcb8eafd78cb5f Mon Sep 17 00:00:00 2001 +From: Jean Delvare <jdelvare@suse.de> +Date: Fri, 9 Sep 2022 10:10:37 +0200 +Subject: Avoid warnings with grep 3.8 + +GNU grep version 3.8 became more strict about needless quoting in +patterns. We have one occurrence of that in quilt, where "/" +characters are being quoted by default. There are cases where they +indeed need to be quoted (typically when used in a sed s/// command) +but most of the time they do not, and this results in the following +warning: + +grep: warning: stray \ before / + +So rename quote_bre() to quote_sed_re(), and introduce +quote_grep_re() which does not quote "/". + +Signed-off-by: Jean Delvare <jdelvare@suse.de> +Upstream-Status: Backport [https://git.savannah.nongnu.org/cgit/quilt.git/commit/?id=f73f8d7f71de2878d3f92881a5fcb8eafd78cb5f] +Signed-off-by: Alexander Kanavin <alex@linutronix.de> +--- + quilt/diff.in | 2 +- + quilt/patches.in | 2 +- + quilt/scripts/patchfns.in | 20 +++++++++++++------- + quilt/upgrade.in | 4 ++-- + 4 files changed, 17 insertions(+), 11 deletions(-) + +diff --git a/quilt/diff.in b/quilt/diff.in +index e90dc33..07788ff 100644 +--- a/quilt/diff.in ++++ b/quilt/diff.in +@@ -255,7 +255,7 @@ then + # Add all files in the snapshot into the file list (they may all + # have changed). + files=( $(find $QUILT_PC/$snap_subdir -type f \ +- | sed -e "s/^$(quote_bre $QUILT_PC/$snap_subdir/)//" \ ++ | sed -e "s/^$(quote_sed_re $QUILT_PC/$snap_subdir/)//" \ + | sort) ) + printf "%s\n" "${files[@]}" >&4 + unset files +diff --git a/quilt/patches.in b/quilt/patches.in +index bb17a46..eac45a9 100644 +--- a/quilt/patches.in ++++ b/quilt/patches.in +@@ -60,7 +60,7 @@ scan_unapplied() + # Quote each file name only once + for file in "${opt_files[@]}" + do +- files_bre[${#files_bre[@]}]=$(quote_bre "$file") ++ files_bre[${#files_bre[@]}]=$(quote_grep_re "$file") + done + + # "Or" all files in a single pattern +diff --git a/quilt/scripts/patchfns.in b/quilt/scripts/patchfns.in +index c2d5f9d..1bd7233 100644 +--- a/quilt/scripts/patchfns.in ++++ b/quilt/scripts/patchfns.in +@@ -78,8 +78,14 @@ array_join() + done + } + +-# Quote a string for use in a basic regular expression. +-quote_bre() ++# Quote a string for use in a regular expression for a grep pattern. ++quote_grep_re() ++{ ++ echo "$1" | sed -e 's:\([][^$.*\\]\):\\\1:g' ++} ++ ++# Quote a string for use in a regular expression for a sed s/// command. ++quote_sed_re() + { + echo "$1" | sed -e 's:\([][^$/.*\\]\):\\\1:g' + } +@@ -215,7 +221,7 @@ patch_in_series() + + if [ -e "$SERIES" ] + then +- grep -q "^$(quote_bre $patch)\([ \t]\|$\)" "$SERIES" ++ grep -q "^$(quote_grep_re $patch)\([ \t]\|$\)" "$SERIES" + else + return 1 + fi +@@ -365,7 +371,7 @@ is_applied() + { + local patch=$1 + [ -e $DB ] || return 1 +- grep -q "^$(quote_bre $patch)\$" $DB ++ grep -q "^$(quote_grep_re $patch)\$" $DB + } + + applied_patches() +@@ -465,7 +471,7 @@ remove_from_db() + local tmpfile + if tmpfile=$(gen_tempfile) + then +- grep -v "^$(quote_bre $patch)\$" $DB > $tmpfile ++ grep -v "^$(quote_grep_re $patch)\$" $DB > $tmpfile + cat $tmpfile > $DB + rm -f $tmpfile + [ -s $DB ] || rm -f $DB +@@ -520,7 +526,7 @@ find_patch() + fi + + local patch=${1#$SUBDIR_DOWN$QUILT_PATCHES/} +- local bre=$(quote_bre "$patch") ++ local bre=$(quote_sed_re "$patch") + set -- $(sed -e "/^$bre\(\|\.patch\|\.diff\?\)\(\|\.gz\|\.bz2\|\.xz\|\.lzma\|\.lz\)\([ "$'\t'"]\|$\)/!d" \ + -e 's/[ '$'\t''].*//' "$SERIES") + if [ $# -eq 1 ] +@@ -631,7 +637,7 @@ files_in_patch() + then + find "$path" -type f \ + -a ! -path "$(quote_glob "$path")/.timestamp" | +- sed -e "s/$(quote_bre "$path")\///" ++ sed -e "s/$(quote_sed_re "$path")\///" + fi + } + +diff --git a/quilt/upgrade.in b/quilt/upgrade.in +index dbf7d05..866aa33 100644 +--- a/quilt/upgrade.in ++++ b/quilt/upgrade.in +@@ -74,7 +74,7 @@ printf $"Converting meta-data to version %s\n" "$DB_VERSION" + + for patch in $(applied_patches) + do +- proper_name="$(grep "^$(quote_bre $patch)"'\(\|\.patch\|\.diff?\)\(\|\.gz\|\.bz2\)\([ \t]\|$\)' $SERIES)" ++ proper_name="$(grep "^$(quote_grep_re $patch)"'\(\|\.patch\|\.diff?\)\(\|\.gz\|\.bz2\)\([ \t]\|$\)' $SERIES)" + proper_name=${proper_name#$QUILT_PATCHES/} + proper_name=${proper_name%% *} + if [ -z "$proper_name" ] +@@ -84,7 +84,7 @@ do + fi + + if [ "$patch" != "$proper_name" -a -d $QUILT_PC/$patch ] \ +- && grep -q "^$(quote_bre $patch)\$" \ ++ && grep -q "^$(quote_grep_re $patch)\$" \ + $QUILT_PC/applied-patches + then + mv $QUILT_PC/$patch $QUILT_PC/$proper_name \ +-- +cgit v1.1 + diff --git a/poky/meta/recipes-devtools/rpm/files/0001-python-Use-Py_hash_t-instead-of-long-in-hdr_hash.patch b/poky/meta/recipes-devtools/rpm/files/0001-python-Use-Py_hash_t-instead-of-long-in-hdr_hash.patch new file mode 100644 index 0000000000..d0e637191a --- /dev/null +++ b/poky/meta/recipes-devtools/rpm/files/0001-python-Use-Py_hash_t-instead-of-long-in-hdr_hash.patch @@ -0,0 +1,35 @@ +From 6ef189c45b763aedac5ef57ed6a5fc125fa95b41 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Fri, 3 Mar 2023 09:54:48 -0800 +Subject: [PATCH] python: Use Py_hash_t instead of long in hdr_hash + +Fixes +python/header-py.c:744:2: error: incompatible function pointer types initializing 'hashfunc' (aka 'int (*)(struct _object *)') with an expression of type 'long (PyObject *)' (aka 'long (struct _object *)') [-Wincompatible-function-pointer-types] +| hdr_hash, /* tp_hash */ +| ^~~~~~~~ + +Upstream-Status: Submitted [https://github.com/rpm-software-management/rpm/pull/2409] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + python/header-py.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/python/header-py.c b/python/header-py.c +index 0aed0c9267..c15503f359 100644 +--- a/python/header-py.c ++++ b/python/header-py.c +@@ -316,9 +316,9 @@ static PyObject * hdr_dsOfHeader(PyObject * s) + "(Oi)", s, RPMTAG_NEVR); + } + +-static long hdr_hash(PyObject * h) ++static Py_hash_t hdr_hash(PyObject * h) + { +- return (long) h; ++ return (Py_hash_t) h; + } + + static PyObject * hdr_reduce(hdrObject *s) +-- +2.39.2 + diff --git a/poky/meta/recipes-devtools/rpm/rpm_4.18.0.bb b/poky/meta/recipes-devtools/rpm/rpm_4.18.0.bb index 5f3986d8a3..db83a8c099 100644 --- a/poky/meta/recipes-devtools/rpm/rpm_4.18.0.bb +++ b/poky/meta/recipes-devtools/rpm/rpm_4.18.0.bb @@ -40,6 +40,7 @@ SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.18.x;protoc file://0001-build-pack.c-do-not-insert-payloadflags-into-.rpm-me.patch \ file://0001-configure.ac-add-linux-gnux32-variant-to-triplet-han.patch \ file://fifofix.patch \ + file://0001-python-Use-Py_hash_t-instead-of-long-in-hdr_hash.patch \ " PE = "1" diff --git a/poky/meta/recipes-devtools/ruby/ruby.inc b/poky/meta/recipes-devtools/ruby/ruby.inc deleted file mode 100644 index ebff5efd1f..0000000000 --- a/poky/meta/recipes-devtools/ruby/ruby.inc +++ /dev/null @@ -1,39 +0,0 @@ -SUMMARY = "An interpreter of object-oriented scripting language" -DESCRIPTION = "Ruby is an interpreted scripting language for quick \ -and easy object-oriented programming. It has many features to process \ -text files and to do system management tasks (as in Perl). \ -It is simple, straight-forward, and extensible. \ -" -HOMEPAGE = "http://www.ruby-lang.org/" -SECTION = "devel/ruby" -LICENSE = "Ruby | BSD-2-Clause | BSD-3-Clause | GPL-2.0-only | ISC | MIT" -LIC_FILES_CHKSUM = "file://COPYING;md5=5b8c87559868796979806100db3f3805 \ - file://BSDL;md5=8b50bc6de8f586dc66790ba11d064d75 \ - file://GPL;md5=b234ee4d69f5fce4486a80fdaf4a4263 \ - file://LEGAL;md5=f260190bc1e92e363f0ee3c0463d4c7c \ - " - -DEPENDS = "zlib openssl libyaml gdbm readline libffi" -DEPENDS:append:class-target = " ruby-native" - -SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}" -SRC_URI = "http://cache.ruby-lang.org/pub/ruby/${SHRT_VER}/ruby-${PV}.tar.gz \ - file://0001-extmk-fix-cross-compilation-of-external-gems.patch \ - file://0002-Obey-LDFLAGS-for-the-link-of-libruby.patch \ - " -UPSTREAM_CHECK_URI = "https://www.ruby-lang.org/en/downloads/" - -inherit autotools ptest pkgconfig - - -# This snippet lets compiled extensions which rely on external libraries, -# such as zlib, compile properly. If we don't do this, then when extmk.rb -# runs, it uses the native libraries instead of the target libraries, and so -# none of the linking operations succeed -- which makes extconf.rb think -# that the libraries aren't available and hence that the extension can't be -# built. - -do_configure:prepend() { - sed -i "s#%%TARGET_CFLAGS%%#$CFLAGS#; s#%%TARGET_LDFLAGS%%#$LDFLAGS#" ${S}/common.mk - rm -rf ${S}/ruby/ -} diff --git a/poky/meta/recipes-devtools/ruby/ruby/0001-Remove-dependency-on-libcapstone.patch b/poky/meta/recipes-devtools/ruby/ruby/0001-Remove-dependency-on-libcapstone.patch deleted file mode 100644 index 5d0f8fcc09..0000000000 --- a/poky/meta/recipes-devtools/ruby/ruby/0001-Remove-dependency-on-libcapstone.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 222203297966f312109e8eaa2520f2cf2f59c09d Mon Sep 17 00:00:00 2001 -From: Alan Wu <XrXr@users.noreply.github.com> -Date: Thu, 31 Mar 2022 17:26:28 -0400 -Subject: [PATCH] Remove dependency on libcapstone - -We have received reports of build failures due to this configuration -check modifying compile flags. Since only YJIT devs use this library -we can remove it to make Ruby easier to build for users. - -See: https://github.com/rbenv/ruby-build/discussions/1933 - -Upstream-Status: Backport ---- - configure.ac | 9 --------- - 1 file changed, 9 deletions(-) - -Index: ruby-3.1.2/configure.ac -=================================================================== ---- ruby-3.1.2.orig/configure.ac -+++ ruby-3.1.2/configure.ac -@@ -1244,15 +1244,6 @@ AC_CHECK_LIB(dl, dlopen) # Dynamic linki - AC_CHECK_LIB(dld, shl_load) # Dynamic linking for HP-UX - AC_CHECK_LIB(socket, shutdown) # SunOS/Solaris - --if pkg-config --exists capstone; then -- CAPSTONE_CFLAGS=`pkg-config --cflags capstone` -- CAPSTONE_LIB_L=`pkg-config --libs-only-L capstone` -- LDFLAGS="$LDFLAGS $CAPSTONE_LIB_L" -- CFLAGS="$CFLAGS $CAPSTONE_CFLAGS" --fi -- --AC_CHECK_LIB(capstone, cs_open) # Capstone disassembler for debugging YJIT -- - dnl Checks for header files. - AC_HEADER_DIRENT - dnl AC_HEADER_STDC has been checked in AC_USE_SYSTEM_EXTENSIONS diff --git a/poky/meta/recipes-devtools/ruby/ruby_3.1.2.bb b/poky/meta/recipes-devtools/ruby/ruby_3.1.3.bb index 387bfa9b44..c8454da3a9 100644 --- a/poky/meta/recipes-devtools/ruby/ruby_3.1.2.bb +++ b/poky/meta/recipes-devtools/ruby/ruby_3.1.3.bb @@ -1,8 +1,25 @@ -require ruby.inc - -DEPENDS:append:libc-musl = " libucontext" - -SRC_URI += " \ +SUMMARY = "An interpreter of object-oriented scripting language" +DESCRIPTION = "Ruby is an interpreted scripting language for quick \ +and easy object-oriented programming. It has many features to process \ +text files and to do system management tasks (as in Perl). \ +It is simple, straight-forward, and extensible. \ +" +HOMEPAGE = "http://www.ruby-lang.org/" +SECTION = "devel/ruby" +LICENSE = "Ruby | BSD-2-Clause | BSD-3-Clause | GPL-2.0-only | ISC | MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=5b8c87559868796979806100db3f3805 \ + file://BSDL;md5=8b50bc6de8f586dc66790ba11d064d75 \ + file://GPL;md5=b234ee4d69f5fce4486a80fdaf4a4263 \ + file://LEGAL;md5=f260190bc1e92e363f0ee3c0463d4c7c \ + " + +DEPENDS = "zlib openssl libyaml gdbm readline libffi" +DEPENDS:append:class-target = " ruby-native" + +SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}" +SRC_URI = "http://cache.ruby-lang.org/pub/ruby/${SHRT_VER}/ruby-${PV}.tar.gz \ + file://0001-extmk-fix-cross-compilation-of-external-gems.patch \ + file://0002-Obey-LDFLAGS-for-the-link-of-libruby.patch \ file://remove_has_include_macros.patch \ file://run-ptest \ file://0001-template-Makefile.in-do-not-write-host-cross-cc-item.patch \ @@ -12,10 +29,27 @@ SRC_URI += " \ file://0005-Mark-Gemspec-reproducible-change-fixing-784225-too.patch \ file://0006-Make-gemspecs-reproducible.patch \ file://0001-vm_dump.c-Define-REG_S1-and-REG_S2-for-musl-riscv.patch \ - file://0001-Remove-dependency-on-libcapstone.patch \ " +UPSTREAM_CHECK_URI = "https://www.ruby-lang.org/en/downloads/" + +inherit autotools ptest pkgconfig + + +# This snippet lets compiled extensions which rely on external libraries, +# such as zlib, compile properly. If we don't do this, then when extmk.rb +# runs, it uses the native libraries instead of the target libraries, and so +# none of the linking operations succeed -- which makes extconf.rb think +# that the libraries aren't available and hence that the extension can't be +# built. + +do_configure:prepend() { + sed -i "s#%%TARGET_CFLAGS%%#$CFLAGS#; s#%%TARGET_LDFLAGS%%#$LDFLAGS#" ${S}/common.mk + rm -rf ${S}/ruby/ +} + +DEPENDS:append:libc-musl = " libucontext" -SRC_URI[sha256sum] = "61843112389f02b735428b53bb64cf988ad9fb81858b8248e22e57336f24a83e" +SRC_URI[sha256sum] = "5ea498a35f4cd15875200a52dde42b6eb179e1264e17d78732c3a57cd1c6ab9e" PACKAGECONFIG ??= "" PACKAGECONFIG += "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}" diff --git a/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service b/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service index 7f72f3388a..b6b81d5c1a 100644 --- a/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service +++ b/poky/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service @@ -1,7 +1,7 @@ [Unit] Description=Run pending postinsts DefaultDependencies=no -After=systemd-remount-fs.service systemd-tmpfiles-setup.service tmp.mount +After=systemd-remount-fs.service systemd-tmpfiles-setup.service tmp.mount ldconfig.service Before=sysinit.target [Service] diff --git a/poky/meta/recipes-devtools/rust/rust.inc b/poky/meta/recipes-devtools/rust/rust.inc index 956301023a..7d87e8e1b2 100644 --- a/poky/meta/recipes-devtools/rust/rust.inc +++ b/poky/meta/recipes-devtools/rust/rust.inc @@ -72,7 +72,7 @@ python do_configure() { config = configparser.RawConfigParser() # [target.ARCH-poky-linux] - host_section = "target.{}".format(d.getVar('RUST_HOST_SYS', True)) + host_section = "target.{}".format(d.getVar('RUST_HOST_SYS')) config.add_section(host_section) llvm_config_target = d.expand("${RUST_ALTERNATE_EXE_PATH}") @@ -87,7 +87,7 @@ python do_configure() { # If we don't do this rust-native will compile it's own llvm for BUILD. # [target.${BUILD_ARCH}-unknown-linux-gnu] - build_section = "target.{}".format(d.getVar('RUST_BUILD_SYS', True)) + build_section = "target.{}".format(d.getVar('RUST_BUILD_SYS')) if build_section != host_section: config.add_section(build_section) @@ -97,7 +97,7 @@ python do_configure() { config.set(build_section, "cc", e(d.expand("${RUST_BUILD_CC}"))) config.set(build_section, "linker", e(d.expand("${RUST_BUILD_CCLD}"))) - target_section = "target.{}".format(d.getVar('RUST_TARGET_SYS', True)) + target_section = "target.{}".format(d.getVar('RUST_TARGET_SYS')) if target_section != host_section and target_section != build_section: config.add_section(target_section) @@ -143,26 +143,26 @@ python do_configure() { config.set("build", "vendor", e(True)) if not "targets" in locals(): - targets = [d.getVar("RUST_TARGET_SYS", True)] + targets = [d.getVar("RUST_TARGET_SYS")] config.set("build", "target", e(targets)) if not "hosts" in locals(): - hosts = [d.getVar("RUST_HOST_SYS", True)] + hosts = [d.getVar("RUST_HOST_SYS")] config.set("build", "host", e(hosts)) # We can't use BUILD_SYS since that is something the rust snapshot knows # nothing about when trying to build some stage0 tools (like fabricate) - config.set("build", "build", e(d.getVar("RUST_BUILD_SYS", True))) + config.set("build", "build", e(d.getVar("RUST_BUILD_SYS"))) # [install] config.add_section("install") # ./x.py install doesn't have any notion of "destdir" # but we can prepend ${D} to all the directories instead - config.set("install", "prefix", e(d.getVar("D", True) + d.getVar("prefix", True))) - config.set("install", "bindir", e(d.getVar("D", True) + d.getVar("bindir", True))) - config.set("install", "libdir", e(d.getVar("D", True) + d.getVar("libdir", True))) - config.set("install", "datadir", e(d.getVar("D", True) + d.getVar("datadir", True))) - config.set("install", "mandir", e(d.getVar("D", True) + d.getVar("mandir", True))) + config.set("install", "prefix", e(d.getVar("D") + d.getVar("prefix"))) + config.set("install", "bindir", e(d.getVar("D") + d.getVar("bindir"))) + config.set("install", "libdir", e(d.getVar("D") + d.getVar("libdir"))) + config.set("install", "datadir", e(d.getVar("D") + d.getVar("datadir"))) + config.set("install", "mandir", e(d.getVar("D") + d.getVar("mandir"))) with open("config.toml", "w") as f: f.write('changelog-seen = 2\n\n') diff --git a/poky/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch b/poky/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch index 7097bb9087..31a76d9bb4 100644 --- a/poky/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch +++ b/poky/meta/recipes-devtools/rust/rust/crossbeam_atomic.patch @@ -14,7 +14,7 @@ Someone with more rust knowledge could split up the triplets in no_atmoics.rs and compare against the architecture/processor, or replace -unknown with a glob to create a patch that upstream might accept. -Upstream-Status: Inappropriate [OE Specific tweak but could be rewritten] +Upstream-Status: Submitted [https://github.com/crossbeam-rs/crossbeam/pull/922] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Index: rustc-1.63.0-src/vendor/crossbeam-utils/build.rs diff --git a/poky/meta/recipes-devtools/rust/rust_1.63.0.bb b/poky/meta/recipes-devtools/rust/rust_1.63.0.bb index 1f9dbd3cce..dbf74cec8f 100644 --- a/poky/meta/recipes-devtools/rust/rust_1.63.0.bb +++ b/poky/meta/recipes-devtools/rust/rust_1.63.0.bb @@ -57,7 +57,6 @@ rust_do_install:class-nativesdk() { } EXTRA_TOOLS ?= "cargo-clippy clippy-driver rustfmt" -EXTRA_TOOLS:remove:riscv32 = "rustfmt" rust_do_install:class-target() { export PSEUDO_UNLOAD=1 rust_runx install diff --git a/poky/meta/recipes-devtools/tcltk/tcl/fix_non_native_build_issue.patch b/poky/meta/recipes-devtools/tcltk/tcl/fix_non_native_build_issue.patch index 44b2ce0a30..5a10c93a31 100644 --- a/poky/meta/recipes-devtools/tcltk/tcl/fix_non_native_build_issue.patch +++ b/poky/meta/recipes-devtools/tcltk/tcl/fix_non_native_build_issue.patch @@ -1,4 +1,4 @@ -Upstream-Status: Pending +Upstream-Status: Inappropriate [upstream does not support installed tests] Index: unix/Makefile.in =================================================================== diff --git a/poky/meta/recipes-devtools/vala/vala.inc b/poky/meta/recipes-devtools/vala/vala.inc index 974baa33f5..162e99bb03 100644 --- a/poky/meta/recipes-devtools/vala/vala.inc +++ b/poky/meta/recipes-devtools/vala/vala.inc @@ -42,20 +42,23 @@ EXTRA_OECONF += " --disable-valadoc" # Vapigen wrapper needs to be available system-wide, because it will be used # to build vapi files from all other packages with vala support do_install:append:class-target() { - install -d ${D}${bindir}/ - install ${B}/vapigen-wrapper ${D}${bindir}/ + install -d ${D}${bindir_crossscripts}/ + install ${B}/vapigen-wrapper ${D}${bindir_crossscripts}/ } # Put vapigen wrapper into target sysroot so that it can be used when building # vapi files. -SYSROOT_DIRS:append:class-target = " ${bindir}" +SYSROOT_DIRS += "${bindir_crossscripts}" + +inherit multilib_script +MULTILIB_SCRIPTS = "${PN}:${bindir}/vala-gen-introspect-0.56" SYSROOT_PREPROCESS_FUNCS:append:class-target = " vapigen_sysroot_preprocess" vapigen_sysroot_preprocess() { # Tweak the vapigen name in the vapigen pkgconfig file, so that it picks # up our wrapper. sed -i \ - -e "s|vapigen=.*|vapigen=${bindir}/vapigen-wrapper|" \ + -e "s|vapigen=.*|vapigen=${bindir_crossscripts}/vapigen-wrapper|" \ ${SYSROOT_DESTDIR}${libdir}/pkgconfig/vapigen-${SHRT_VER}.pc } @@ -64,5 +67,5 @@ SSTATE_SCAN_FILES += "vapigen-wrapper" PACKAGE_PREPROCESS_FUNCS += "vala_package_preprocess" vala_package_preprocess () { - sed -i -e 's:${RECIPE_SYSROOT}::g;' ${PKGD}${bindir}/vapigen-wrapper + rm -rf ${PKGD}${bindir_crossscripts} } diff --git a/poky/meta/recipes-devtools/valgrind/valgrind/remove-for-aarch64 b/poky/meta/recipes-devtools/valgrind/valgrind/remove-for-aarch64 index 887bfd2766..432dcc916c 100644 --- a/poky/meta/recipes-devtools/valgrind/valgrind/remove-for-aarch64 +++ b/poky/meta/recipes-devtools/valgrind/valgrind/remove-for-aarch64 @@ -1,3 +1,4 @@ +drd/tests/boost_thread gdbserver_tests/hgtls cachegrind/tests/ann1 callgrind/tests/simwork1 |