package_deb/ipk/rpm: Add more minimal do_build dependencies back
PATCH 1/4 package_deb/ipk/rpm: Add more minimal do_build dependencies back
The dependencies for do_build became a little too minimal after the removal of recrdeptask since "bitbake go" would not package go-runtime despite it being in DEPENDS and the resulting package having a dependency on it.
A reasonable compromise is probably rdeptask instead of recrdeptask which is a lot lower overhead but makes the build target more useful and importantly, lets world builds do what you'd expect them to.
--- meta/classes/package_deb.bbclass | 1 + meta/classes/package_ipk.bbclass | 1 + meta/classes/package_rpm.bbclass | 1 + 3 files changed, 3 insertions(+)
meta/classes/package_deb.bbclass +1 -0
@@ -316,6 +316,7 @@ do_package_write_deb[dirs] = "${PKGWRITEDIRDEB}" do_package_write_deb[cleandirs] = "${PKGWRITEDIRDEB}" do_package_write_deb[depends] += "${@oe.utils.build_depends_string(d.getVar('PACKAGE_WRITE_DEPS'), 'do_populate_sysroot')}" addtask package_write_deb after do_packagedata do_package do_deploy_source_date_epoch before do_build +do_build[rdeptask] += "do_package_write_deb" PACKAGEINDEXDEPS += "dpkg-native:do_populate_sysroot" PACKAGEINDEXDEPS += "apt-native:do_populate_sysroot"
meta/classes/package_ipk.bbclass +1 -0
@@ -275,6 +275,7 @@ do_package_write_ipk[dirs] = "${PKGWRITEDIRIPK}" do_package_write_ipk[cleandirs] = "${PKGWRITEDIRIPK}" do_package_write_ipk[depends] += "${@oe.utils.build_depends_string(d.getVar('PACKAGE_WRITE_DEPS'), 'do_populate_sysroot')}" addtask package_write_ipk after do_packagedata do_package do_deploy_source_date_epoch before do_build +do_build[rdeptask] += "do_package_write_ipk" PACKAGEINDEXDEPS += "opkg-utils-native:do_populate_sysroot" PACKAGEINDEXDEPS += "opkg-native:do_populate_sysroot"
meta/classes/package_rpm.bbclass +1 -0
@@ -749,6 +749,7 @@ do_package_write_rpm[dirs] = "${PKGWRITEDIRRPM}" do_package_write_rpm[cleandirs] = "${PKGWRITEDIRRPM}" do_package_write_rpm[depends] += "${@oe.utils.build_depends_string(d.getVar('PACKAGE_WRITE_DEPS'), 'do_populate_sysroot')}" addtask package_write_rpm after do_packagedata do_package do_deploy_source_date_epoch before do_build +do_build[rdeptask] += "do_package_write_rpm" PACKAGEINDEXDEPS += "rpm-native:do_populate_sysroot" PACKAGEINDEXDEPS += "createrepo-c-native:do_populate_sysroot"
Signature · 1 line
2.32.0
PATCH 2/4 meson: Handle qemu riscv issues
In qemu, they merged the 32 and 64 bit riscv variants into one target for meson purposes but this isn't officially supported by upstream meson. In normal builds this would just be a warning but in OE, this is fatal.
Avoid the fatal errors for now and build as qemu intended whilst this is resolved by the upstreams.
--- .../0001-Make-CPU-family-warnings-fatal.patch | 28 +++++++++++-------- 1 file changed, 16 insertions(+), 12 deletions(-)
meta/recipes-devtools/meson/meson/0001-Make-CPU-family-warnings-fatal.patch +16 -12
@@ -11,30 +11,34 @@ Signed-off-by: Ross Burton <[email protected]> mesonbuild/environment.py | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) -diff --git a/mesonbuild/envconfig.py b/mesonbuild/envconfig.py -index 307aac3..66fb7ec 100644 ---- a/mesonbuild/envconfig.py -+++ b/mesonbuild/envconfig.py -@@ -267,7 +267,7 @@ class MachineInfo(HoldableObject): +Index: meson-0.60.2/mesonbuild/envconfig.py +=================================================================== +--- meson-0.60.2.orig/mesonbuild/envconfig.py ++++ meson-0.60.2/mesonbuild/envconfig.py +@@ -266,8 +266,8 @@ class MachineInfo(HoldableObject): + 'but is missing {}.'.format(minimum_literal - set(literal))) cpu_family = literal['cpu_family'] - if cpu_family not in known_cpu_families: +- if cpu_family not in known_cpu_families: - mlog.warning(f'Unknown CPU family {cpu_family}, please report this at https://github.com/mesonbuild/meson/issues/new') ++ if cpu_family not in known_cpu_families and cpu_family != "riscv": + raise EnvironmentException('Unknown CPU family {}, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.'.format(cpu_family)) endian = literal['endian'] if endian not in ('little', 'big'): -diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py -index 71286a5..179917e 100644 ---- a/mesonbuild/environment.py -+++ b/mesonbuild/environment.py -@@ -352,9 +352,7 @@ def detect_cpu_family(compilers: CompilersDict) -> str: +Index: meson-0.60.2/mesonbuild/environment.py +=================================================================== +--- meson-0.60.2.orig/mesonbuild/environment.py ++++ meson-0.60.2/mesonbuild/environment.py +@@ -354,10 +354,8 @@ def detect_cpu_family(compilers: Compile + if any_compiler_has_define(compilers, '__64BIT__'): trial = 'ppc64' - if trial not in known_cpu_families: +- if trial not in known_cpu_families: - mlog.warning(f'Unknown CPU family {trial!r}, please report this at ' - 'https://github.com/mesonbuild/meson/issues/new with the ' - 'output of `uname -a` and `cat /proc/cpuinfo`') ++ if trial not in known_cpu_families and trail != "riscv": + raise EnvironmentException('Unknown CPU family %s, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.' % trial) return trial
Signature · 1 line
2.32.0
PATCH 3/4 openssl: Add reproducibility fix
In reply to Richard PurdieWhen the date rolled from one year to another, it highlighted a reproducibility issue in openssl. Patch a workaround for this to avoid autobuilder failures. Help submitting upstream welcome.
--- .../openssl/openssl/reproducibility.patch | 22 +++++++++++++++++++ .../openssl/openssl_3.0.1.bb | 1 + 2 files changed, 23 insertions(+) create mode 100644 meta/recipes-connectivity/openssl/openssl/reproducibility.patch
meta/recipes-connectivity/openssl/openssl/reproducibility.patch new file +22 -0
@@ -0,0 +1,22 @@ +Using localtime() means the output can depend on the timezone of the build machine. +Using gmtime() is safer. For complete reproducibility use SOURCE_DATE_EPOCH if set. + +Signed-off-by: Richard Purdie <[email protected]> +Upstream-Status: Pending [should be suitable] + +Index: openssl-3.0.1/apps/progs.pl +=================================================================== +--- openssl-3.0.1.orig/apps/progs.pl ++++ openssl-3.0.1/apps/progs.pl +@@ -21,7 +21,10 @@ die "Unrecognised option, must be -C or + my %commands = (); + my $cmdre = qr/^\s*int\s+([a-z_][a-z0-9_]*)_main\(\s*int\s+argc\s*,/; + my $apps_openssl = shift @ARGV; +-my $YEAR = [localtime()]->[5] + 1900; ++my $YEAR = [gmtime()]->[5] + 1900; ++if (defined($ENV{SOURCE_DATE_EPOCH}) && $ENV{SOURCE_DATE_EPOCH} !~ /\D/) { ++ $YEAR = [gmtime($ENV{SOURCE_DATE_EPOCH})]->[5] + 1900; ++} + + # because the program apps/openssl has object files as sources, and + # they then have the corresponding C files as source, we need to chain
meta/recipes-connectivity/openssl/openssl_3.0.1.bb +1 -0
@@ -12,6 +12,7 @@ SRC_URI = "http://www.openssl.org/source/openssl-${PV}.tar.gz \ file://0001-buildinfo-strip-sysroot-and-debug-prefix-map-from-co.patch \ file://afalg.patch \ file://0001-Configure-do-not-tweak-mips-cflags.patch \ + file://reproducibility.patch \ " SRC_URI:append:class-nativesdk = " \
Signature · 1 line
2.32.0
PATCH 4/4 webkitgtk: Add reproducibility fix
In reply to Richard PurdieWhen the date rolled from one year to another this highlighted a reproducibility issue. This could be better fixed by using SOURCE_DATE_EPOCH from the environment but I'm not sure how you do that in ruby. Help from someone with that knowledge to submit that upstream very welcome.
--- .../webkit/webkitgtk/reproducibility.patch | 22 +++++++++++++++++++ meta/recipes-sato/webkit/webkitgtk_2.34.2.bb | 1 + 2 files changed, 23 insertions(+) create mode 100644 meta/recipes-sato/webkit/webkitgtk/reproducibility.patch
meta/recipes-sato/webkit/webkitgtk/reproducibility.patch new file +22 -0
@@ -0,0 +1,22 @@ +Injection a year based on the current date isn't reproducible. Hack this +to a specific year for now for reproducibilty and to avoid autobuilder failures. + +The correct fix would be to use SOURCE_DATE_EPOCH from the environment and +then this could be submitted upstream, sadly my ruby isn't up to that. + +Upstream-Status: Pending [could be reworked] +Signed-off-by: Richard Purdie <[email protected]> + +Index: webkitgtk-2.34.2/Source/JavaScriptCore/generator/GeneratedFile.rb +=================================================================== +--- webkitgtk-2.34.2.orig/Source/JavaScriptCore/generator/GeneratedFile.rb ++++ webkitgtk-2.34.2/Source/JavaScriptCore/generator/GeneratedFile.rb +@@ -25,7 +25,7 @@ require 'date' + require 'digest' + + $LICENSE = <<-EOF +-Copyright (C) #{Date.today.year} Apple Inc. All rights reserved. ++Copyright (C) 2021 Apple Inc. All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions
meta/recipes-sato/webkit/webkitgtk_2.34.2.bb +1 -0
@@ -18,6 +18,7 @@ SRC_URI = "https://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \ file://reduce-memory-overheads.patch \ file://musl-lower-stack-usage.patch \ file://0001-Fix-build-without-opengl-or-es.patch \ + file://reproducibility.patch \ " SRC_URI[sha256sum] = "584677d6e7cae12e27cdcc8e05b4cf73b54849a24afc3d7a40cec91016deff00"
Signature · 1 line
2.32.0
Re: [OE-core] [PATCH 4/4] webkitgtk: Add reproducibility fix
Hi Richard,
Quoted 5 lines · Richard Purdie
When the date rolled from one year to another this highlighted a reproducibility issue. This could be better fixed by using
SOURCE_DATE_EPOCHfrom the environment but I'm not sure how you do that in ruby. Help from someone with that knowledge to submit that upstream very welcome.
Small side note, it seems like "copyright years" aren't actually any useful, see https://hynek.me/til/copyright-years/ and https://www.linuxfoundation.org/blog/copyright-notices-in-open-source-software-projects/.
I guess we can just notify the project to stop using the date entirely in the copyright to avoid those issues and hope they'll just agree :)
Cheers,
Quentin
Re: [OE-core] [PATCH 4/4] webkitgtk: Add reproducibility fix
In reply to Richard PurdieQuoted 28 lines · Richard Purdie
When the date rolled from one year to another this highlighted a reproducibility issue. This could be better fixed by using
SOURCE_DATE_EPOCHfrom the environment but I'm not sure how you do that in ruby. Help from someone with that knowledge to submit that upstream very welcome.Signed-off-by Richard Purdie <[email protected]>--- .../webkit/webkitgtk/reproducibility.patch | 22 +++++++++++++++++++ meta/recipes-sato/webkit/webkitgtk_2.34.2.bb | 1 + 2 files changed, 23 insertions(+) create mode 100644 meta/recipes-sato/webkit/webkitgtk/reproducibility.patchmeta/recipes-sato/webkit/webkitgtk/reproducibility.patch new file +9
-0@@ -0,0 +1,22 @@ +Injection a year based on the current date isn't reproducible. Hack this +to a specific year for now for reproducibilty and to avoid autobuilder failures. + +The correct fix would be to use SOURCE_DATE_EPOCH from the environment and +then this could be submitted upstream, sadly my ruby isn't up to that. + +Upstream-Status: Pending [could be reworked] +Signed-off-by: Richard Purdie <[email protected]> +
meta/recipes-sato/webkit/webkitgtk/reproducibility.patch line 19
Quoted 10 lines
meta/recipes-sato/webkit/webkitgtk/reproducibility.patch new file +10
-0+Index: webkitgtk-2.34.2/Source/JavaScriptCore/generator/GeneratedFile.rb +=================================================================== +--- webkitgtk-2.34.2.orig/Source/JavaScriptCore/generator/GeneratedFile.rb ++++ webkitgtk-2.34.2/Source/JavaScriptCore/generator/GeneratedFile.rb +@@ -25,7 +25,7 @@ require 'date' + require 'digest' + + $LICENSE = <<-EOF +-Copyright (C) #{Date.today.year} Apple Inc. All rights reserved. ++Copyright (C) 2021 Apple Inc. All rights reserved.
perhaps eliminating the year completely is better.
Quoted 27 lines
meta/recipes-sato/webkit/webkitgtk/reproducibility.patch new file +3
-0+ + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditionsmeta/recipes-sato/webkit/webkitgtk_2.34.2.bb +1
-1@@ -18,6 +18,7 @@ SRC_URI = "https://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \ file://reduce-memory-overheads.patch \ file://musl-lower-stack-usage.patch \ file://0001-Fix-build-without-opengl-or-es.patch \ + file://reproducibility.patch \ " SRC_URI[sha256sum] = "584677d6e7cae12e27cdcc8e05b4cf73b54849a24afc3d7a40cec91016deff00" --2.32.0
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#160165): https://lists.openembedded.org/g/openembedded-core/message/160165
Mute This Topic: https://lists.openembedded.org/mt/88190252/1997914
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-