diff options
author | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2020-05-26 20:25:03 +0300 |
---|---|---|
committer | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2020-05-26 20:25:03 +0300 |
commit | 35a774200999ac2fca48693c1c169bf99d2f63ea (patch) | |
tree | 0b2f65ce3a90f41d1c2542d0fd20b1604fd83fe5 /poky/meta/recipes-devtools | |
parent | 497a23ef6661ad6ca7b75009e48a592c1620d46c (diff) | |
download | openbmc-35a774200999ac2fca48693c1c169bf99d2f63ea.tar.xz |
Reset the following subtrees on HEAD:
poky: ed3bdd7fbc(dunfell)
meta-raspberrypi: 8066fac91d(dunfell)
meta-security: d83f7cb0c9(dunfell)
meta-openembedded: e413c1ef62(dunfell)
Change-Id: Ifd3228663b08911c890d7631310294cccb3dd232
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Diffstat (limited to 'poky/meta/recipes-devtools')
59 files changed, 1343 insertions, 703 deletions
diff --git a/poky/meta/recipes-devtools/bison/bison_3.5.4.bb b/poky/meta/recipes-devtools/bison/bison_3.5.3.bb index 59c34f7297..27e09434f8 100644 --- a/poky/meta/recipes-devtools/bison/bison_3.5.4.bb +++ b/poky/meta/recipes-devtools/bison/bison_3.5.3.bb @@ -13,7 +13,7 @@ SRC_URI = "${GNU_MIRROR}/bison/bison-${PV}.tar.xz \ file://dont-depend-on-help2man.patch.patch \ file://add-with-bisonlocaledir.patch \ " -SRC_URI[sha256sum] = "4c17e99881978fa32c05933c5262457fa5b2b611668454f8dc2a695cd6b3720c" +SRC_URI[sha256sum] = "2bf85b5f88a5f2fa8069aed2a2dfc3a9f8d15a97e59c713e3906e5fdd982a7c4" # No point in hardcoding path to m4, just use PATH EXTRA_OECONF += "M4=m4" diff --git a/poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01.bb b/poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01.bb index b568bb39f6..c08da6cdca 100644 --- a/poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01.bb +++ b/poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01.bb @@ -11,7 +11,6 @@ SRC_URI = " \ ${SOURCEFORGE_MIRROR}/project/cdrtools/cdrtools-${PV}.tar.bz2 \ file://0001-Don-t-set-uid-gid-during-install.patch \ " -UPSTREAM_VERSION_UNKNOWN = "1" SRC_URI[md5sum] = "7d45c5b7e1f78d85d1583b361aee6e8b" SRC_URI[sha256sum] = "ed282eb6276c4154ce6a0b5dee0bdb81940d0cbbfc7d03f769c4735ef5f5860f" diff --git a/poky/meta/recipes-devtools/dnf/dnf/0001-dnf-write-the-log-lock-to-root.patch b/poky/meta/recipes-devtools/dnf/dnf/0001-dnf-write-the-log-lock-to-root.patch deleted file mode 100644 index 21b50dee01..0000000000 --- a/poky/meta/recipes-devtools/dnf/dnf/0001-dnf-write-the-log-lock-to-root.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 5e07c16a506b19cbb107d5e99fca41d679b23b9a Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin <alex.kanavin@gmail.com> -Date: Tue, 28 Apr 2020 15:55:00 +0200 -Subject: [PATCH] dnf: write the log lock to root - -Writing it to /var/log appears to be racing with installation -of base-files, and if lock is created first, base-files -will refuse to install (due to the target directory -already existing, and base-files creating it as a symlink). - -Upstream-Status: Inappropriate [oe-core specific] -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - dnf/logging.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/dnf/logging.py b/dnf/logging.py -index bd660470..a9d808b1 100644 ---- a/dnf/logging.py -+++ b/dnf/logging.py -@@ -94,7 +94,7 @@ class MultiprocessRotatingFileHandler(logging.handlers.RotatingFileHandler): - def __init__(self, filename, mode='a', maxBytes=0, backupCount=0, encoding=None, delay=False): - super(MultiprocessRotatingFileHandler, self).__init__( - filename, mode, maxBytes, backupCount, encoding, delay) -- self.rotate_lock = dnf.lock.build_log_lock("/var/log/", True) -+ self.rotate_lock = dnf.lock.build_log_lock("/", True) - - def emit(self, record): - while True: diff --git a/poky/meta/recipes-devtools/dnf/dnf/Fix-SyntaxWarning.patch b/poky/meta/recipes-devtools/dnf/dnf/Fix-SyntaxWarning.patch new file mode 100644 index 0000000000..1bd8b09594 --- /dev/null +++ b/poky/meta/recipes-devtools/dnf/dnf/Fix-SyntaxWarning.patch @@ -0,0 +1,34 @@ +From 23c5b15efe42e5e6ee695e54798bac248532d8d6 Mon Sep 17 00:00:00 2001 + +Date: Tue, 28 May 2019 13:14:51 +0200 +Subject: [oe-core][PATCH 1/1] Fix SyntaxWarning: "is" with a literal. Did you + mean "=="? + +--- + dnf/cli/commands/repoquery.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) +--- + +Unchanged. Appears in version 4.2.7. + +Upstream-Status: Backport [git://github.com/rpm-software-management/dnf.git] + +Signed-off-by: Joe Slater <joe.slater@windriver.com> + + +diff --git a/dnf/cli/commands/repoquery.py b/dnf/cli/commands/repoquery.py +index 941a470..63fc668 100644 +--- a/dnf/cli/commands/repoquery.py ++++ b/dnf/cli/commands/repoquery.py +@@ -611,7 +611,7 @@ class RepoQueryCommand(commands.Command): + + def tree_seed(self, query, aquery, opts, level=-1, usedpkgs=None): + for pkg in sorted(set(query.run()), key=lambda p: p.name): +- usedpkgs = set() if usedpkgs is None or level is -1 else usedpkgs ++ usedpkgs = set() if usedpkgs is None or level == -1 else usedpkgs + if pkg.name.startswith("rpmlib") or pkg.name.startswith("solvable"): + return + self.grow_tree(level, pkg, opts) +-- +2.7.4 + diff --git a/poky/meta/recipes-devtools/dnf/dnf_4.2.21.bb b/poky/meta/recipes-devtools/dnf/dnf_4.2.2.bb index 44dab1d8a6..a046ffc05d 100644 --- a/poky/meta/recipes-devtools/dnf/dnf_4.2.21.bb +++ b/poky/meta/recipes-devtools/dnf/dnf_4.2.2.bb @@ -13,11 +13,11 @@ SRC_URI = "git://github.com/rpm-software-management/dnf.git \ file://0005-Do-not-prepend-installroot-to-logdir.patch \ file://0029-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch \ file://0030-Run-python-scripts-using-env.patch \ + file://Fix-SyntaxWarning.patch \ file://0001-set-python-path-for-completion_helper.patch \ - file://0001-dnf-write-the-log-lock-to-root.patch \ " -SRCREV = "864c381baabf024c299dca75abfda96139b8f583" +SRCREV = "9947306a55271b8b7c9e2b6e3b7d582885b6045d" UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)" S = "${WORKDIR}/git" diff --git a/poky/meta/recipes-devtools/dpkg/dpkg/0001-Add-support-for-riscv32-CPU.patch b/poky/meta/recipes-devtools/dpkg/dpkg/0001-Add-support-for-riscv32-CPU.patch deleted file mode 100644 index 52e85705fa..0000000000 --- a/poky/meta/recipes-devtools/dpkg/dpkg/0001-Add-support-for-riscv32-CPU.patch +++ /dev/null @@ -1,39 +0,0 @@ -From 279e4c274f5f295823cf9fa95d3ba131f6d711db Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Wed, 29 Apr 2020 22:02:23 -0700 -Subject: [PATCH] Add support for riscv32 CPU - -Upstream-Status: Pending -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - data/cputable | 1 + - scripts/Dpkg/Vendor/Debian.pm | 1 + - 2 files changed, 2 insertions(+) - -diff --git a/data/cputable b/data/cputable -index 9f2a8e0..1d935b1 100644 ---- a/data/cputable -+++ b/data/cputable -@@ -41,6 +41,7 @@ powerpc powerpc (powerpc|ppc) 32 big - powerpcel powerpcle powerpcle 32 little - ppc64 powerpc64 (powerpc|ppc)64 64 big - ppc64el powerpc64le powerpc64le 64 little -+riscv32 riscv32 riscv32 32 little - riscv64 riscv64 riscv64 64 little - s390 s390 s390 32 big - s390x s390x s390x 64 big -diff --git a/scripts/Dpkg/Vendor/Debian.pm b/scripts/Dpkg/Vendor/Debian.pm -index a352bbd..fa1d90b 100644 ---- a/scripts/Dpkg/Vendor/Debian.pm -+++ b/scripts/Dpkg/Vendor/Debian.pm -@@ -306,6 +306,7 @@ sub _add_build_flags { - powerpc - ppc64 - ppc64el -+ riscv32 - riscv64 - s390x - sparc --- -2.26.2 - diff --git a/poky/meta/recipes-devtools/dpkg/dpkg_1.19.7.bb b/poky/meta/recipes-devtools/dpkg/dpkg_1.19.7.bb index 50fe54dee1..e9dec337b3 100644 --- a/poky/meta/recipes-devtools/dpkg/dpkg_1.19.7.bb +++ b/poky/meta/recipes-devtools/dpkg/dpkg_1.19.7.bb @@ -13,7 +13,6 @@ SRC_URI = "${DEBIAN_MIRROR}/main/d/${BPN}/${BPN}_${PV}.tar.xz \ file://0007-dpkg-deb-build.c-Remove-usage-of-clamp-mtime-in-tar.patch \ file://0001-dpkg-Support-muslx32-build.patch \ file://pager.patch \ - file://0001-Add-support-for-riscv32-CPU.patch \ " SRC_URI_append_class-native = " \ file://tweak-options-require-tar-1.27.patch \ diff --git a/poky/meta/recipes-devtools/elfutils/elfutils_0.179.bb b/poky/meta/recipes-devtools/elfutils/elfutils_0.178.bb index 1da95ec1de..c500ae3c19 100644 --- a/poky/meta/recipes-devtools/elfutils/elfutils_0.179.bb +++ b/poky/meta/recipes-devtools/elfutils/elfutils_0.178.bb @@ -40,8 +40,8 @@ SRC_URI_append_libc-musl = " \ file://0003-musl-utils.patch \ file://0004-Fix-error-on-musl.patch \ " -SRC_URI[md5sum] = "8ee56b371b5a7ea081284c44e5164600" -SRC_URI[sha256sum] = "25a545566cbacaa37ae6222e58f1c48ea4570f53ba991886e2f5ce96e22a23a2" +SRC_URI[md5sum] = "5480d0b7174446aba13a6adde107287f" +SRC_URI[sha256sum] = "31e7a00e96d4e9c4bda452e1f2cdac4daf8abd24f5e154dee232131899f3a0f2" inherit autotools gettext ptest pkgconfig diff --git a/poky/meta/recipes-devtools/fdisk/gptfdisk/0001-gptcurses-correctly-include-curses.h.patch b/poky/meta/recipes-devtools/fdisk/gptfdisk/0001-gptcurses-correctly-include-curses.h.patch deleted file mode 100644 index 67689e838a..0000000000 --- a/poky/meta/recipes-devtools/fdisk/gptfdisk/0001-gptcurses-correctly-include-curses.h.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 607b0bed5e8a5f5c3754cd6ffcf499d8134c37f9 Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin <alex.kanavin@gmail.com> -Date: Mon, 30 Mar 2020 17:11:19 +0200 -Subject: [PATCH] gptcurses: correctly include curses.h - -Upstream-Status: Inappropriate [oe-core specific] -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - gptcurses.cc | 4 ---- - 1 file changed, 4 deletions(-) - -diff --git a/gptcurses.cc b/gptcurses.cc -index 1b18cf2..4ebfde1 100644 ---- a/gptcurses.cc -+++ b/gptcurses.cc -@@ -23,11 +23,7 @@ - #include <iostream> - #include <string> - #include <sstream> --#ifdef __APPLE__ - #include <ncurses.h> --#else --#include <ncursesw/ncurses.h> --#endif - #include "gptcurses.h" - #include "support.h" - diff --git a/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.5.bb b/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.4.bb index c7850f03ca..b043c96543 100644 --- a/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.5.bb +++ b/poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.4.bb @@ -6,11 +6,9 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552" DEPENDS = "util-linux" -SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${PV}/${BP}.tar.gz \ - file://0001-gptcurses-correctly-include-curses.h.patch \ - " -SRC_URI[md5sum] = "58dac67c85e46ca87b587231549aefe6" -SRC_URI[sha256sum] = "0e7d3987cd0488ecaf4b48761bc97f40b1dc089e5ff53c4b37abe30bc67dcb2f" +SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${PV}/${BP}.tar.gz" +SRC_URI[md5sum] = "5ecc3c44913bb6b53d3708d1ac7ac295" +SRC_URI[sha256sum] = "b663391a6876f19a3cd901d862423a16e2b5ceaa2f4a3b9bb681e64b9c7ba78d" UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/gptfdisk/files/gptfdisk/" UPSTREAM_CHECK_REGEX = "/gptfdisk/(?P<pver>(\d+[\.\-_]*)+)/" diff --git a/poky/meta/recipes-devtools/file/file_5.38.bb b/poky/meta/recipes-devtools/file/file_5.38.bb index b8f09107e8..f5ad568936 100644 --- a/poky/meta/recipes-devtools/file/file_5.38.bb +++ b/poky/meta/recipes-devtools/file/file_5.38.bb @@ -8,8 +8,8 @@ SECTION = "console/utils" LICENSE = "BSD-2-Clause" LIC_FILES_CHKSUM = "file://COPYING;beginline=2;md5=0251eaec1188b20d9a72c502ecfdda1b" -DEPENDS = "zlib file-replacement-native" -DEPENDS_class-native = "zlib-native" +DEPENDS = "file-replacement-native" +DEPENDS_class-native = "" SRC_URI = "git://github.com/file/file.git" @@ -18,6 +18,12 @@ S = "${WORKDIR}/git" inherit autotools update-alternatives +PACKAGECONFIG ??= "zlib" +PACKAGECONFIG_class-native ??= "zlib" +PACKAGECONFIG[bz2] = "--enable-bzlib, --disable-bzlib, bzip2" +PACKAGECONFIG[lzma] = "--enable-xzlib, --disable-xzlib, xz" +PACKAGECONFIG[zlib] = "--enable-zlib, --disable-zlib, zlib" + EXTRA_OECONF += "--disable-libseccomp" ALTERNATIVE_${PN} = "file" diff --git a/poky/meta/recipes-devtools/jquery/jquery_3.5.0.bb b/poky/meta/recipes-devtools/jquery/jquery_3.4.1.bb index 5c6f9cddbe..1bf6ef5c98 100644 --- a/poky/meta/recipes-devtools/jquery/jquery_3.5.0.bb +++ b/poky/meta/recipes-devtools/jquery/jquery_3.4.1.bb @@ -2,7 +2,7 @@ SUMMARY = "jQuery is a fast, small, and feature-rich JavaScript library" HOMEPAGE = "https://jquery.com/" LICENSE = "MIT" SECTION = "devel" -LIC_FILES_CHKSUM = "file://${WORKDIR}/${BP}.js;startline=8;endline=10;md5=b1e67ece919e852643f1541a54492d65" +LIC_FILES_CHKSUM = "file://${WORKDIR}/${BP}.js;startline=8;endline=10;md5=cdb86f5bda90caec023592d2e768357c" SRC_URI = "\ https://code.jquery.com/${BP}.js;name=js \ @@ -10,9 +10,9 @@ SRC_URI = "\ https://code.jquery.com/${BP}.min.map;name=map \ " -SRC_URI[js.sha256sum] = "aff01a147aeccc9b70a5efad1f2362fd709f3316296ec460d94aa7d31decdb37" -SRC_URI[min.sha256sum] = "c4dccdd9ae25b64078e0c73f273de94f8894d5c99e4741645ece29aeefc9c5a4" -SRC_URI[map.sha256sum] = "3149351c8cbc3fb230bbf6188617c7ffda77d9e14333f4f5f0aa1aae379df892" +SRC_URI[js.sha256sum] = "5a93a88493aa32aab228bf4571c01207d3b42b0002409a454d404b4d8395bd55" +SRC_URI[min.sha256sum] = "0925e8ad7bd971391a8b1e98be8e87a6971919eb5b60c196485941c3c1df089a" +SRC_URI[map.sha256sum] = "8da74aec0fcdd7678a2663b3cc9bafbaf009e6d6929b28bb3dd95bced18206f6" UPSTREAM_CHECK_REGEX = "jquery-(?P<pver>\d+(\.\d+)+)\.js" diff --git a/poky/meta/recipes-devtools/libdnf/libdnf/0001-Add-WITH_TESTS-option.patch b/poky/meta/recipes-devtools/libdnf/libdnf/0001-Add-WITH_TESTS-option.patch index ac9400c48d..3c87d4d8b3 100644 --- a/poky/meta/recipes-devtools/libdnf/libdnf/0001-Add-WITH_TESTS-option.patch +++ b/poky/meta/recipes-devtools/libdnf/libdnf/0001-Add-WITH_TESTS-option.patch @@ -1,4 +1,4 @@ -From 56fa2bbdbd29377a6ef0d0b7aadbac8b5ea8c95b Mon Sep 17 00:00:00 2001 +From e5a50db749b2b02e9e0cff9f7b639020e8ac76da Mon Sep 17 00:00:00 2001 From: Alexander Kanavin <alex.kanavin@gmail.com> Date: Tue, 6 Nov 2018 13:54:43 +0100 Subject: [PATCH] Add WITH_TESTS option @@ -14,18 +14,18 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> 2 files changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt -index 881152a..965c992 100644 +index ce88b9e3..7a99320a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -33,6 +33,7 @@ option(WITH_MAN "Enables hawkey man page generation" ON) - option(WITH_ZCHUNK "Build with zchunk support" ON) +@@ -32,6 +32,7 @@ option(WITH_HTML "Enables hawkey HTML generation" ON) + option(WITH_MAN "Enables hawkey man page generation" ON) option(ENABLE_RHSM_SUPPORT "Build with Red Hat Subscription Manager support?" OFF) option(ENABLE_SOLV_URPMREORDER "Build with support for URPM-like solution reordering?" OFF) +option(WITH_TESTS "Enables unit tests" ON) # load pkg-config first; it's required by other modules -@@ -165,8 +166,10 @@ endif() +@@ -158,8 +159,10 @@ endif() # build tests @@ -37,7 +37,7 @@ index 881152a..965c992 100644 add_subdirectory(python/hawkey) endif() diff --git a/python/hawkey/CMakeLists.txt b/python/hawkey/CMakeLists.txt -index d964534..84d1720 100644 +index d9645346..84d17204 100644 --- a/python/hawkey/CMakeLists.txt +++ b/python/hawkey/CMakeLists.txt @@ -50,4 +50,6 @@ target_link_libraries(_hawkeymodule ${PYTHON_LIBRARY}) diff --git a/poky/meta/recipes-devtools/libdnf/libdnf/0001-Look-fo-sphinx-only-if-documentation-is-actually-ena.patch b/poky/meta/recipes-devtools/libdnf/libdnf/0001-Look-fo-sphinx-only-if-documentation-is-actually-ena.patch deleted file mode 100644 index 6dd7c71aae..0000000000 --- a/poky/meta/recipes-devtools/libdnf/libdnf/0001-Look-fo-sphinx-only-if-documentation-is-actually-ena.patch +++ /dev/null @@ -1,42 +0,0 @@ -From b570c7f8bd089deec7da2b108aa789a27025a473 Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin <alex.kanavin@gmail.com> -Date: Tue, 19 Nov 2019 13:46:09 +0100 -Subject: [PATCH] Look fo sphinx only if documentation is actually enabled - -Upstream-Status: Pending -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - docs/hawkey/CMakeLists.txt | 20 +++++++++++--------- - 1 file changed, 11 insertions(+), 9 deletions(-) - -diff --git a/docs/hawkey/CMakeLists.txt b/docs/hawkey/CMakeLists.txt -index 52cc35c6..63c7672f 100644 ---- a/docs/hawkey/CMakeLists.txt -+++ b/docs/hawkey/CMakeLists.txt -@@ -2,15 +2,17 @@ - # tell sphinx-build to do them both in one go: - - --find_program(SPHINX_PROGRAM NAMES "sphinx-build-${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}") --if(NOT EXISTS ${SPHINX_PROGRAM}) -- find_program(SPHINX_PROGRAM NAMES sphinx-build-${PYTHON_VERSION_MAJOR}) --endif() --if(NOT EXISTS ${SPHINX_PROGRAM}) -- find_program(SPHINX_PROGRAM NAMES sphinx-build) --endif() --if(NOT EXISTS ${SPHINX_PROGRAM}) -- message(FATAL_ERROR "Sphinx program not found." ) -+if (WITH_HTML OR WITH_MAN) -+ find_program(SPHINX_PROGRAM NAMES "sphinx-build-${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}") -+ if(NOT EXISTS ${SPHINX_PROGRAM}) -+ find_program(SPHINX_PROGRAM NAMES sphinx-build-${PYTHON_VERSION_MAJOR}) -+ endif() -+ if(NOT EXISTS ${SPHINX_PROGRAM}) -+ find_program(SPHINX_PROGRAM NAMES sphinx-build) -+ endif() -+ if(NOT EXISTS ${SPHINX_PROGRAM}) -+ message(FATAL_ERROR "Sphinx program not found." ) -+ endif() - endif() - - if(WITH_HTML) diff --git a/poky/meta/recipes-devtools/libdnf/libdnf/0001-Use-single-quotes-around-string-literals-used-in-SQL.patch b/poky/meta/recipes-devtools/libdnf/libdnf/0001-Use-single-quotes-around-string-literals-used-in-SQL.patch deleted file mode 100644 index 6be484fea3..0000000000 --- a/poky/meta/recipes-devtools/libdnf/libdnf/0001-Use-single-quotes-around-string-literals-used-in-SQL.patch +++ /dev/null @@ -1,36 +0,0 @@ -From 96ca7d0049461df2293dd0000edcbc69b64255e0 Mon Sep 17 00:00:00 2001 -From: Peter Kjellerstedt <pkj@axis.com> -Date: Sun, 3 May 2020 22:40:39 +0200 -Subject: [PATCH] Use single-quotes around string literals used in SQL - statements - -If sqlite is built with -DSQLITE_DQS=0 in accordance with -https://sqlite.org/quirks.html#dblquote, migration to version 1.2 of the -history database would fail with: - - History database cannot be created: /var/lib/dnf/history.sqlite. - Error: SQLite error on ":memory:": Executing an SQL statement failed: - no such column: 1.2 - -Upstream-Status: Submitted [https://github.com/rpm-software-management/libdnf/pull/951] -Signed-off-by: Peter Kjellerstedt <pkj@axis.com> ---- - libdnf/transaction/sql/migrate_tables_1_2.sql | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/libdnf/transaction/sql/migrate_tables_1_2.sql b/libdnf/transaction/sql/migrate_tables_1_2.sql -index 49b75315..f80ad1c4 100644 ---- a/libdnf/transaction/sql/migrate_tables_1_2.sql -+++ b/libdnf/transaction/sql/migrate_tables_1_2.sql -@@ -1,9 +1,9 @@ - R"**( - BEGIN TRANSACTION; - ALTER TABLE trans -- ADD comment TEXT DEFAULT ""; -+ ADD comment TEXT DEFAULT ''; - UPDATE config -- SET value = "1.2" -+ SET value = '1.2' - WHERE key = 'version'; - COMMIT; - )**" diff --git a/poky/meta/recipes-devtools/libdnf/libdnf/0001-include-stdexcept-for-runtime_error.patch b/poky/meta/recipes-devtools/libdnf/libdnf/0001-include-stdexcept-for-runtime_error.patch new file mode 100644 index 0000000000..cedf539243 --- /dev/null +++ b/poky/meta/recipes-devtools/libdnf/libdnf/0001-include-stdexcept-for-runtime_error.patch @@ -0,0 +1,65 @@ +From 5f8eee5040d7074710cd542fc50f7a40918321fc Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Mon, 23 Dec 2019 14:30:22 -0800 +Subject: [PATCH] include <stdexcept> for runtime_error + +Fixes + +error: class 'libdnf::ModulePackageContainer::Exception' does not have any field named 'runtime_error' + explicit Exception(const std::string &what) : runtime_error(what) {} + ^~~~~~~~~~~~~ + +Upstream-Status: Submitted [https://github.com/rpm-software-management/libdnf/pull/867] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + libdnf/goal/Goal.hpp | 1 + + libdnf/module/ModulePackageContainer.hpp | 1 + + libdnf/repo/solvable/Dependency.cpp | 3 ++- + 3 files changed, 4 insertions(+), 1 deletion(-) + +diff --git a/libdnf/goal/Goal.hpp b/libdnf/goal/Goal.hpp +index f33dfa24..7b8d822c 100644 +--- a/libdnf/goal/Goal.hpp ++++ b/libdnf/goal/Goal.hpp +@@ -22,6 +22,7 @@ + #define __GOAL_HPP + + #include <memory> ++#include <stdexcept> + + #include "../dnf-types.h" + #include "../hy-goal.h" +diff --git a/libdnf/module/ModulePackageContainer.hpp b/libdnf/module/ModulePackageContainer.hpp +index 1f815fda..37a8832d 100644 +--- a/libdnf/module/ModulePackageContainer.hpp ++++ b/libdnf/module/ModulePackageContainer.hpp +@@ -30,6 +30,7 @@ + #include <string> + #include <vector> + #include <set> ++#include <stdexcept> + + //class ModulePackageContainer; + //typedef std::shared_ptr<ModulePackageContainer> ModulePackageContainerPtr; +diff --git a/libdnf/repo/solvable/Dependency.cpp b/libdnf/repo/solvable/Dependency.cpp +index 6682b729..0fc8b5cd 100644 +--- a/libdnf/repo/solvable/Dependency.cpp ++++ b/libdnf/repo/solvable/Dependency.cpp +@@ -18,6 +18,7 @@ + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + ++#include <stdexcept> + #include "Dependency.hpp" + #include "libdnf/utils/utils.hpp" + #include "libdnf/repo/DependencySplitter.hpp" +@@ -106,4 +107,4 @@ Dependency::getReldepId(DnfSack *sack, const char * reldepStr) + } + } + +-} +\ No newline at end of file ++} +-- +2.24.1 + diff --git a/poky/meta/recipes-devtools/libdnf/libdnf/fix-deprecation-warning.patch b/poky/meta/recipes-devtools/libdnf/libdnf/fix-deprecation-warning.patch new file mode 100644 index 0000000000..3a3e02f352 --- /dev/null +++ b/poky/meta/recipes-devtools/libdnf/libdnf/fix-deprecation-warning.patch @@ -0,0 +1,71 @@ +From 66d9b2ba3fbc7b04f2b5ad9d0e5371340c037b5f Mon Sep 17 00:00:00 2001 +From: Marek Blaha <mblaha@redhat.com> +Date: Wed, 10 Jul 2019 10:11:01 +0200 +Subject: [oe-core][PATCH 1/1] Fix Python 3.8 deprecation warning + (RhBug:1724244) + +This deprecation warning was introduced in Python 3.8 by +https://bugs.python.org/issue36381: + +/usr/lib/python3.8/site-packages/dnf/package.py:57: DeprecationWarning: PY_SSIZE_T_CLEAN will be required for '#' formats + return super(Package, self).chksum + +https://bugzilla.redhat.com/show_bug.cgi?id=1724244 +--- + python/hawkey/package-py.cpp | 3 ++- + python/hawkey/packagedelta-py.cpp | 3 ++- + 2 files changed, 4 insertions(+), 2 deletions(-) +--- + +Unchanged. Appears in version 0.35.2. + +Upstream-Status: Backport [git://github.com/rpm-software-management/libdnf.git] + +Signed-off-by: Joe Slater <joe.slater@windriver.com> + + +diff --git a/python/hawkey/package-py.cpp b/python/hawkey/package-py.cpp +index 5102bba..68e03cb 100644 +--- a/python/hawkey/package-py.cpp ++++ b/python/hawkey/package-py.cpp +@@ -18,6 +18,7 @@ + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + ++#define PY_SSIZE_T_CLEAN + #include <Python.h> + #include <stdio.h> + +@@ -251,7 +252,7 @@ get_chksum(_PackageObject *self, void *closure) + #if PY_MAJOR_VERSION < 3 + res = Py_BuildValue("is#", type, cs, checksum_length); + #else +- res = Py_BuildValue("iy#", type, cs, checksum_length); ++ res = Py_BuildValue("iy#", type, cs, (Py_ssize_t)checksum_length); + #endif + + return res; +diff --git a/python/hawkey/packagedelta-py.cpp b/python/hawkey/packagedelta-py.cpp +index ca1cb7d..1a64836 100644 +--- a/python/hawkey/packagedelta-py.cpp ++++ b/python/hawkey/packagedelta-py.cpp +@@ -18,6 +18,7 @@ + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + ++#define PY_SSIZE_T_CLEAN + #include <Python.h> + + // hawkey +@@ -92,7 +93,7 @@ get_chksum(_PackageDeltaObject *self, void *closure) + #if PY_MAJOR_VERSION < 3 + res = Py_BuildValue("is#", type, cs, checksum_length); + #else +- res = Py_BuildValue("iy#", type, cs, checksum_length); ++ res = Py_BuildValue("iy#", type, cs, (Py_ssize_t)checksum_length); + #endif + + return res; +-- +2.7.4 + diff --git a/poky/meta/recipes-devtools/libdnf/libdnf_0.47.0.bb b/poky/meta/recipes-devtools/libdnf/libdnf_0.28.1.bb index 1b06d66b19..cc2ceb8816 100644 --- a/poky/meta/recipes-devtools/libdnf/libdnf_0.47.0.bb +++ b/poky/meta/recipes-devtools/libdnf/libdnf_0.28.1.bb @@ -2,29 +2,27 @@ SUMMARY = "Library providing simplified C and Python API to libsolv" LICENSE = "LGPLv2.1" LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c" -SRC_URI = "git://github.com/rpm-software-management/libdnf;branch=dnf-4-master \ +SRC_URI = "git://github.com/rpm-software-management/libdnf \ file://0001-FindGtkDoc.cmake-drop-the-requirement-for-GTKDOC_SCA.patch \ file://0004-Set-libsolv-variables-with-pkg-config-cmake-s-own-mo.patch \ file://0001-Get-parameters-for-both-libsolv-and-libsolvext-libdn.patch \ file://0001-Add-WITH_TESTS-option.patch \ - file://0001-Look-fo-sphinx-only-if-documentation-is-actually-ena.patch \ - file://0001-Use-single-quotes-around-string-literals-used-in-SQL.patch \ + file://0001-include-stdexcept-for-runtime_error.patch \ + file://fix-deprecation-warning.patch \ " -SRCREV = "8330eea6985c4e4b53796f858de5b6b38b1ddf5c" +SRCREV = "751f89045b80d58c0d05800f74357cf78cdf7e77" UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)" S = "${WORKDIR}/git" -DEPENDS = "glib-2.0 libsolv libcheck librepo rpm gtk-doc libmodulemd json-c swig-native" +DEPENDS = "glib-2.0 libsolv libcheck librepo rpm gtk-doc libmodulemd-v1 json-c swig-native" inherit gtk-doc gobject-introspection cmake pkgconfig distutils3-base EXTRA_OECMAKE = " -DPYTHON_INSTALL_DIR=${PYTHON_SITEPACKAGES_DIR} -DWITH_MAN=OFF -DPYTHON_DESIRED=3 \ ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '-DWITH_GIR=ON', '-DWITH_GIR=OFF', d)} \ -DWITH_TESTS=OFF \ - -DWITH_ZCHUNK=OFF \ - -DWITH_HTML=OFF \ " EXTRA_OECMAKE_append_class-native = " -DWITH_GIR=OFF" EXTRA_OECMAKE_append_class-nativesdk = " -DWITH_GIR=OFF" diff --git a/poky/meta/recipes-devtools/libmodulemd/libmodulemd-v1/0001-spec_tmpl.sh-use-bin-sh-not-usr-bin-sh.patch b/poky/meta/recipes-devtools/libmodulemd/libmodulemd-v1/0001-spec_tmpl.sh-use-bin-sh-not-usr-bin-sh.patch new file mode 100644 index 0000000000..847b5f700b --- /dev/null +++ b/poky/meta/recipes-devtools/libmodulemd/libmodulemd-v1/0001-spec_tmpl.sh-use-bin-sh-not-usr-bin-sh.patch @@ -0,0 +1,22 @@ +From 4e67f6049b3f822fe6f5af46790a51ace581bf82 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Tue, 6 Nov 2018 13:41:29 +0100 +Subject: [PATCH] spec_tmpl.sh: use /bin/sh, not /usr/bin/sh + +Upstream-Status: Pending +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> + +--- + spec_tmpl.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/spec_tmpl.sh b/spec_tmpl.sh +index 0238087..126853c 100755 +--- a/spec_tmpl.sh ++++ b/spec_tmpl.sh +@@ -1,4 +1,4 @@ +-#!/usr/bin/sh ++#!/bin/sh + + version=$1 + template=$2 diff --git a/poky/meta/recipes-devtools/libmodulemd/libmodulemd_git.bb b/poky/meta/recipes-devtools/libmodulemd/libmodulemd-v1_git.bb index d440e60ee6..5409051d79 100644 --- a/poky/meta/recipes-devtools/libmodulemd/libmodulemd_git.bb +++ b/poky/meta/recipes-devtools/libmodulemd/libmodulemd-v1_git.bb @@ -2,19 +2,19 @@ SUMMARY = "C Library for manipulating module metadata files" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://COPYING;md5=25a3927bff3ee4f5b21bcb0ed3fcd6bb" -SRC_URI = "git://github.com/fedora-modularity/libmodulemd;protocol=https \ - file://0001-modulemd-generate-the-manpage-only-if-the-feature-is.patch \ - file://0002-meson.build-do-not-install-python-gi-bindings.patch \ +SRC_URI = "git://github.com/fedora-modularity/libmodulemd;protocol=https;branch=1.x-maint \ + file://0001-spec_tmpl.sh-use-bin-sh-not-usr-bin-sh.patch \ " -PV = "2.9.2" -SRCREV = "780750eab8a0587b20d033f335301f16d00ab9c9" +PV = "1.8.16" +SRCREV = "d0dcf7b373b3cf85cd39eb3bc23d31e06195a75a" +UPSTREAM_CHECK_GITTAGREGEX = "libmodulemd-(?P<pver>1.*\d)" S = "${WORKDIR}/git" inherit meson gobject-introspection -EXTRA_OEMESON = "-Ddeveloper_build=false -Dwith_docs=false -Drpmio=disabled -Dlibmagic=disabled -Dwith_manpages=disabled" +EXTRA_OEMESON = "-Ddeveloper_build=false -Dwith_docs=false" DEPENDS += "glib-2.0 libyaml glib-2.0-native python3" diff --git a/poky/meta/recipes-devtools/libmodulemd/libmodulemd/0001-modulemd-generate-the-manpage-only-if-the-feature-is.patch b/poky/meta/recipes-devtools/libmodulemd/libmodulemd/0001-modulemd-generate-the-manpage-only-if-the-feature-is.patch deleted file mode 100644 index d5c87a1154..0000000000 --- a/poky/meta/recipes-devtools/libmodulemd/libmodulemd/0001-modulemd-generate-the-manpage-only-if-the-feature-is.patch +++ /dev/null @@ -1,28 +0,0 @@ -From a04fd2c8ac9e0f7a6fc17f02b2a95227b3d0aae4 Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin <alex.kanavin@gmail.com> -Date: Tue, 31 Mar 2020 16:06:39 +0200 -Subject: [PATCH] modulemd: generate the manpage only if the feature is enabled - -Upstream-Status: Pending -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - modulemd/meson.build | 2 ++ - 1 file changed, 2 insertions(+) - -diff --git a/modulemd/meson.build b/modulemd/meson.build -index 9ef1902..9f71e72 100644 ---- a/modulemd/meson.build -+++ b/modulemd/meson.build -@@ -494,6 +494,7 @@ if with_docs - ) - endif - -+if with_manpages == 'enabled' - help2man_opts = [ - '--no-info', - '--section=1', -@@ -506,3 +507,4 @@ custom_target( - ], - install: true, - install_dir: join_paths(get_option('mandir'), 'man1')) -+endif diff --git a/poky/meta/recipes-devtools/libmodulemd/libmodulemd/0002-meson.build-do-not-install-python-gi-bindings.patch b/poky/meta/recipes-devtools/libmodulemd/libmodulemd/0002-meson.build-do-not-install-python-gi-bindings.patch deleted file mode 100644 index a97fb73907..0000000000 --- a/poky/meta/recipes-devtools/libmodulemd/libmodulemd/0002-meson.build-do-not-install-python-gi-bindings.patch +++ /dev/null @@ -1,23 +0,0 @@ -From d7eeac90fe02ccf5c5e4334e41ec75fc33803643 Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin <alex.kanavin@gmail.com> -Date: Tue, 31 Mar 2020 16:12:28 +0200 -Subject: [PATCH] meson.build: do not install python gi bindings - -These are unnecessary for oe-core, and the install location -is incorrectly determined using native python. - -Upstream-Status: Inappropriate [oe-core specific] -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - meson.build | 1 - - 1 file changed, 1 deletion(-) - -diff --git a/meson.build b/meson.build -index a8b02b4..8ff737b 100644 ---- a/meson.build -+++ b/meson.build -@@ -171,4 +171,3 @@ configure_file( - ) - - subdir('modulemd') --subdir('bindings/python') diff --git a/poky/meta/recipes-devtools/meson/meson.inc b/poky/meta/recipes-devtools/meson/meson.inc index 50fb41ac98..0a58c971ae 100644 --- a/poky/meta/recipes-devtools/meson/meson.inc +++ b/poky/meta/recipes-devtools/meson/meson.inc @@ -26,6 +26,7 @@ SRC_URI_append_class-native = " \ " UPSTREAM_CHECK_URI = "https://github.com/mesonbuild/meson/releases" +UPSTREAM_CHECK_REGEX = "meson-(?P<pver>\d+(\.\d+)+)\.tar" inherit setuptools3 diff --git a/poky/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch b/poky/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch index e64488be46..9ce31e5489 100644 --- a/poky/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch +++ b/poky/meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch @@ -16,12 +16,12 @@ index 0f277a7..24578ea 100644 --- a/mesonbuild/envconfig.py +++ b/mesonbuild/envconfig.py @@ -192,7 +192,7 @@ class MachineInfo: - + cpu_family = literal['cpu_family'] if cpu_family not in known_cpu_families: - mlog.warning('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % cpu_family) + raise EnvironmentException('Unknown CPU family %s, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.' % cpu_family) - + endian = literal['endian'] if endian not in ('little', 'big'): diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py @@ -30,12 +30,12 @@ index dc8b14f..3aab71e 100644 +++ b/mesonbuild/environment.py @@ -354,9 +354,7 @@ def detect_cpu_family(compilers: CompilersDict) -> str: trial = 'parisc' - + if trial not in known_cpu_families: - mlog.warning('Unknown CPU family {!r}, please report this at ' - 'https://github.com/mesonbuild/meson/issues/new with the ' - 'output of `uname -a` and `cat /proc/cpuinfo`'.format(trial)) + raise EnvironmentException('Unknown CPU family %s, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.' % trial) - + return trial - + diff --git a/poky/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch b/poky/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch index d2c3f8cdfd..ce18660756 100644 --- a/poky/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch +++ b/poky/meta/recipes-devtools/meson/meson/0002-Support-building-allarch-recipes-again.patch @@ -17,8 +17,8 @@ index 24578ea..216e71f 100644 --- a/mesonbuild/envconfig.py +++ b/mesonbuild/envconfig.py @@ -36,6 +36,7 @@ _T = typing.TypeVar('_T') - - + + known_cpu_families = ( + 'allarch', 'aarch64', diff --git a/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch b/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch index a5baca0938..dc822fb1fc 100644 --- a/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch +++ b/poky/meta/recipes-devtools/meson/meson/0003-native_bindir.patch @@ -28,25 +28,25 @@ index 40e304c..4b687df 100644 @@ -184,7 +184,7 @@ class Dependency: def get_exe_args(self, compiler): return [] - + - def get_pkgconfig_variable(self, variable_name, kwargs): + def get_pkgconfig_variable(self, variable_name, kwargs, use_native=False): raise DependencyException('{!r} is not a pkgconfig dependency'.format(self.name)) - + def get_configtool_variable(self, variable_name): @@ -247,7 +247,7 @@ class InternalDependency(Dependency): self.sources = sources self.ext_deps = ext_deps - + - def get_pkgconfig_variable(self, variable_name, kwargs): + def get_pkgconfig_variable(self, variable_name, kwargs, use_native=False): raise DependencyException('Method "get_pkgconfig_variable()" is ' 'invalid for an internal dependency') - + @@ -673,15 +673,18 @@ class PkgConfigDependency(ExternalDependency): return s.format(self.__class__.__name__, self.name, self.is_found, self.version_reqs) - + - def _call_pkgbin_real(self, args, env): - cmd = self.pkgbin.get_command() + args + def _call_pkgbin_real(self, args, env, use_native=False): @@ -59,7 +59,7 @@ index 40e304c..4b687df 100644 call = ' '.join(cmd) mlog.debug("Called `{}` -> {}\n{}".format(call, rc, out)) return rc, out, err - + - def _call_pkgbin(self, args, env=None): + def _call_pkgbin(self, args, env=None, use_native=False): # Always copy the environment since we're going to modify it @@ -72,21 +72,21 @@ index 40e304c..4b687df 100644 - cache[(self.pkgbin, targs, fenv)] = self._call_pkgbin_real(args, env) + cache[(self.pkgbin, targs, fenv)] = self._call_pkgbin_real(args, env, use_native) return cache[(self.pkgbin, targs, fenv)] - + def _convert_mingw_paths(self, args: T.List[str]) -> T.List[str]: @@ -907,7 +910,7 @@ class PkgConfigDependency(ExternalDependency): (self.name, out_raw)) self.link_args, self.raw_link_args = self._search_libs(out, out_raw) - + - def get_pkgconfig_variable(self, variable_name, kwargs): + def get_pkgconfig_variable(self, variable_name, kwargs, use_native=False): options = ['--variable=' + variable_name, self.name] - + if 'define_variable' in kwargs: @@ -920,7 +923,7 @@ class PkgConfigDependency(ExternalDependency): - + options = ['--define-variable=' + '='.join(definition)] + options - + - ret, out, err = self._call_pkgbin(options) + ret, out, err = self._call_pkgbin(options, use_native=use_native) variable = '' @@ -104,7 +104,7 @@ index da411ef..856506a 100644 + prefix = core.get_pkgconfig_variable('exec_prefix', {}, use_native=True) if prefix: self.bindir = os.path.join(prefix, 'bin') - + @@ -508,7 +508,7 @@ class Qt4Dependency(QtBaseDependency): applications = ['moc', 'uic', 'rcc', 'lupdate', 'lrelease'] for application in applications: @@ -113,13 +113,13 @@ index da411ef..856506a 100644 + return os.path.dirname(core.get_pkgconfig_variable('%s_location' % application, {}, use_native=True)) except MesonException: pass - + @@ -518,7 +518,7 @@ class Qt5Dependency(QtBaseDependency): QtBaseDependency.__init__(self, 'qt5', env, kwargs) - + def get_pkgconfig_host_bins(self, core): - return core.get_pkgconfig_variable('host_bins', {}) + return core.get_pkgconfig_variable('host_bins', {}, use_native=True) - + def get_private_includes(self, mod_inc_dir, module): return _qt_get_private_includes(mod_inc_dir, module, self.version) diff --git a/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb b/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb index a20e316a3d..07e2402545 100644 --- a/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb +++ b/poky/meta/recipes-devtools/opkg/opkg-keyrings_1.0.bb @@ -36,5 +36,8 @@ FILES_${PN} = "${datadir}/opkg/keyrings" RDEPENDS_${PN} = "opkg" pkg_postinst_ontarget_${PN} () { -opkg-key populate + if test -x ${bindir}/opkg-key + then + ${bindir}/opkg-key populate + fi } diff --git a/poky/meta/recipes-devtools/perl/files/0001-tests-adjust-to-correctly-exclude-unbuilt-extensions.patch b/poky/meta/recipes-devtools/perl/files/0001-tests-adjust-to-correctly-exclude-unbuilt-extensions.patch new file mode 100644 index 0000000000..0f3a2c6327 --- /dev/null +++ b/poky/meta/recipes-devtools/perl/files/0001-tests-adjust-to-correctly-exclude-unbuilt-extensions.patch @@ -0,0 +1,27 @@ +From b0d53cfd785f64002128ac5eecc4aed0663d9c30 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Thu, 9 Jan 2020 17:26:55 +0100 +Subject: [PATCH] tests: adjust to correctly exclude unbuilt extensions + +Issue is reported here: +https://github.com/arsv/perl-cross/issues/85 + +Upstream-Status: Inappropriate [issue caused by perl-cross] +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> +--- + t/TEST | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/t/TEST b/t/TEST +index a9c844f..8d3505f 100755 +--- a/t/TEST ++++ b/t/TEST +@@ -419,7 +419,7 @@ sub _tests_from_manifest { + while (<MANI>) { + if (m!^((?:cpan|dist|ext)/(\S+)/+(?:[^/\s]+\.t|test\.pl)|lib/\S+?(?:\.t|test\.pl))\s!) { + my $t = $1; +- my $extension = $2; ++ my $extension = $1."/".$2; + + # XXX Generates way too many error lines currently. Skip for + # v5.22 diff --git a/poky/meta/recipes-devtools/perl/files/determinism.patch b/poky/meta/recipes-devtools/perl/files/determinism.patch index ccdd52a0d0..ed4d06f5ec 100644 --- a/poky/meta/recipes-devtools/perl/files/determinism.patch +++ b/poky/meta/recipes-devtools/perl/files/determinism.patch @@ -21,6 +21,19 @@ RP 2020/2/7 Upstream-Status: Pending [75% submitted] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org +Index: perl-5.30.1/cnf/configure_attr.sh +=================================================================== +--- perl-5.30.1.orig/cnf/configure_attr.sh ++++ perl-5.30.1/cnf/configure_attr.sh +@@ -131,7 +131,7 @@ if not hinted d_c99_variadic_macros 'sup + try_start + try_add '#include <stdio.h>' + try_add '#define foo(fmt, ...) printf(fmt, __VA_ARGS__)' +- try_add 'int main(void) { foo("%i\n", 1234); return 0; }' ++ try_add 'int main(void) { foo("%i", 1234); return 0; }' + try_compile + resdef d_c99_variadic_macros 'supported' 'missing' + fi Index: perl-5.30.1/cnf/configure_mods.sh =================================================================== --- perl-5.30.1.orig/cnf/configure_mods.sh diff --git a/poky/meta/recipes-devtools/perl/files/racefix.patch b/poky/meta/recipes-devtools/perl/files/racefix.patch new file mode 100644 index 0000000000..bac42d26ae --- /dev/null +++ b/poky/meta/recipes-devtools/perl/files/racefix.patch @@ -0,0 +1,24 @@ +In our builds Config_heavy.pl sometimes has lines: +cwarnflags=XXX +ccstdflags=XXX +and sometimes does not. +The reason is that this information is pulled from cflags by configpm and yet +there is no dependency in the Makefile. Add one to fix this. + +Upstream-Status: Submitted [https://github.com/arsv/perl-cross/pull/89] +RP 2020/2/19 +Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> + +Index: perl-5.30.1/Makefile +=================================================================== +--- perl-5.30.1.orig/Makefile ++++ perl-5.30.1/Makefile +@@ -204,7 +204,7 @@ configpod: $(CONFIGPOD) + git_version.h lib/Config_git.pl: make_patchnum.pl | miniperl$X + ./miniperl_top make_patchnum.pl + +-lib/Config.pm lib/Config_heavy.pl lib/Config.pod: config.sh \ ++lib/Config.pm lib/Config_heavy.pl lib/Config.pod: config.sh cflags \ + lib/Config_git.pl Porting/Glossary | miniperl$X + ./miniperl_top configpm + diff --git a/poky/meta/recipes-devtools/perl/perl_5.30.2.bb b/poky/meta/recipes-devtools/perl/perl_5.30.1.bb index 778c420b2e..9d747aa5b4 100644 --- a/poky/meta/recipes-devtools/perl/perl_5.30.2.bb +++ b/poky/meta/recipes-devtools/perl/perl_5.30.1.bb @@ -8,7 +8,7 @@ LIC_FILES_CHKSUM = "file://Copying;md5=5b122a36d0f6dc55279a0ebc69f3c60b \ SRC_URI = "https://www.cpan.org/src/5.0/perl-${PV}.tar.gz;name=perl \ - https://github.com/arsv/perl-cross/releases/download/1.3.2/perl-cross-1.3.2.tar.gz;name=perl-cross \ + https://github.com/arsv/perl-cross/releases/download/1.3.1/perl-cross-1.3.1.tar.gz;name=perl-cross \ file://perl-rdepends.txt \ file://0001-configure_tool.sh-do-not-quote-the-argument-to-comma.patch \ file://0001-ExtUtils-MakeMaker-add-LDFLAGS-when-linking-binary-m.patch \ @@ -20,8 +20,10 @@ SRC_URI = "https://www.cpan.org/src/5.0/perl-${PV}.tar.gz;name=perl \ file://0001-configure_path.sh-do-not-hardcode-prefix-lib-as-libr.patch \ file://0001-enc2xs-Add-environment-variable-to-suppress-comments.patch \ file://0002-Constant-Fix-up-shebang.patch \ + file://0001-tests-adjust-to-correctly-exclude-unbuilt-extensions.patch \ file://0001-PATCH-perl-134117-Close-DATA-in-loc_tools.pl.patch \ file://determinism.patch \ + file://racefix.patch \ " SRC_URI_append_class-native = " \ file://perl-configpm-switch.patch \ @@ -30,8 +32,10 @@ SRC_URI_append_class-target = " \ file://encodefix.patch \ " -SRC_URI[perl.sha256sum] = "66db7df8a91979eb576fac91743644da878244cf8ee152f02cd6f5cd7a731689" -SRC_URI[perl-cross.sha256sum] = "defa12f0ad7be0b6c48b4f76e2fb5b37c1b37fbeb6e9ebe938279cd539a0c20c" +SRC_URI[perl.md5sum] = "6438eb7b8db9bbde28e01086de376a46" +SRC_URI[perl.sha256sum] = "bf3d25571ff1ee94186177c2cdef87867fd6a14aa5a84f0b1fb7bf798f42f964" +SRC_URI[perl-cross.md5sum] = "1e463b105cfa56d251a86979af23e3a7" +SRC_URI[perl-cross.sha256sum] = "edce0b0c2f725e2db3f203d6d8e9f3f7161256f5d1590551e40694f21200141d" S = "${WORKDIR}/perl-${PV}" diff --git a/poky/meta/recipes-devtools/pseudo/files/0001-pseudo_ipc.h-Fix-enum-typedef.patch b/poky/meta/recipes-devtools/pseudo/files/0001-pseudo_ipc.h-Fix-enum-typedef.patch new file mode 100644 index 0000000000..33d4ef3b2f --- /dev/null +++ b/poky/meta/recipes-devtools/pseudo/files/0001-pseudo_ipc.h-Fix-enum-typedef.patch @@ -0,0 +1,31 @@ +From a491aececfedf7313d29b80d626e0964fb533548 Mon Sep 17 00:00:00 2001 +From: Jacob Kroon <jacob.kroon@gmail.com> +Date: Sun, 3 May 2020 06:24:03 +0200 +Subject: [PATCH] pseudo_ipc.h: Fix enum typedef + +'pseudo_access_t' is a type, so use typedef. + +Fixes building pseudo with gcc 10 where -fno-common is the default. + +Signed-off-by: Jacob Kroon <jacob.kroon@gmail.com> +Upstream-Status: Submitted [https://lists.openembedded.org/g/openembedded-core/message/137758] +--- + pseudo_ipc.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/pseudo_ipc.h b/pseudo_ipc.h +index caeae5c..d945257 100644 +--- a/pseudo_ipc.h ++++ b/pseudo_ipc.h +@@ -29,7 +29,7 @@ typedef struct { + char path[]; + } pseudo_msg_t; + +-enum { ++typedef enum { + PSA_EXEC = 1, + PSA_WRITE = (PSA_EXEC << 1), + PSA_READ = (PSA_WRITE << 1), +-- +2.26.2 + diff --git a/poky/meta/recipes-devtools/pseudo/pseudo_git.bb b/poky/meta/recipes-devtools/pseudo/pseudo_git.bb index a3049c5e6c..324ae9071f 100644 --- a/poky/meta/recipes-devtools/pseudo/pseudo_git.bb +++ b/poky/meta/recipes-devtools/pseudo/pseudo_git.bb @@ -12,6 +12,7 @@ SRC_URI = "git://git.yoctoproject.org/pseudo \ file://0006-xattr-adjust-for-attr-2.4.48-release.patch \ file://seccomp.patch \ file://0001-pseudo-On-a-DB-fixup-remove-files-that-do-not-exist-.patch \ + file://0001-pseudo_ipc.h-Fix-enum-typedef.patch \ " SRCREV = "060058bb29f70b244e685b3c704eb0641b736f73" diff --git a/poky/meta/recipes-devtools/python-numpy/files/0001-convert-shebang-from-python-to-python3.patch b/poky/meta/recipes-devtools/python-numpy/files/0001-convert-shebang-from-python-to-python3.patch index a416244420..b86e131122 100644 --- a/poky/meta/recipes-devtools/python-numpy/files/0001-convert-shebang-from-python-to-python3.patch +++ b/poky/meta/recipes-devtools/python-numpy/files/0001-convert-shebang-from-python-to-python3.patch @@ -1,4 +1,4 @@ -From 00848d760fa3999e2bed759b585452b35d65d6ec Mon Sep 17 00:00:00 2001 +From c53237f90e4a3a435a20517552186d394d6d09c8 Mon Sep 17 00:00:00 2001 From: Changqing Li <changqing.li@windriver.com> Date: Thu, 5 Mar 2020 12:02:35 +0800 Subject: [PATCH] convert shebang from python to python3 @@ -7,61 +7,62 @@ Upstream-Status: Backport [https://github.com/numpy/numpy/commit/583901a074dc65145d3d6136ba7dcd02634d680b] Signed-off-by: Changqing Li <changqing.li@windriver.com> - --- - doc/DISTUTILS.rst.txt | 2 +- - doc/cdoc/numpyfilter.py | 2 +- - doc/postprocess.py | 2 +- - doc/summarize.py | 2 +- - numpy/distutils/conv_template.py | 2 +- - numpy/distutils/cpuinfo.py | 2 +- - numpy/distutils/from_template.py | 2 +- - numpy/distutils/setup.py | 2 +- - numpy/distutils/system_info.py | 2 +- - numpy/f2py/__init__.py | 2 +- - numpy/f2py/auxfuncs.py | 2 +- - numpy/f2py/capi_maps.py | 2 +- - numpy/f2py/cb_rules.py | 2 +- - numpy/f2py/cfuncs.py | 2 +- - numpy/f2py/common_rules.py | 2 +- - numpy/f2py/crackfortran.py | 2 +- - numpy/f2py/diagnose.py | 2 +- - numpy/f2py/f2py2e.py | 2 +- - numpy/f2py/f90mod_rules.py | 2 +- - numpy/f2py/func2subr.py | 2 +- - numpy/f2py/rules.py | 2 +- - numpy/f2py/setup.py | 2 +- - numpy/f2py/use_rules.py | 2 +- - numpy/linalg/lapack_lite/clapack_scrub.py | 2 +- - numpy/linalg/lapack_lite/make_lite.py | 2 +- - numpy/ma/bench.py | 2 +- - numpy/ma/setup.py | 2 +- - numpy/matrixlib/setup.py | 2 +- - numpy/random/_examples/cython/extending.pyx | 2 +- - numpy/random/_examples/cython/extending_distributions.pyx | 2 +- - numpy/setup.py | 2 +- - numpy/testing/print_coercion_tables.py | 2 +- - numpy/testing/setup.py | 2 +- - runtests.py | 2 +- - setup.py | 2 +- - tools/c_coverage/c_coverage_report.py | 2 +- - tools/changelog.py | 2 +- - tools/ci/push_docs_to_repo.py | 2 +- - tools/find_deprecated_escaped_characters.py | 2 +- - tools/refguide_check.py | 2 +- - tools/swig/test/setup.py | 2 +- - tools/swig/test/testArray.py | 2 +- - tools/swig/test/testFarray.py | 2 +- - tools/swig/test/testFlat.py | 2 +- - tools/swig/test/testFortran.py | 2 +- - tools/swig/test/testMatrix.py | 2 +- - tools/swig/test/testSuperTensor.py | 2 +- - tools/swig/test/testTensor.py | 2 +- - tools/swig/test/testVector.py | 2 +- - 49 files changed, 49 insertions(+), 49 deletions(-) + doc/DISTUTILS.rst.txt | 2 +- + doc/cdoc/numpyfilter.py | 2 +- + doc/postprocess.py | 2 +- + doc/summarize.py | 2 +- + numpy/distutils/conv_template.py | 2 +- + numpy/distutils/cpuinfo.py | 2 +- + numpy/distutils/from_template.py | 2 +- + numpy/distutils/setup.py | 2 +- + numpy/distutils/system_info.py | 2 +- + numpy/f2py/__init__.py | 2 +- + numpy/f2py/auxfuncs.py | 2 +- + numpy/f2py/capi_maps.py | 2 +- + numpy/f2py/cb_rules.py | 2 +- + numpy/f2py/cfuncs.py | 2 +- + numpy/f2py/common_rules.py | 2 +- + numpy/f2py/crackfortran.py | 2 +- + numpy/f2py/diagnose.py | 2 +- + numpy/f2py/f2py2e.py | 2 +- + numpy/f2py/f90mod_rules.py | 2 +- + numpy/f2py/func2subr.py | 2 +- + numpy/f2py/rules.py | 2 +- + numpy/f2py/setup.py | 2 +- + numpy/f2py/use_rules.py | 2 +- + numpy/linalg/lapack_lite/clapack_scrub.py | 2 +- + numpy/linalg/lapack_lite/make_lite.py | 2 +- + numpy/ma/bench.py | 2 +- + numpy/ma/setup.py | 2 +- + numpy/matrixlib/setup.py | 2 +- + numpy/random/examples/cython/extending.pyx | 2 +- + numpy/random/examples/cython/extending_distributions.pyx | 2 +- + numpy/setup.py | 2 +- + numpy/testing/print_coercion_tables.py | 2 +- + numpy/testing/setup.py | 2 +- + runtests.py | 2 +- + setup.py | 2 +- + tools/c_coverage/c_coverage_report.py | 2 +- + tools/changelog.py | 2 +- + tools/ci/push_docs_to_repo.py | 2 +- + tools/cythonize.py | 2 +- + tools/find_deprecated_escaped_characters.py | 2 +- + tools/refguide_check.py | 2 +- + tools/swig/test/setup.py | 2 +- + tools/swig/test/testArray.py | 2 +- + tools/swig/test/testFarray.py | 2 +- + tools/swig/test/testFlat.py | 2 +- + tools/swig/test/testFortran.py | 2 +- + tools/swig/test/testMatrix.py | 2 +- + tools/swig/test/testSuperTensor.py | 2 +- + tools/swig/test/testTensor.py | 2 +- + tools/swig/test/testVector.py | 2 +- + tools/test-installed-numpy.py | 2 +- + 51 files changed, 51 insertions(+), 51 deletions(-) diff --git a/doc/DISTUTILS.rst.txt b/doc/DISTUTILS.rst.txt -index bcef825..bc1700f 100644 +index eadde63..2402110 100644 --- a/doc/DISTUTILS.rst.txt +++ b/doc/DISTUTILS.rst.txt @@ -59,7 +59,7 @@ SciPy pure Python package example @@ -114,7 +115,7 @@ index 3bcb7b8..88432c8 100644 takes templated file .xxx.src and produces .xxx file where .xxx is .i or .c or .h, using the following template rules diff --git a/numpy/distutils/cpuinfo.py b/numpy/distutils/cpuinfo.py -index bc97283..87502a9 100644 +index 5802993..7f6742e 100644 --- a/numpy/distutils/cpuinfo.py +++ b/numpy/distutils/cpuinfo.py @@ -1,4 +1,4 @@ @@ -144,7 +145,7 @@ index 82a53bd..646921b 100644 def configuration(parent_package='',top_path=None): diff --git a/numpy/distutils/system_info.py b/numpy/distutils/system_info.py -index 4f340b6..189081d 100644 +index f94dce1..df526f6 100644 --- a/numpy/distutils/system_info.py +++ b/numpy/distutils/system_info.py @@ -1,4 +1,4 @@ @@ -154,7 +155,7 @@ index 4f340b6..189081d 100644 This file defines a set of system_info classes for getting information about various resources (libraries, library directories, diff --git a/numpy/f2py/__init__.py b/numpy/f2py/__init__.py -index 42e3632..09a3657 100644 +index d146739..0a83b99 100644 --- a/numpy/f2py/__init__.py +++ b/numpy/f2py/__init__.py @@ -1,4 +1,4 @@ @@ -174,7 +175,7 @@ index 404bdbd..d23d959 100644 Auxiliary functions for f2py2e. diff --git a/numpy/f2py/capi_maps.py b/numpy/f2py/capi_maps.py -index ce79f68..e5d3fd2 100644 +index c41dd77..a3e2dc2 100644 --- a/numpy/f2py/capi_maps.py +++ b/numpy/f2py/capi_maps.py @@ -1,4 +1,4 @@ @@ -194,7 +195,7 @@ index 183d7c2..93e93fe 100644 Build call-back mechanism for f2py2e. diff --git a/numpy/f2py/cfuncs.py b/numpy/f2py/cfuncs.py -index ccb7b3a..cdb783d 100644 +index d59b630..3847745 100644 --- a/numpy/f2py/cfuncs.py +++ b/numpy/f2py/cfuncs.py @@ -1,4 +1,4 @@ @@ -204,7 +205,7 @@ index ccb7b3a..cdb783d 100644 C declarations, CPP macros, and C functions for f2py2e. diff --git a/numpy/f2py/common_rules.py b/numpy/f2py/common_rules.py -index f61d881..fe510bf 100644 +index 62c1ba2..c1825d4 100644 --- a/numpy/f2py/common_rules.py +++ b/numpy/f2py/common_rules.py @@ -1,4 +1,4 @@ @@ -234,7 +235,7 @@ index 0241fed..6c0304c 100644 import os diff --git a/numpy/f2py/f2py2e.py b/numpy/f2py/f2py2e.py -index d03eff9..c17bfd9 100755 +index 110337f..c0789f6 100755 --- a/numpy/f2py/f2py2e.py +++ b/numpy/f2py/f2py2e.py @@ -1,4 +1,4 @@ @@ -264,7 +265,7 @@ index 6010d5a..fdea0c2 100644 Rules for building C/API module with f2py2e. diff --git a/numpy/f2py/rules.py b/numpy/f2py/rules.py -index f2f713b..f87b03c 100755 +index 1b41498..790d197 100755 --- a/numpy/f2py/rules.py +++ b/numpy/f2py/rules.py @@ -1,4 +1,4 @@ @@ -274,7 +275,7 @@ index f2f713b..f87b03c 100755 Rules for building C/API module with f2py2e. diff --git a/numpy/f2py/setup.py b/numpy/f2py/setup.py -index a8c1401..2e7a517 100644 +index c0c50ce..044c9f2 100644 --- a/numpy/f2py/setup.py +++ b/numpy/f2py/setup.py @@ -1,4 +1,4 @@ @@ -343,26 +344,26 @@ index d0981d6..57534d1 100644 from __future__ import division, print_function def configuration(parent_package='', top_path=None): -diff --git a/numpy/random/_examples/cython/extending.pyx b/numpy/random/_examples/cython/extending.pyx -index 7a0dfe0..3a7f81a 100644 ---- a/numpy/random/_examples/cython/extending.pyx -+++ b/numpy/random/_examples/cython/extending.pyx +diff --git a/numpy/random/examples/cython/extending.pyx b/numpy/random/examples/cython/extending.pyx +index a6a4ba4..33f28f9 100644 +--- a/numpy/random/examples/cython/extending.pyx ++++ b/numpy/random/examples/cython/extending.pyx @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 #cython: language_level=3 from libc.stdint cimport uint32_t -diff --git a/numpy/random/_examples/cython/extending_distributions.pyx b/numpy/random/_examples/cython/extending_distributions.pyx -index 1bef506..4da6a4b 100644 ---- a/numpy/random/_examples/cython/extending_distributions.pyx -+++ b/numpy/random/_examples/cython/extending_distributions.pyx +diff --git a/numpy/random/examples/cython/extending_distributions.pyx b/numpy/random/examples/cython/extending_distributions.pyx +index 3cefec9..7a526ab 100644 +--- a/numpy/random/examples/cython/extending_distributions.pyx ++++ b/numpy/random/examples/cython/extending_distributions.pyx @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 #cython: language_level=3 """ - This file shows how the to use a BitGenerator to create a distribution. + This file shows how the distributions that are accessed through diff --git a/numpy/setup.py b/numpy/setup.py index 4ccdaee..db06c82 100644 --- a/numpy/setup.py @@ -374,7 +375,7 @@ index 4ccdaee..db06c82 100644 diff --git a/numpy/testing/print_coercion_tables.py b/numpy/testing/print_coercion_tables.py -index 72b22ce..1e9a301 100755 +index 3a359f4..a9c5363 100755 --- a/numpy/testing/print_coercion_tables.py +++ b/numpy/testing/print_coercion_tables.py @@ -1,4 +1,4 @@ @@ -394,7 +395,7 @@ index 7c3f2fb..bd315ee 100755 diff --git a/runtests.py b/runtests.py -index a38054f..383ddaa 100755 +index 23245ae..cafdb92 100755 --- a/runtests.py +++ b/runtests.py @@ -1,4 +1,4 @@ @@ -404,7 +405,7 @@ index a38054f..383ddaa 100755 runtests.py [OPTIONS] [-- ARGS] diff --git a/setup.py b/setup.py -index d7f807b..705ea5d 100755 +index a205913..010884f 100755 --- a/setup.py +++ b/setup.py @@ -1,4 +1,4 @@ @@ -443,6 +444,16 @@ index a989668..ae53054 100755 import argparse import subprocess +diff --git a/tools/cythonize.py b/tools/cythonize.py +index c81b72d..c1d4384 100755 +--- a/tools/cythonize.py ++++ b/tools/cythonize.py +@@ -1,4 +1,4 @@ +-#!/usr/bin/env python ++#!/usr/bin/env python3 + """ cythonize + + Cythonize pyx files into C files as needed. diff --git a/tools/find_deprecated_escaped_characters.py b/tools/find_deprecated_escaped_characters.py index 6f90001..10e0378 100644 --- a/tools/find_deprecated_escaped_characters.py @@ -454,7 +465,7 @@ index 6f90001..10e0378 100644 Look for escape sequences deprecated in Python 3.6. diff --git a/tools/refguide_check.py b/tools/refguide_check.py -index 2c62809..a19a29e 100644 +index c208072..798e322 100644 --- a/tools/refguide_check.py +++ b/tools/refguide_check.py @@ -1,4 +1,4 @@ @@ -484,7 +495,7 @@ index 8d9c797..54ffe71 100755 # System imports diff --git a/tools/swig/test/testFarray.py b/tools/swig/test/testFarray.py -index e8bf711..b377f7c 100755 +index 0037dc9..bedf384 100755 --- a/tools/swig/test/testFarray.py +++ b/tools/swig/test/testFarray.py @@ -1,4 +1,4 @@ @@ -553,3 +564,16 @@ index 45e763b..067b922 100755 from __future__ import division, absolute_import, print_function # System imports +diff --git a/tools/test-installed-numpy.py b/tools/test-installed-numpy.py +index 5240253..fd7541c 100755 +--- a/tools/test-installed-numpy.py ++++ b/tools/test-installed-numpy.py +@@ -1,4 +1,4 @@ +-#!/usr/bin/env python ++#!/usr/bin/env python3 + from __future__ import division, absolute_import, print_function + + # A simple script to test the installed version of numpy by calling +-- +2.7.4 + diff --git a/poky/meta/recipes-devtools/python-numpy/files/0001-numpy-random-setup.py-remove-the-detection-of-x86-ta.patch b/poky/meta/recipes-devtools/python-numpy/files/0001-numpy-random-setup.py-remove-the-detection-of-x86-ta.patch new file mode 100644 index 0000000000..9da6a2b3da --- /dev/null +++ b/poky/meta/recipes-devtools/python-numpy/files/0001-numpy-random-setup.py-remove-the-detection-of-x86-ta.patch @@ -0,0 +1,32 @@ +From b881e0b2ba9cf1a4aa351a1c1ea90b1e1776ce21 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Mon, 12 Aug 2019 15:37:36 +0200 +Subject: [PATCH] numpy/random/setup.py: remove the detection of x86 targets + via uname() + +This was badly breaking compilation for ARM targets (and possibly +other non-x86 targets); if -msse2 is desirable for x86 builds it has +to be passed through another channel. + +Upstream-Status: Inappropriate [oe-core specific] +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> +--- + numpy/random/setup.py | 5 ----- + 1 file changed, 5 deletions(-) + +diff --git a/numpy/random/setup.py b/numpy/random/setup.py +index a1bf3b8..60fb534 100644 +--- a/numpy/random/setup.py ++++ b/numpy/random/setup.py +@@ -49,11 +49,6 @@ def configuration(parent_package='', top_path=None): + elif not is_msvc: + # Some bit generators require c99 + EXTRA_COMPILE_ARGS += ['-std=c99'] +- INTEL_LIKE = any(arch in platform.machine() +- for arch in ('x86', 'i686', 'i386', 'amd64')) +- if INTEL_LIKE: +- # Assumes GCC or GCC-like compiler +- EXTRA_COMPILE_ARGS += ['-msse2'] + + # Use legacy integer variable sizes + LEGACY_DEFS = [('NP_RANDOM_LEGACY', '1')] diff --git a/poky/meta/recipes-devtools/python-numpy/python-numpy.inc b/poky/meta/recipes-devtools/python-numpy/python-numpy.inc index 727755393e..42032a04a8 100644 --- a/poky/meta/recipes-devtools/python-numpy/python-numpy.inc +++ b/poky/meta/recipes-devtools/python-numpy/python-numpy.inc @@ -7,10 +7,11 @@ SRCNAME = "numpy" SRC_URI = "https://github.com/${SRCNAME}/${SRCNAME}/releases/download/v${PV}/${SRCNAME}-${PV}.tar.gz \ file://0001-Don-t-search-usr-and-so-on-for-libraries-by-default-.patch \ + file://0001-numpy-random-setup.py-remove-the-detection-of-x86-ta.patch \ file://0001-convert-shebang-from-python-to-python3.patch \ " -SRC_URI[md5sum] = "cd631c761f141d382b4e1b31c8232fc0" -SRC_URI[sha256sum] = "93ee59ec38f3bf8f9a42d5f4301f60e6825a4a6385a145f70badcd2bf2a11134" +SRC_URI[md5sum] = "9147c3ee75e58d657b5b8b5a4f3564e0" +SRC_URI[sha256sum] = "fb0415475e673cb9a6dd816df999e0ab9f86fa3af2b1770944e7288d2bea4ac9" UPSTREAM_CHECK_URI = "https://github.com/numpy/numpy/releases" UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar" @@ -18,8 +19,6 @@ UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar" # Needed for building with gcc 4.x from centos 7 CFLAGS_append_class-native = " -std=c99" -DEPENDS += "python3-cython-native" - S = "${WORKDIR}/numpy-${PV}" CLEANBROKEN = "1" diff --git a/poky/meta/recipes-devtools/python-numpy/python3-numpy_1.18.3.bb b/poky/meta/recipes-devtools/python-numpy/python3-numpy_1.17.4.bb index d388e88d25..d388e88d25 100644 --- a/poky/meta/recipes-devtools/python-numpy/python3-numpy_1.18.3.bb +++ b/poky/meta/recipes-devtools/python-numpy/python3-numpy_1.17.4.bb diff --git a/poky/meta/recipes-devtools/python/python-cython.inc b/poky/meta/recipes-devtools/python/python-cython.inc deleted file mode 100644 index 437e796629..0000000000 --- a/poky/meta/recipes-devtools/python/python-cython.inc +++ /dev/null @@ -1,41 +0,0 @@ -DESCRIPTION = "Cython is a language specially designed for writing Python extension modules. \ -It's designed to bridge the gap between the nice, high-level, easy-to-use world of Python \ -and the messy, low-level world of C." -SECTION = "devel/python" -LICENSE = "Apache-2.0" -LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=e23fadd6ceef8c618fc1c65191d846fa" -PYPI_PACKAGE = "Cython" -BBCLASSEXTEND = "native nativesdk" - -SRC_URI[md5sum] = "a899abaa48b68bb679aef45ceb4b89d3" -SRC_URI[sha256sum] = "232755284f942cbb3b43a06cd85974ef3c970a021aef19b5243c03ee2b08fa05" -UPSTREAM_CHECK_REGEX = "Cython-(?P<pver>.*)\.tar" - -inherit pypi - -RDEPENDS_${PN}_class-target += "\ - ${PYTHON_PN}-misc \ - ${PYTHON_PN}-netserver \ - ${PYTHON_PN}-pkgutil \ - ${PYTHON_PN}-pyparsing \ - ${PYTHON_PN}-setuptools \ - ${PYTHON_PN}-shell \ - ${PYTHON_PN}-xml \ -" - -RDEPENDS_${PN}_class-nativesdk += "\ - nativesdk-${PYTHON_PN}-misc \ - nativesdk-${PYTHON_PN}-netserver \ - nativesdk-${PYTHON_PN}-pkgutil \ - nativesdk-${PYTHON_PN}-pyparsing \ - nativesdk-${PYTHON_PN}-setuptools \ - nativesdk-${PYTHON_PN}-shell \ - nativesdk-${PYTHON_PN}-xml \ -" - -do_install_append() { - # Make sure we use /usr/bin/env python - for PYTHSCRIPT in `grep -rIl '^#!.*python' ${D}`; do - sed -i -e '1s|^#!.*|#!/usr/bin/env ${PYTHON_PN}|' $PYTHSCRIPT - done -} diff --git a/poky/meta/recipes-devtools/python/python-gitdb.inc b/poky/meta/recipes-devtools/python/python-gitdb.inc index a91bb32c3b..23ec2986b1 100644 --- a/poky/meta/recipes-devtools/python/python-gitdb.inc +++ b/poky/meta/recipes-devtools/python/python-gitdb.inc @@ -6,9 +6,10 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=59e5ecb13339a936eedf83282eaf4528" inherit pypi -PYPI_PACKAGE = "gitdb" +PYPI_PACKAGE = "gitdb2" -SRC_URI[sha256sum] = "6f0ecd46f99bb4874e5678d628c3a198e2b4ef38daea2756a2bfd8df7dd5c1a5" +SRC_URI[md5sum] = "1a7ea3362e405f8a5634f7ee53636094" +SRC_URI[sha256sum] = "1b6df1433567a51a4a9c1a5a0de977aa351a405cc56d7d35f3388bad1f630350" DEPENDS = "${PYTHON_PN}-async ${PYTHON_PN}-setuptools-native ${PYTHON_PN}-smmap" diff --git a/poky/meta/recipes-devtools/python/python-pbr.inc b/poky/meta/recipes-devtools/python/python-pbr.inc index ce3c224d51..0e64501c32 100644 --- a/poky/meta/recipes-devtools/python/python-pbr.inc +++ b/poky/meta/recipes-devtools/python/python-pbr.inc @@ -5,8 +5,6 @@ SECTION = "devel/python" LICENSE = "Apache-2.0" LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2" -SRC_URI += "file://0001-change-shebang-to-python3.patch" - inherit pypi RDEPENDS_${PN} += "${PYTHON_PN}-pip" diff --git a/poky/meta/recipes-devtools/python/python-pyparsing.inc b/poky/meta/recipes-devtools/python/python-pyparsing.inc deleted file mode 100644 index 348b324bf5..0000000000 --- a/poky/meta/recipes-devtools/python/python-pyparsing.inc +++ /dev/null @@ -1,22 +0,0 @@ -SUMMARY = "Python parsing module" -HOMEPAGE = "http://pyparsing.wikispaces.com/" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://LICENSE;md5=657a566233888513e1f07ba13e2f47f1" - -SRC_URI[md5sum] = "f0953e47a0112f7a65aec2305ffdf7b4" -SRC_URI[sha256sum] = "c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1" -UPSTREAM_CHECK_REGEX = "pyparsing-(?P<pver>.*)\.tar" - -inherit pypi - -RDEPENDS_${PN} += " \ - ${PYTHON_PN}-datetime \ - ${PYTHON_PN}-debugger \ - ${PYTHON_PN}-json \ - ${PYTHON_PN}-netclient \ - ${PYTHON_PN}-pprint \ - ${PYTHON_PN}-stringold \ - ${PYTHON_PN}-threading \ -" - -BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python-setuptools.inc b/poky/meta/recipes-devtools/python/python-setuptools.inc index 07c2f8b216..58267966ba 100644 --- a/poky/meta/recipes-devtools/python/python-setuptools.inc +++ b/poky/meta/recipes-devtools/python/python-setuptools.inc @@ -10,8 +10,6 @@ inherit pypi 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" - SRC_URI[md5sum] = "0c956eea142af9c2b02d72e3c042af30" SRC_URI[sha256sum] = "89c6e6011ec2f6d57d43a3f9296c4ef022c2cbf49bab26b407fe67992ae3397f" @@ -24,6 +22,7 @@ RDEPENDS_${PN} = "\ ${PYTHON_PN}-distutils \ ${PYTHON_PN}-email \ ${PYTHON_PN}-html \ + ${PYTHON_PN}-json \ ${PYTHON_PN}-netserver \ ${PYTHON_PN}-numbers \ ${PYTHON_PN}-pkgutil \ diff --git a/poky/meta/recipes-devtools/python/python3-cython_0.29.16.bb b/poky/meta/recipes-devtools/python/python3-cython_0.29.16.bb deleted file mode 100644 index 2ce6bdbd68..0000000000 --- a/poky/meta/recipes-devtools/python/python3-cython_0.29.16.bb +++ /dev/null @@ -1,18 +0,0 @@ -inherit setuptools3 -require python-cython.inc - -RDEPENDS_${PN} += "\ - python3-setuptools \ -" - -# running build_ext a second time during install fails, because Python -# would then attempt to import cythonized modules built for the target -# architecture. -DISTUTILS_INSTALL_ARGS += "--skip-build" - -do_install_append() { - # rename scripts that would conflict with the Python 2 build of Cython - mv ${D}${bindir}/cython ${D}${bindir}/cython3 - mv ${D}${bindir}/cythonize ${D}${bindir}/cythonize3 - mv ${D}${bindir}/cygdb ${D}${bindir}/cygdb3 -} diff --git a/poky/meta/recipes-devtools/python/python3-dbusmock_0.19.bb b/poky/meta/recipes-devtools/python/python3-dbusmock_0.19.bb deleted file mode 100644 index 5389e48973..0000000000 --- a/poky/meta/recipes-devtools/python/python3-dbusmock_0.19.bb +++ /dev/null @@ -1,16 +0,0 @@ -SUMMARY = "With this program/Python library you can easily create mock objects on D-Bus" - -LICENSE = "GPL-3.0" -LIC_FILES_CHKSUM = "file://COPYING;md5=e6a600fd5e1d9cbde2d983680233ad02" - -SRC_URI[sha256sum] = "497f30eed2fcd5deaa2633b9622e4e99af4bdfba4e972b350ba630bac6fc86c2" - -PYPI_PACKAGE = "python-dbusmock" - -inherit pypi setuptools3 - -RDEPENDS_${PN} += "\ - ${PYTHON_PN}-dbus \ - ${PYTHON_PN}-pygobject \ - ${PYTHON_PN}-xml \ - " diff --git a/poky/meta/recipes-devtools/python/python3-gitdb_4.0.4.bb b/poky/meta/recipes-devtools/python/python3-gitdb_2.0.6.bb index 2dcd9c8aff..2dcd9c8aff 100644 --- a/poky/meta/recipes-devtools/python/python3-gitdb_4.0.4.bb +++ b/poky/meta/recipes-devtools/python/python3-gitdb_2.0.6.bb diff --git a/poky/meta/recipes-devtools/python/python3-pbr/0001-change-shebang-to-python3.patch b/poky/meta/recipes-devtools/python/python3-pbr/0001-change-shebang-to-python3.patch deleted file mode 100644 index 688da6b204..0000000000 --- a/poky/meta/recipes-devtools/python/python3-pbr/0001-change-shebang-to-python3.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 09bd8368bf0d5385663a10eeb890131481681bdd Mon Sep 17 00:00:00 2001 -From: Changqing Li <changqing.li@windriver.com> -Date: Thu, 23 Apr 2020 09:28:58 +0000 -Subject: [PATCH] change shebang to python3 - -Upstream-Status: Pending - -Signed-off-by: Changqing Li <changqing.li@windriver.com> ---- - pbr/tests/test_integration.py | 2 +- - pbr/tests/test_packaging.py | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/pbr/tests/test_integration.py b/pbr/tests/test_integration.py -index 8e96f21..b07cbe3 100644 ---- a/pbr/tests/test_integration.py -+++ b/pbr/tests/test_integration.py -@@ -150,7 +150,7 @@ class TestInstallWithoutPbr(base.BaseTestCase): - pkgs = { - 'pkgTest': { - 'setup.py': textwrap.dedent("""\ -- #!/usr/bin/env python -+ #!/usr/bin/env python3 - import setuptools - setuptools.setup( - name = 'pkgTest', -diff --git a/pbr/tests/test_packaging.py b/pbr/tests/test_packaging.py -index 07be547..f6a9412 100644 ---- a/pbr/tests/test_packaging.py -+++ b/pbr/tests/test_packaging.py -@@ -206,7 +206,7 @@ class CreatePackages(fixtures.Fixture): - - defaults = { - 'setup.py': textwrap.dedent(six.u("""\ -- #!/usr/bin/env python -+ #!/usr/bin/env python3 - import setuptools - setuptools.setup( - setup_requires=['pbr'], --- -2.24.1 - diff --git a/poky/meta/recipes-devtools/python/python3-pip/0001-change-shebang-to-python3.patch b/poky/meta/recipes-devtools/python/python3-pip/0001-change-shebang-to-python3.patch deleted file mode 100644 index 00cffe169b..0000000000 --- a/poky/meta/recipes-devtools/python/python3-pip/0001-change-shebang-to-python3.patch +++ /dev/null @@ -1,60 +0,0 @@ -From e7a00e9b5104ae2fbcea32a35c85760b77fae7e5 Mon Sep 17 00:00:00 2001 -From: Changqing Li <changqing.li@windriver.com> -Date: Thu, 23 Apr 2020 09:42:10 +0000 -Subject: [PATCH] change shebang to python3 - -Upstream-Status: Pending - -pip will drop support of python2 from 21.0 - -Signed-off-by: Changqing Li <changqing.li@windriver.com> ---- - src/pip/_internal/__init__.py | 2 +- - src/pip/_vendor/appdirs.py | 2 +- - src/pip/_vendor/chardet/cli/chardetect.py | 2 +- - src/pip/_vendor/requests/certs.py | 2 +- - 4 files changed, 4 insertions(+), 4 deletions(-) - -diff --git a/src/pip/_internal/__init__.py b/src/pip/_internal/__init__.py -index 3aa8a46..e1ad179 100755 ---- a/src/pip/_internal/__init__.py -+++ b/src/pip/_internal/__init__.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python -+#!/usr/bin/env python3 - import pip._internal.utils.inject_securetransport # noqa - from pip._internal.utils.typing import MYPY_CHECK_RUNNING - -diff --git a/src/pip/_vendor/appdirs.py b/src/pip/_vendor/appdirs.py -index 3a52b75..ad3f81d 100644 ---- a/src/pip/_vendor/appdirs.py -+++ b/src/pip/_vendor/appdirs.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python -+#!/usr/bin/env python3 - # -*- coding: utf-8 -*- - # Copyright (c) 2005-2010 ActiveState Software Inc. - # Copyright (c) 2013 Eddy Petrișor -diff --git a/src/pip/_vendor/chardet/cli/chardetect.py b/src/pip/_vendor/chardet/cli/chardetect.py -index c61136b..a497e98 100644 ---- a/src/pip/_vendor/chardet/cli/chardetect.py -+++ b/src/pip/_vendor/chardet/cli/chardetect.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python -+#!/usr/bin/env python3 - """ - Script which takes one or more file paths and reports on their detected - encodings -diff --git a/src/pip/_vendor/requests/certs.py b/src/pip/_vendor/requests/certs.py -index 06a594e..bfa7839 100644 ---- a/src/pip/_vendor/requests/certs.py -+++ b/src/pip/_vendor/requests/certs.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python -+#!/usr/bin/env python3 - # -*- coding: utf-8 -*- - - """ --- -2.24.1 - diff --git a/poky/meta/recipes-devtools/python/python3-pip_20.0.2.bb b/poky/meta/recipes-devtools/python/python3-pip_20.0.2.bb index 96973db774..08738fb2f9 100644 --- a/poky/meta/recipes-devtools/python/python3-pip_20.0.2.bb +++ b/poky/meta/recipes-devtools/python/python3-pip_20.0.2.bb @@ -6,8 +6,6 @@ LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=8ba06d529c955048e5ddd7c45459eb2e" DEPENDS += "python3 python3-setuptools-native" -SRC_URI += "file://0001-change-shebang-to-python3.patch" - SRC_URI[md5sum] = "7d42ba49b809604f0df3d55df1c3fd86" SRC_URI[sha256sum] = "7db0c8ea4c7ea51c8049640e8e6e7fde949de672bfa4949920675563a5a6967f" diff --git a/poky/meta/recipes-devtools/python/python3-pyparsing_2.4.7.bb b/poky/meta/recipes-devtools/python/python3-pyparsing_2.4.7.bb deleted file mode 100644 index d0c3d0b424..0000000000 --- a/poky/meta/recipes-devtools/python/python3-pyparsing_2.4.7.bb +++ /dev/null @@ -1,3 +0,0 @@ -inherit setuptools3 -require python-pyparsing.inc - diff --git a/poky/meta/recipes-devtools/python/python3-setuptools/0001-change-shebang-to-python3.patch b/poky/meta/recipes-devtools/python/python3-setuptools/0001-change-shebang-to-python3.patch deleted file mode 100644 index 33af8daed7..0000000000 --- a/poky/meta/recipes-devtools/python/python3-setuptools/0001-change-shebang-to-python3.patch +++ /dev/null @@ -1,36 +0,0 @@ -From c39d0896930e25c224cc897660fc8511ccae30c8 Mon Sep 17 00:00:00 2001 -From: Changqing Li <changqing.li@windriver.com> -Date: Thu, 23 Apr 2020 10:01:12 +0000 -Subject: [PATCH] change shebang to python3 - -Upstream-Status: Pending - -Signed-off-by: Changqing Li <changqing.li@windriver.com> ---- - pkg_resources/_vendor/appdirs.py | 2 +- - setuptools/command/easy_install.py | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/pkg_resources/_vendor/appdirs.py b/pkg_resources/_vendor/appdirs.py -index ae67001..933e398 100644 ---- a/pkg_resources/_vendor/appdirs.py -+++ b/pkg_resources/_vendor/appdirs.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python -+#!/usr/bin/env python3 - # -*- coding: utf-8 -*- - # Copyright (c) 2005-2010 ActiveState Software Inc. - # Copyright (c) 2013 Eddy Petrișor -diff --git a/setuptools/command/easy_install.py b/setuptools/command/easy_install.py -index abca1ae..6bcdc98 100644 ---- a/setuptools/command/easy_install.py -+++ b/setuptools/command/easy_install.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python -+#!/usr/bin/env python3 - """ - Easy Install - ------------ --- -2.24.1 - diff --git a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch index 4029233fb7..80e2f0fad7 100644 --- a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch +++ b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch @@ -1,4 +1,4 @@ -From f39c28eb52f12ae6e82db360ffd5a903ac8faca5 Mon Sep 17 00:00:00 2001 +From 87cfc0db1ed6fe381a5ed5f0016d8c3344a31a11 Mon Sep 17 00:00:00 2001 From: Alexander Kanavin <alex.kanavin@gmail.com> Date: Mon, 9 Jan 2017 18:52:11 +0200 Subject: [PATCH] Do not add an unsatisfiable dependency when building rpms in @@ -9,23 +9,25 @@ hand produces rpms that way by design. Upstream-Status: Inappropriate [oe-core specific] Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> - --- build/pack.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/build/pack.c b/build/pack.c -index e6cec1816..810cd7351 100644 +index 1261cdbba..bb2d6f4f6 100644 --- a/build/pack.c +++ b/build/pack.c -@@ -724,10 +724,6 @@ static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int ch - headerPutBin(pkg->header, RPMTAG_SOURCEPKGID, spec->sourcePkgId,16); - } - -- if (cheating) { -- (void) rpmlibNeedsFeature(pkg, "ShortCircuited", "4.9.0-1"); -- } -- - if ((rc = getPkgFilename(pkg->header, filename))) - return rc; +@@ -595,10 +595,6 @@ rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) + headerPutBin(pkg->header, RPMTAG_SOURCEPKGID, spec->sourcePkgId,16); + } +- if (cheating) { +- (void) rpmlibNeedsFeature(pkg, "ShortCircuited", "4.9.0-1"); +- } +- + { char *binFormat = rpmGetPath("%{_rpmfilename}", NULL); + char *binRpm, *binDir; + binRpm = headerFormat(pkg->header, binFormat, &errorString); +-- +2.11.0 + diff --git a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch index 52440d6818..82e7328757 100644 --- a/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch +++ b/poky/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch @@ -1,4 +1,4 @@ -From 2f3d1619b6510bc131c4375827caf912559f0fa2 Mon Sep 17 00:00:00 2001 +From bd08eb0ae1312f347f49949481daa7c923752df2 Mon Sep 17 00:00:00 2001 From: Alexander Kanavin <alex.kanavin@gmail.com> Date: Mon, 27 Feb 2017 09:43:30 +0200 Subject: [PATCH] Do not hardcode "lib/rpm" as the installation path for @@ -14,10 +14,10 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/configure.ac b/configure.ac -index d3aeab86e..1a1f3f91f 100644 +index 09af7c4..9bd6903 100644 --- a/configure.ac +++ b/configure.ac -@@ -1086,7 +1086,7 @@ else +@@ -1055,7 +1055,7 @@ else usrprefix=$prefix fi @@ -27,10 +27,10 @@ index d3aeab86e..1a1f3f91f 100644 AC_SUBST(OBJDUMP) diff --git a/macros.in b/macros.in -index fe9803aad..d128675bf 100644 +index a3aa7a9..62cee5c 100644 --- a/macros.in +++ b/macros.in -@@ -985,7 +985,7 @@ package or when debugging this package.\ +@@ -970,7 +970,7 @@ package or when debugging this package.\ %_sharedstatedir %{_prefix}/com %_localstatedir %{_prefix}/var %_lib lib @@ -40,7 +40,7 @@ index fe9803aad..d128675bf 100644 %_infodir %{_datadir}/info %_mandir %{_datadir}/man diff --git a/rpm.am b/rpm.am -index 40b4ec55f..3139ce8f6 100644 +index 82c2d7c..6341b51 100644 --- a/rpm.am +++ b/rpm.am @@ -1,10 +1,10 @@ @@ -55,4 +55,4 @@ index 40b4ec55f..3139ce8f6 100644 +rpmconfigdir = $(libdir)/rpm # Libtool version (current-revision-age) for all our libraries - rpm_version_info = 9:1:0 + rpm_version_info = 9:0:1 diff --git a/poky/meta/recipes-devtools/rpm/files/0001-Split-binary-package-building-into-a-separate-functi.patch b/poky/meta/recipes-devtools/rpm/files/0001-Split-binary-package-building-into-a-separate-functi.patch new file mode 100644 index 0000000000..6e44f0b7fc --- /dev/null +++ b/poky/meta/recipes-devtools/rpm/files/0001-Split-binary-package-building-into-a-separate-functi.patch @@ -0,0 +1,84 @@ +From 721a660a507d6d062e7aecafad886c643970a5d5 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Thu, 25 May 2017 18:15:27 +0300 +Subject: [PATCH 1/4] Split binary package building into a separate function + +So that it can be run as a thread pool task. + +Upstream-Status: Submitted [https://github.com/rpm-software-management/rpm/pull/226] +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> + +--- + build/pack.c | 33 +++++++++++++++++++++------------ + 1 file changed, 21 insertions(+), 12 deletions(-) + +diff --git a/build/pack.c b/build/pack.c +index 518f4e92a..ccfd614cc 100644 +--- a/build/pack.c ++++ b/build/pack.c +@@ -546,18 +546,13 @@ static rpmRC checkPackages(char *pkgcheck) + return RPMRC_OK; + } + +-rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) ++static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int cheating, char** filename) + { +- rpmRC rc; +- const char *errorString; +- Package pkg; +- char *pkglist = NULL; +- +- for (pkg = spec->packages; pkg != NULL; pkg = pkg->next) { +- char *fn; ++ const char *errorString; ++ rpmRC rc = RPMRC_OK; + + if (pkg->fileList == NULL) +- continue; ++ return rc; + + if ((rc = processScriptFiles(spec, pkg))) + return rc; +@@ -587,7 +582,7 @@ rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) + headerGetString(pkg->header, RPMTAG_NAME), errorString); + return RPMRC_FAIL; + } +- fn = rpmGetPath("%{_rpmdir}/", binRpm, NULL); ++ *filename = rpmGetPath("%{_rpmdir}/", binRpm, NULL); + if ((binDir = strchr(binRpm, '/')) != NULL) { + struct stat st; + char *dn; +@@ -609,14 +604,28 @@ rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) + free(binRpm); + } + +- rc = writeRPM(pkg, NULL, fn, NULL); ++ rc = writeRPM(pkg, NULL, *filename, NULL); + if (rc == RPMRC_OK) { + /* Do check each written package if enabled */ +- char *pkgcheck = rpmExpand("%{?_build_pkgcheck} ", fn, NULL); ++ char *pkgcheck = rpmExpand("%{?_build_pkgcheck} ", *filename, NULL); + if (pkgcheck[0] != ' ') { + rc = checkPackages(pkgcheck); + } + free(pkgcheck); ++ } ++ return rc; ++} ++ ++rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) ++{ ++ rpmRC rc; ++ Package pkg; ++ char *pkglist = NULL; ++ ++ for (pkg = spec->packages; pkg != NULL; pkg = pkg->next) { ++ char *fn = NULL; ++ rc = packageBinary(spec, pkg, cookie, cheating, &fn); ++ if (rc == RPMRC_OK) { + rstrcat(&pkglist, fn); + rstrcat(&pkglist, " "); + } +-- +2.11.0 + diff --git a/poky/meta/recipes-devtools/rpm/files/0001-mono-find-provides-requires-do-not-use-monodis-from-.patch b/poky/meta/recipes-devtools/rpm/files/0001-mono-find-provides-requires-do-not-use-monodis-from-.patch new file mode 100644 index 0000000000..24aa4c7fff --- /dev/null +++ b/poky/meta/recipes-devtools/rpm/files/0001-mono-find-provides-requires-do-not-use-monodis-from-.patch @@ -0,0 +1,58 @@ +From 43fbc3f53302a395463e8450ac81c53f623eec3f Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Tue, 27 Aug 2019 17:42:34 +0200 +Subject: [PATCH] mono-find-provides/requires: do not use monodis from the host + +There was a host contamination issue here: if monodis was installed +on the host, do_package would use that to resolve dependencies +of mono libraries (and often fail in that). Without monodis, +no dependencies are resolved, which is seemingly how things +are supposed to work. + +Upstream-Status: Inappropriate [oe-core specific] +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> +--- + scripts/mono-find-provides | 8 ++++---- + scripts/mono-find-requires | 8 ++++---- + 2 files changed, 8 insertions(+), 8 deletions(-) + +diff --git a/scripts/mono-find-provides b/scripts/mono-find-provides +index 9348457d3..b28872ffb 100644 +--- a/scripts/mono-find-provides ++++ b/scripts/mono-find-provides +@@ -18,11 +18,11 @@ monolist=($(printf "%s\n" "${filelist[@]}" | grep -E "\\.(exe|dll)\$")) + build_bindir="$2/usr/bin" + build_libdir="$2$3" + +-if [ -x $build_bindir/monodis ]; then +- monodis="$build_bindir/monodis" ++if [ -x $build_bindir/monodis.bogus ]; then ++ monodis="$build_bindir/monodis.bogus" + export LD_LIBRARY_PATH=$build_libdir${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH} +-elif [ -x /usr/bin/monodis ]; then +- monodis="/usr/bin/monodis" ++elif [ -x /usr/bin/monodis.bogus ]; then ++ monodis="/usr/bin/monodis.bogus" + else + exit 0; + fi +diff --git a/scripts/mono-find-requires b/scripts/mono-find-requires +index ea58cae48..d270169e1 100644 +--- a/scripts/mono-find-requires ++++ b/scripts/mono-find-requires +@@ -18,11 +18,11 @@ monolist=($(printf "%s\n" "${filelist[@]}" | grep -E "\\.(exe|dll)\$")) + build_bindir="$2/usr/bin" + build_libdir="$2$3" + +-if [ -x $build_bindir/monodis ]; then +- monodis="$build_bindir/monodis" ++if [ -x $build_bindir/monodis.bogus ]; then ++ monodis="$build_bindir/monodis.bogus" + export LD_LIBRARY_PATH=$build_libdir${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH} +-elif [ -x /usr/bin/monodis ]; then +- monodis="/usr/bin/monodis" ++elif [ -x /usr/bin/monodis.bogus ]; then ++ monodis="/usr/bin/monodis.bogus" + else + exit 0; + fi diff --git a/poky/meta/recipes-devtools/rpm/files/0001-rpmfc.c-do-not-run-file-classification-in-parallel.patch b/poky/meta/recipes-devtools/rpm/files/0001-rpmfc.c-do-not-run-file-classification-in-parallel.patch deleted file mode 100644 index d8d338792d..0000000000 --- a/poky/meta/recipes-devtools/rpm/files/0001-rpmfc.c-do-not-run-file-classification-in-parallel.patch +++ /dev/null @@ -1,65 +0,0 @@ -From 93c3c7f043f62e96941274e957c4ad9432032af1 Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin <alex.kanavin@gmail.com> -Date: Mon, 18 Nov 2019 16:22:56 +0100 -Subject: [PATCH] rpmfc.c: do not run file classification in parallel - -This is causing freezes with libmagic when the file in question is compressed: -https://github.com/rpm-software-management/rpm/issues/756 - -Upstream-Status: Inappropriate [upstream wants a proper fix] -Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> ---- - build/rpmfc.c | 8 -------- - 1 file changed, 8 deletions(-) - -diff --git a/build/rpmfc.c b/build/rpmfc.c -index 3db7a9352..17afdd57a 100644 ---- a/build/rpmfc.c -+++ b/build/rpmfc.c -@@ -680,7 +680,6 @@ static void rpmfcAttributes(rpmfc fc, int ix, const char *ftype, const char *ful - /* Add attributes on libmagic type & path pattern matches */ - if (matches(&(*attr)->incl, ftype, path, is_executable)) { - argvAddTokens(&fc->fattrs[ix], (*attr)->name); -- #pragma omp critical(fahash) - fattrHashAddEntry(fc->fahash, attr-fc->atypes, ix); - } - } -@@ -1105,7 +1104,6 @@ rpmRC rpmfcClassify(rpmfc fc, ARGV_t argv, rpm_mode_t * fmode) - /* Build (sorted) file class dictionary. */ - fc->cdict = rpmstrPoolCreate(); - -- #pragma omp parallel - { - /* libmagic is not thread-safe, each thread needs to a private handle */ - magic_t ms = magic_open(msflags); -@@ -1113,15 +1111,12 @@ rpmRC rpmfcClassify(rpmfc fc, ARGV_t argv, rpm_mode_t * fmode) - if (ms == NULL) { - rpmlog(RPMLOG_ERR, _("magic_open(0x%x) failed: %s\n"), - msflags, strerror(errno)); -- #pragma omp cancel parallel - } - - if (magic_load(ms, NULL) == -1) { - rpmlog(RPMLOG_ERR, _("magic_load failed: %s\n"), magic_error(ms)); -- #pragma omp cancel parallel - } - -- #pragma omp for ordered reduction(+:nerrors) - for (int ix = 0; ix < fc->nfiles; ix++) { - rpmsid ftypeId; - const char * ftype; -@@ -1185,14 +1180,11 @@ rpmRC rpmfcClassify(rpmfc fc, ARGV_t argv, rpm_mode_t * fmode) - fc->fcolor[ix] = fcolor; - - /* Add to file class dictionary and index array */ -- #pragma omp ordered - if (fcolor != RPMFC_WHITE && (fcolor & RPMFC_INCLUDE)) { - ftypeId = rpmstrPoolId(fc->cdict, ftype, 1); -- #pragma omp atomic - fc->fknown++; - } else { - ftypeId = rpmstrPoolId(fc->cdict, "", 1); -- #pragma omp atomic - fc->fwhite++; - } - /* Pool id's start from 1, for headers we want it from 0 */ diff --git a/poky/meta/recipes-devtools/rpm/files/0002-Run-binary-package-creation-via-thread-pools.patch b/poky/meta/recipes-devtools/rpm/files/0002-Run-binary-package-creation-via-thread-pools.patch new file mode 100644 index 0000000000..d10041c2e1 --- /dev/null +++ b/poky/meta/recipes-devtools/rpm/files/0002-Run-binary-package-creation-via-thread-pools.patch @@ -0,0 +1,127 @@ +From 513200cf76758de4668312c628d6362bdabfaf4b Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Thu, 25 May 2017 19:30:20 +0300 +Subject: [PATCH 1/3] Run binary package creation via thread pools. + +Upstream-Status: Submitted [https://github.com/rpm-software-management/rpm/pull/226] +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> + +--- + build/pack.c | 81 +++++++++++++++++++++++++++++++++++++++++++++++++----------- + configure.ac | 3 +++ + 2 files changed, 70 insertions(+), 14 deletions(-) + +diff --git a/build/pack.c b/build/pack.c +index ccfd614cc..ed5b9ab4e 100644 +--- a/build/pack.c ++++ b/build/pack.c +@@ -616,25 +616,78 @@ static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int ch + return rc; + } + +-rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) ++struct binaryPackageTaskData + { +- rpmRC rc; + Package pkg; ++ char *filename; ++ rpmRC result; ++ struct binaryPackageTaskData *next; ++}; ++ ++static struct binaryPackageTaskData* runBinaryPackageTasks(rpmSpec spec, const char *cookie, int cheating) ++{ ++ struct binaryPackageTaskData *tasks = NULL; ++ struct binaryPackageTaskData *task = NULL; ++ struct binaryPackageTaskData *prev = NULL; ++ ++ for (Package pkg = spec->packages; pkg != NULL; pkg = pkg->next) { ++ task = rcalloc(1, sizeof(*task)); ++ task->pkg = pkg; ++ if (pkg == spec->packages) { ++ // the first package needs to be processed ahead of others, as they copy ++ // changelog data from it, and so otherwise data races would happen ++ task->result = packageBinary(spec, pkg, cookie, cheating, &(task->filename)); ++ rpmlog(RPMLOG_NOTICE, _("Finished binary package job, result %d, filename %s\n"), task->result, task->filename); ++ tasks = task; ++ } ++ if (prev != NULL) { ++ prev->next = task; ++ } ++ prev = task; ++ } ++ ++ #pragma omp parallel ++ #pragma omp single ++ // re-declaring task variable is necessary, or older gcc versions will produce code that segfaults ++ for (struct binaryPackageTaskData *task = tasks; task != NULL; task = task->next) { ++ if (task != tasks) ++ #pragma omp task ++ { ++ task->result = packageBinary(spec, task->pkg, cookie, cheating, &(task->filename)); ++ rpmlog(RPMLOG_NOTICE, _("Finished binary package job, result %d, filename %s\n"), task->result, task->filename); ++ } ++ } ++ ++ return tasks; ++} ++ ++static void freeBinaryPackageTasks(struct binaryPackageTaskData* tasks) ++{ ++ while (tasks != NULL) { ++ struct binaryPackageTaskData* next = tasks->next; ++ rfree(tasks->filename); ++ rfree(tasks); ++ tasks = next; ++ } ++} ++ ++rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) ++{ + char *pkglist = NULL; + +- for (pkg = spec->packages; pkg != NULL; pkg = pkg->next) { +- char *fn = NULL; +- rc = packageBinary(spec, pkg, cookie, cheating, &fn); +- if (rc == RPMRC_OK) { +- rstrcat(&pkglist, fn); +- rstrcat(&pkglist, " "); +- } +- free(fn); +- if (rc != RPMRC_OK) { +- pkglist = _free(pkglist); +- return rc; +- } ++ struct binaryPackageTaskData *tasks = runBinaryPackageTasks(spec, cookie, cheating); ++ ++ for (struct binaryPackageTaskData *task = tasks; task != NULL; task = task->next) { ++ if (task->result == RPMRC_OK) { ++ rstrcat(&pkglist, task->filename); ++ rstrcat(&pkglist, " "); ++ } else { ++ _free(pkglist); ++ freeBinaryPackageTasks(tasks); ++ return RPMRC_FAIL; ++ } + } ++ freeBinaryPackageTasks(tasks); + + /* Now check the package set if enabled */ + if (pkglist != NULL) { +diff --git a/configure.ac b/configure.ac +index a506ec819..59fa0acaf 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -17,6 +17,9 @@ AC_DISABLE_STATIC + + PKG_PROG_PKG_CONFIG + ++AC_OPENMP ++RPMCFLAGS="$OPENMP_CFLAGS $RPMCFLAGS" ++ + dnl Checks for programs. + AC_PROG_CXX + AC_PROG_AWK +-- +2.11.0 + diff --git a/poky/meta/recipes-devtools/rpm/files/0003-rpmstrpool.c-make-operations-over-string-pools-threa.patch b/poky/meta/recipes-devtools/rpm/files/0003-rpmstrpool.c-make-operations-over-string-pools-threa.patch new file mode 100644 index 0000000000..c348ae5330 --- /dev/null +++ b/poky/meta/recipes-devtools/rpm/files/0003-rpmstrpool.c-make-operations-over-string-pools-threa.patch @@ -0,0 +1,207 @@ +From c80892f17e44331206c8318d53b63bb6a99554d0 Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Tue, 30 May 2017 13:58:30 +0300 +Subject: [PATCH 3/4] rpmstrpool.c: make operations over string pools + thread-safe + +Otherwise multithreaded rpm building explodes in various ways due +to data races. + +Upstream-Status: Submitted [https://github.com/rpm-software-management/rpm/pull/226] +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> + +--- + rpmio/rpmstrpool.c | 56 +++++++++++++++++++++++++++++++++++++++++++++--------- + 1 file changed, 47 insertions(+), 9 deletions(-) + +diff --git a/rpmio/rpmstrpool.c b/rpmio/rpmstrpool.c +index 30a57eb10..58ba95a02 100644 +--- a/rpmio/rpmstrpool.c ++++ b/rpmio/rpmstrpool.c +@@ -113,6 +113,8 @@ static poolHash poolHashCreate(int numBuckets) + return ht; + } + ++static const char * rpmstrPoolStrNoLock(rpmstrPool pool, rpmsid sid); ++ + static void poolHashResize(rpmstrPool pool, int numBuckets) + { + poolHash ht = pool->hash; +@@ -120,7 +122,7 @@ static void poolHashResize(rpmstrPool pool, int numBuckets) + + for (int i=0; i<ht->numBuckets; i++) { + if (!ht->buckets[i].keyid) continue; +- unsigned int keyHash = rstrhash(rpmstrPoolStr(pool, ht->buckets[i].keyid)); ++ unsigned int keyHash = rstrhash(rpmstrPoolStrNoLock(pool, ht->buckets[i].keyid)); + for (unsigned int j=0;;j++) { + unsigned int hash = hashbucket(keyHash, j) % numBuckets; + if (!buckets[hash].keyid) { +@@ -149,7 +151,7 @@ static void poolHashAddHEntry(rpmstrPool pool, const char * key, unsigned int ke + ht->buckets[hash].keyid = keyid; + ht->keyCount++; + break; +- } else if (!strcmp(rpmstrPoolStr(pool, ht->buckets[hash].keyid), key)) { ++ } else if (!strcmp(rpmstrPoolStrNoLock(pool, ht->buckets[hash].keyid), key)) { + return; + } + } +@@ -191,7 +193,7 @@ static void poolHashPrintStats(rpmstrPool pool) + int maxcollisions = 0; + + for (i=0; i<ht->numBuckets; i++) { +- unsigned int keyHash = rstrhash(rpmstrPoolStr(pool, ht->buckets[i].keyid)); ++ unsigned int keyHash = rstrhash(rpmstrPoolStrNoLock(pool, ht->buckets[i].keyid)); + for (unsigned int j=0;;j++) { + unsigned int hash = hashbucket(keyHash, i) % ht->numBuckets; + if (hash==i) { +@@ -221,7 +223,7 @@ static void rpmstrPoolRehash(rpmstrPool pool) + + pool->hash = poolHashCreate(sizehint); + for (int i = 1; i <= pool->offs_size; i++) +- poolHashAddEntry(pool, rpmstrPoolStr(pool, i), i); ++ poolHashAddEntry(pool, rpmstrPoolStrNoLock(pool, i), i); + } + + rpmstrPool rpmstrPoolCreate(void) +@@ -245,6 +247,8 @@ rpmstrPool rpmstrPoolCreate(void) + + rpmstrPool rpmstrPoolFree(rpmstrPool pool) + { ++ #pragma omp critical(rpmstrpool) ++ { + if (pool) { + if (pool->nrefs > 1) { + pool->nrefs--; +@@ -260,18 +264,24 @@ rpmstrPool rpmstrPoolFree(rpmstrPool pool) + free(pool); + } + } ++ } + return NULL; + } + + rpmstrPool rpmstrPoolLink(rpmstrPool pool) + { ++ #pragma omp critical(rpmstrpool) ++ { + if (pool) + pool->nrefs++; ++ } + return pool; + } + + void rpmstrPoolFreeze(rpmstrPool pool, int keephash) + { ++ #pragma omp critical(rpmstrpool) ++ { + if (pool && !pool->frozen) { + if (!keephash) { + pool->hash = poolHashFree(pool->hash); +@@ -281,16 +291,20 @@ void rpmstrPoolFreeze(rpmstrPool pool, int keephash) + pool->offs_alloced * sizeof(*pool->offs)); + pool->frozen = 1; + } ++ } + } + + void rpmstrPoolUnfreeze(rpmstrPool pool) + { ++ #pragma omp critical(rpmstrpool) ++ { + if (pool) { + if (pool->hash == NULL) { + rpmstrPoolRehash(pool); + } + pool->frozen = 0; + } ++ } + } + + static rpmsid rpmstrPoolPut(rpmstrPool pool, const char *s, size_t slen, unsigned int hash) +@@ -350,7 +364,7 @@ static rpmsid rpmstrPoolGet(rpmstrPool pool, const char * key, size_t keylen, + return 0; + } + +- s = rpmstrPoolStr(pool, ht->buckets[hash].keyid); ++ s = rpmstrPoolStrNoLock(pool, ht->buckets[hash].keyid); + /* pool string could be longer than keylen, require exact matche */ + if (strncmp(s, key, keylen) == 0 && s[keylen] == '\0') + return ht->buckets[hash].keyid; +@@ -373,27 +387,31 @@ static inline rpmsid strn2id(rpmstrPool pool, const char *s, size_t slen, + rpmsid rpmstrPoolIdn(rpmstrPool pool, const char *s, size_t slen, int create) + { + rpmsid sid = 0; +- ++ #pragma omp critical(rpmstrpool) ++ { + if (s != NULL) { + unsigned int hash = rstrnhash(s, slen); + sid = strn2id(pool, s, slen, hash, create); + } ++ } + return sid; + } + + rpmsid rpmstrPoolId(rpmstrPool pool, const char *s, int create) + { + rpmsid sid = 0; +- ++ #pragma omp critical(rpmstrpool) ++ { + if (s != NULL) { + size_t slen; + unsigned int hash = rstrlenhash(s, &slen); + sid = strn2id(pool, s, slen, hash, create); + } ++ } + return sid; + } + +-const char * rpmstrPoolStr(rpmstrPool pool, rpmsid sid) ++static const char * rpmstrPoolStrNoLock(rpmstrPool pool, rpmsid sid) + { + const char *s = NULL; + if (pool && sid > 0 && sid <= pool->offs_size) +@@ -401,12 +419,25 @@ const char * rpmstrPoolStr(rpmstrPool pool, rpmsid sid) + return s; + } + ++const char * rpmstrPoolStr(rpmstrPool pool, rpmsid sid) ++{ ++ const char *s = NULL; ++ #pragma omp critical(rpmstrpool) ++ { ++ s = rpmstrPoolStrNoLock(pool, sid); ++ } ++ return s; ++} ++ + size_t rpmstrPoolStrlen(rpmstrPool pool, rpmsid sid) + { + size_t slen = 0; ++ #pragma omp critical(rpmstrpool) ++ { + if (pool && sid > 0 && sid <= pool->offs_size) { + slen = strlen(pool->offs[sid]); + } ++ } + return slen; + } + +@@ -421,5 +452,12 @@ int rpmstrPoolStreq(rpmstrPool poolA, rpmsid sidA, + + rpmsid rpmstrPoolNumStr(rpmstrPool pool) + { +- return (pool != NULL) ? pool->offs_size : 0; ++ rpmsid id = 0; ++ #pragma omp critical(rpmstrpool) ++ { ++ if (pool) { ++ id = pool->offs_size; ++ } ++ } ++ return id; + } +-- +2.11.0 + diff --git a/poky/meta/recipes-devtools/rpm/files/0004-build-pack.c-remove-static-local-variables-from-buil.patch b/poky/meta/recipes-devtools/rpm/files/0004-build-pack.c-remove-static-local-variables-from-buil.patch new file mode 100644 index 0000000000..652e30b3e4 --- /dev/null +++ b/poky/meta/recipes-devtools/rpm/files/0004-build-pack.c-remove-static-local-variables-from-buil.patch @@ -0,0 +1,336 @@ +From 792693bb90768cfde4898e8dd31ee1b5de803d2f Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin <alex.kanavin@gmail.com> +Date: Thu, 8 Jun 2017 17:08:09 +0300 +Subject: [PATCH] build/pack.c: remove static local variables from buildHost() + and getBuildTime() + +Their use is causing difficult to diagnoze data races when building multiple +packages in parallel, and is a bad idea in general, as it also makes it more +difficult to reason about code. + +Upstream-Status: Submitted [https://github.com/rpm-software-management/rpm/pull/226] +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> + +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> + +--- + build/build.c | 54 ++++++++++++++++++++++++++++-- + build/pack.c | 84 +++++++++-------------------------------------- + build/rpmbuild_internal.h | 8 +++-- + 3 files changed, 74 insertions(+), 72 deletions(-) + +diff --git a/build/build.c b/build/build.c +index 13c3df2..b154f08 100644 +--- a/build/build.c ++++ b/build/build.c +@@ -6,6 +6,8 @@ + #include "system.h" + + #include <errno.h> ++#include <netdb.h> ++#include <time.h> + #include <sys/wait.h> + + #include <rpm/rpmlog.h> +@@ -16,6 +18,50 @@ + + #include "debug.h" + ++static rpm_time_t getBuildTime(void) ++{ ++ rpm_time_t buildTime = 0; ++ char *srcdate; ++ time_t epoch; ++ char *endptr; ++ ++ srcdate = getenv("SOURCE_DATE_EPOCH"); ++ if (srcdate) { ++ errno = 0; ++ epoch = strtol(srcdate, &endptr, 10); ++ if (srcdate == endptr || *endptr || errno != 0) ++ rpmlog(RPMLOG_ERR, _("unable to parse SOURCE_DATE_EPOCH\n")); ++ else ++ buildTime = (int32_t) epoch; ++ } else ++ buildTime = (int32_t) time(NULL); ++ ++ return buildTime; ++} ++ ++static char * buildHost(void) ++{ ++ char* hostname; ++ struct hostent *hbn; ++ char *bhMacro; ++ ++ bhMacro = rpmExpand("%{?_buildhost}", NULL); ++ if (strcmp(bhMacro, "") != 0) { ++ rasprintf(&hostname, "%s", bhMacro); ++ } else { ++ hostname = rcalloc(1024, sizeof(*hostname)); ++ (void) gethostname(hostname, 1024); ++ hbn = gethostbyname(hostname); ++ if (hbn) ++ strcpy(hostname, hbn->h_name); ++ else ++ rpmlog(RPMLOG_WARNING, ++ _("Could not canonicalize hostname: %s\n"), hostname); ++ } ++ free(bhMacro); ++ return(hostname); ++} ++ + /** + */ + static rpmRC doRmSource(rpmSpec spec) +@@ -201,6 +247,9 @@ static rpmRC buildSpec(BTA_t buildArgs, rpmSpec spec, int what) + rpmRC rc = RPMRC_OK; + int test = (what & RPMBUILD_NOBUILD); + char *cookie = buildArgs->cookie ? xstrdup(buildArgs->cookie) : NULL; ++ const char* host = buildHost(); ++ rpm_time_t buildTime = getBuildTime(); ++ + + if (rpmExpandNumeric("%{?source_date_epoch_from_changelog}") && + getenv("SOURCE_DATE_EPOCH") == NULL) { +@@ -269,11 +318,11 @@ static rpmRC buildSpec(BTA_t buildArgs, rpmSpec spec, int what) + goto exit; + + if (((what & RPMBUILD_PACKAGESOURCE) && !test) && +- (rc = packageSources(spec, &cookie))) ++ (rc = packageSources(spec, &cookie, buildTime, host))) + goto exit; + + if (((what & RPMBUILD_PACKAGEBINARY) && !test) && +- (rc = packageBinaries(spec, cookie, (didBuild == 0)))) ++ (rc = packageBinaries(spec, cookie, (didBuild == 0), buildTime, host))) + goto exit; + + if ((what & RPMBUILD_CLEAN) && +@@ -293,6 +342,7 @@ static rpmRC buildSpec(BTA_t buildArgs, rpmSpec spec, int what) + (void) unlink(spec->specFile); + + exit: ++ free(host); + free(cookie); + spec->rootDir = NULL; + if (rc != RPMRC_OK && rpmlogGetNrecs() > 0) { +diff --git a/build/pack.c b/build/pack.c +index df15876..17a4b09 100644 +--- a/build/pack.c ++++ b/build/pack.c +@@ -6,8 +6,6 @@ + #include "system.h" + + #include <errno.h> +-#include <netdb.h> +-#include <time.h> + #include <sys/wait.h> + + #include <rpm/rpmlib.h> /* RPMSIGTAG*, rpmReadPackageFile */ +@@ -152,57 +150,6 @@ exit: + return rc; + } + +-static rpm_time_t * getBuildTime(void) +-{ +- static rpm_time_t buildTime[1]; +- char *srcdate; +- time_t epoch; +- char *endptr; +- +- if (buildTime[0] == 0) { +- srcdate = getenv("SOURCE_DATE_EPOCH"); +- if (srcdate) { +- errno = 0; +- epoch = strtol(srcdate, &endptr, 10); +- if (srcdate == endptr || *endptr || errno != 0) +- rpmlog(RPMLOG_ERR, _("unable to parse SOURCE_DATE_EPOCH\n")); +- else +- buildTime[0] = (int32_t) epoch; +- } else +- buildTime[0] = (int32_t) time(NULL); +- } +- +- return buildTime; +-} +- +-static const char * buildHost(void) +-{ +- static char hostname[1024]; +- static int oneshot = 0; +- struct hostent *hbn; +- char *bhMacro; +- +- if (! oneshot) { +- bhMacro = rpmExpand("%{?_buildhost}", NULL); +- if (strcmp(bhMacro, "") != 0 && strlen(bhMacro) < 1024) { +- strcpy(hostname, bhMacro); +- } else { +- if (strcmp(bhMacro, "") != 0) +- rpmlog(RPMLOG_WARNING, _("The _buildhost macro is too long\n")); +- (void) gethostname(hostname, sizeof(hostname)); +- hbn = gethostbyname(hostname); +- if (hbn) +- strcpy(hostname, hbn->h_name); +- else +- rpmlog(RPMLOG_WARNING, +- _("Could not canonicalize hostname: %s\n"), hostname); +- } +- free(bhMacro); +- oneshot = 1; +- } +- return(hostname); +-} +- + static rpmRC processScriptFiles(rpmSpec spec, Package pkg) + { + struct TriggerFileEntry *p; +@@ -476,7 +423,8 @@ exit: + * order to how the RPM format is laid on disk. + */ + static rpmRC writeRPM(Package pkg, unsigned char ** pkgidp, +- const char *fileName, char **cookie) ++ const char *fileName, char **cookie, ++ rpm_time_t buildTime, const char* buildHost) + { + FD_t fd = NULL; + char * rpmio_flags = NULL; +@@ -500,7 +448,7 @@ static rpmRC writeRPM(Package pkg, unsigned char ** pkgidp, + + /* Create and add the cookie */ + if (cookie) { +- rasprintf(cookie, "%s %d", buildHost(), (int) (*getBuildTime())); ++ rasprintf(cookie, "%s %d", buildHost, buildTime); + headerPutString(pkg->header, RPMTAG_COOKIE, *cookie); + } + +@@ -641,7 +589,7 @@ static rpmRC checkPackages(char *pkgcheck) + return RPMRC_OK; + } + +-static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int cheating, char** filename) ++static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int cheating, char** filename, rpm_time_t buildTime, const char* buildHost) + { + const char *errorString; + rpmRC rc = RPMRC_OK; +@@ -660,8 +608,8 @@ static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int ch + headerCopyTags(spec->packages->header, pkg->header, copyTags); + + headerPutString(pkg->header, RPMTAG_RPMVERSION, VERSION); +- headerPutString(pkg->header, RPMTAG_BUILDHOST, buildHost()); +- headerPutUint32(pkg->header, RPMTAG_BUILDTIME, getBuildTime(), 1); ++ headerPutString(pkg->header, RPMTAG_BUILDHOST, buildHost); ++ headerPutUint32(pkg->header, RPMTAG_BUILDTIME, &buildTime, 1); + + if (spec->sourcePkgId != NULL) { + headerPutBin(pkg->header, RPMTAG_SOURCEPKGID, spec->sourcePkgId,16); +@@ -699,7 +647,7 @@ static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int ch + free(binRpm); + } + +- rc = writeRPM(pkg, NULL, *filename, NULL); ++ rc = writeRPM(pkg, NULL, *filename, NULL, buildTime, buildHost); + if (rc == RPMRC_OK) { + /* Do check each written package if enabled */ + char *pkgcheck = rpmExpand("%{?_build_pkgcheck} ", *filename, NULL); +@@ -719,7 +667,7 @@ struct binaryPackageTaskData + struct binaryPackageTaskData *next; + }; + +-static struct binaryPackageTaskData* runBinaryPackageTasks(rpmSpec spec, const char *cookie, int cheating) ++static struct binaryPackageTaskData* runBinaryPackageTasks(rpmSpec spec, const char *cookie, int cheating, rpm_time_t buildTime, char* buildHost) + { + struct binaryPackageTaskData *tasks = NULL; + struct binaryPackageTaskData *task = NULL; +@@ -731,7 +679,7 @@ static struct binaryPackageTaskData* runBinaryPackageTasks(rpmSpec spec, const c + if (pkg == spec->packages) { + // the first package needs to be processed ahead of others, as they copy + // changelog data from it, and so otherwise data races would happen +- task->result = packageBinary(spec, pkg, cookie, cheating, &(task->filename)); ++ task->result = packageBinary(spec, pkg, cookie, cheating, &(task->filename), buildTime, buildHost); + rpmlog(RPMLOG_NOTICE, _("Finished binary package job, result %d, filename %s\n"), task->result, task->filename); + tasks = task; + } +@@ -748,7 +696,7 @@ static struct binaryPackageTaskData* runBinaryPackageTasks(rpmSpec spec, const c + if (task != tasks) + #pragma omp task + { +- task->result = packageBinary(spec, task->pkg, cookie, cheating, &(task->filename)); ++ task->result = packageBinary(spec, task->pkg, cookie, cheating, &(task->filename), buildTime, buildHost); + rpmlog(RPMLOG_NOTICE, _("Finished binary package job, result %d, filename %s\n"), task->result, task->filename); + } + } +@@ -766,11 +714,11 @@ static void freeBinaryPackageTasks(struct binaryPackageTaskData* tasks) + } + } + +-rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) ++rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating, rpm_time_t buildTime, char* buildHost) + { + char *pkglist = NULL; + +- struct binaryPackageTaskData *tasks = runBinaryPackageTasks(spec, cookie, cheating); ++ struct binaryPackageTaskData *tasks = runBinaryPackageTasks(spec, cookie, cheating, buildTime, buildHost); + + for (struct binaryPackageTaskData *task = tasks; task != NULL; task = task->next) { + if (task->result == RPMRC_OK) { +@@ -797,7 +745,7 @@ rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating) + return RPMRC_OK; + } + +-rpmRC packageSources(rpmSpec spec, char **cookie) ++rpmRC packageSources(rpmSpec spec, char **cookie, rpm_time_t buildTime, char* buildHost) + { + Package sourcePkg = spec->sourcePackage; + rpmRC rc; +@@ -805,8 +753,8 @@ rpmRC packageSources(rpmSpec spec, char **cookie) + + /* Add some cruft */ + headerPutString(sourcePkg->header, RPMTAG_RPMVERSION, VERSION); +- headerPutString(sourcePkg->header, RPMTAG_BUILDHOST, buildHost()); +- headerPutUint32(sourcePkg->header, RPMTAG_BUILDTIME, getBuildTime(), 1); ++ headerPutString(sourcePkg->header, RPMTAG_BUILDHOST, buildHost); ++ headerPutUint32(sourcePkg->header, RPMTAG_BUILDTIME, &buildTime, 1); + headerPutUint32(sourcePkg->header, RPMTAG_SOURCEPACKAGE, &one, 1); + + /* XXX this should be %_srpmdir */ +@@ -814,7 +762,7 @@ rpmRC packageSources(rpmSpec spec, char **cookie) + char *pkgcheck = rpmExpand("%{?_build_pkgcheck_srpm} ", fn, NULL); + + spec->sourcePkgId = NULL; +- rc = writeRPM(sourcePkg, &spec->sourcePkgId, fn, cookie); ++ rc = writeRPM(sourcePkg, &spec->sourcePkgId, fn, cookie, buildTime, buildHost); + + /* Do check SRPM package if enabled */ + if (rc == RPMRC_OK && pkgcheck[0] != ' ') { +diff --git a/build/rpmbuild_internal.h b/build/rpmbuild_internal.h +index 439b7d3..07e8338 100644 +--- a/build/rpmbuild_internal.h ++++ b/build/rpmbuild_internal.h +@@ -427,19 +427,23 @@ rpmRC processSourceFiles(rpmSpec spec, rpmBuildPkgFlags pkgFlags); + * @param spec spec file control structure + * @param cookie build identifier "cookie" or NULL + * @param cheating was build shortcircuited? ++ * @param buildTime the build timestamp that goes into packages ++ * @param buildHost the hostname where the build is happening + * @return RPMRC_OK on success + */ + RPM_GNUC_INTERNAL +-rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating); ++rpmRC packageBinaries(rpmSpec spec, const char *cookie, int cheating, rpm_time_t buildTime, char* buildHost); + + /** \ingroup rpmbuild + * Generate source package. + * @param spec spec file control structure + * @retval cookie build identifier "cookie" or NULL ++ * @param buildTime the build timestamp that goes into packages ++ * @param buildHost the hostname where the build is happening + * @return RPMRC_OK on success + */ + RPM_GNUC_INTERNAL +-rpmRC packageSources(rpmSpec spec, char **cookie); ++rpmRC packageSources(rpmSpec spec, char **cookie, rpm_time_t buildTime, char* buildHost); + + RPM_GNUC_INTERNAL + int addLangTag(rpmSpec spec, Header h, rpmTagVal tag, diff --git a/poky/meta/recipes-devtools/rpm/rpm_4.15.1.bb b/poky/meta/recipes-devtools/rpm/rpm_4.14.2.1.bb index 5c1190a3df..17255dc87a 100644 --- a/poky/meta/recipes-devtools/rpm/rpm_4.15.1.bb +++ b/poky/meta/recipes-devtools/rpm/rpm_4.14.2.1.bb @@ -24,7 +24,7 @@ HOMEPAGE = "http://www.rpm.org" LICENSE = "GPL-2.0" LIC_FILES_CHKSUM = "file://COPYING;md5=c0bf017c0fd1920e6158a333acabfd4a" -SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.15.x \ +SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.14.x \ file://0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch \ file://0001-Do-not-read-config-files-from-HOME.patch \ file://0001-When-cross-installing-execute-package-scriptlets-wit.patch \ @@ -34,15 +34,20 @@ SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.15.x \ file://0001-Fix-build-with-musl-C-library.patch \ file://0001-Add-a-color-setting-for-mips64_n32-binaries.patch \ file://0011-Do-not-require-that-ELF-binaries-are-executable-to-b.patch \ + file://0001-Split-binary-package-building-into-a-separate-functi.patch \ + file://0002-Run-binary-package-creation-via-thread-pools.patch \ + file://0003-rpmstrpool.c-make-operations-over-string-pools-threa.patch \ + file://0004-build-pack.c-remove-static-local-variables-from-buil.patch \ file://0001-perl-disable-auto-reqs.patch \ file://0001-rpm-rpmio.c-restrict-virtual-memory-usage-if-limit-s.patch \ file://0016-rpmscript.c-change-logging-level-around-scriptlets-t.patch \ + file://0001-mono-find-provides-requires-do-not-use-monodis-from-.patch \ + file://0001-Rip-out-partial-support-for-unused-MD2-and-RIPEMD160.patch \ file://0001-rpmplugins.c-call-dlerror-prior-to-dlsym.patch \ - file://0001-rpmfc.c-do-not-run-file-classification-in-parallel.patch \ " PE = "1" -SRCREV = "ab2179452c5be276a6b96c591afded485c7e58c3" +SRCREV = "4a9440006398646583f0d9ae1837dad2875013aa" S = "${WORKDIR}/git" @@ -56,7 +61,7 @@ export PYTHON_ABI EXTRA_AUTORECONF_append = " --exclude=gnu-configize" EXTRA_OECONF_append = " --without-lua --enable-python --with-crypto=openssl" -EXTRA_OECONF_append_libc-musl = " --disable-nls --disable-openmp" +EXTRA_OECONF_append_libc-musl = " --disable-nls" # --sysconfdir prevents rpm from attempting to access machine-specific configuration in sysroot/etc; we need to have it in rootfs # @@ -122,7 +127,8 @@ do_install_append () { ${D}/${libdir}/rpm/macros sed -i -e 's|/usr/bin/python|${USRBINPATH}/env ${PYTHON_PN}|' \ - ${D}${libdir}/rpm/pythondistdeps.py + ${D}${libdir}/rpm/pythondistdeps.py \ + ${D}${libdir}/rpm/python-macro-helper } FILES_${PN} += "${libdir}/rpm-plugins/*.so \ |