Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sota.conf.inc: remove SOURCE_DATE_EPOCH and REPRODUCIBLE_TIMESTAMP_RO…
…OTFS :Release Notes: Sent upstream in: uptane/meta-updater#35 :Detailed Notes: SOURCE_DATE_EPOCH set to 0 is now causing python3-setuptools-native build to fail with: creating build/bdist.linux-x86_64/wheel/setuptools-59.5.0.dist-info/WHEEL creating '/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/dist/tmpqgh1qmw6/setuptools-59.5.0-py3-none-any.whl' and adding 'build/bdist.linux-x86_64/wheel' to it Traceback (most recent call last): File "<string>", line 1, in <module> File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/setuptools-59.5.0/setuptools/build_meta.py", line 230, in build_wheel return self._build_with_temp_dir(['bdist_wheel'], '.whl', File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/setuptools-59.5.0/setuptools/build_meta.py", line 215, in _build_with_temp_dir self.run_setup() File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/setuptools-59.5.0/setuptools/build_meta.py", line 158, in run_setup exec(compile(code, __file__, 'exec'), locals()) File "setup.py", line 87, in <module> dist = setuptools.setup(**setup_params) File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/setuptools-59.5.0/setuptools/__init__.py", line 153, in setup return distutils.core.setup(**attrs) File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/recipe-sysroot-native/usr/lib/python3.10/distutils/core.py", line 148, in setup dist.run_commands() File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/recipe-sysroot-native/usr/lib/python3.10/distutils/dist.py", line 966, in run_commands self.run_command(cmd) File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/recipe-sysroot-native/usr/lib/python3.10/distutils/dist.py", line 985, in run_command cmd_obj.run() File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/recipe-sysroot-native/usr/lib/python3.10/site-packages/wheel/bdist_wheel.py", line 361, in run wf.write_files(archive_root) File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/recipe-sysroot-native/usr/lib/python3.10/site-packages/wheel/wheelfile.py", line 136, in write_files self.write(path, arcname) File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/recipe-sysroot-native/usr/lib/python3.10/site-packages/wheel/wheelfile.py", line 147, in write zinfo = ZipInfo(arcname or filename, date_time=get_zipinfo_datetime(st.st_mtime)) File "/OE/lge/build/webosose/kirkstone/BUILD/work/x86_64-linux/python3-setuptools-native/59.5.0-r0/recipe-sysroot-native/usr/lib/python3.10/zipfile.py", line 362, in __init__ raise ValueError('ZIP does not support timestamps before 1980') ValueError: ZIP does not support timestamps before 1980 The st.st_mtime is correct timestamp, but get_zipinfo_datetime function in python3.10/site-packages/wheel/wheelfile.py will prefer SOURCE_DATE_EPOCH when set: def get_zipinfo_datetime(timestamp=None): # Some applications need reproducible .whl files, but they can't do this without forcing # the timestamp of the individual ZipInfo objects. See issue #143. timestamp = int(os.environ.get('SOURCE_DATE_EPOCH', timestamp or time.time())) return time.gmtime(timestamp)[0:6] Which leads to 1.1.1970 which isn't supported by ZIP. The default value will use get_source_date_epoch_value: # $SOURCE_DATE_EPOCH [2 operations] # exported /OE/lge/build/webosose/kirkstone/oe-core/meta/conf/bitbake.conf:672 # [export] "1" # set? /OE/lge/build/webosose/kirkstone/oe-core/meta/conf/bitbake.conf:672 # "${@get_source_date_epoch_value(d)}" # pre-expansion value: # "${@get_source_date_epoch_value(d)}" export SOURCE_DATE_EPOCH="1638725317" which in this case is: python3-setuptools-native/59.5.0-r0/source-date-epoch/__source_date_epoch.txt 1638725317 $ date --date='@1638725317' Sun Dec 5 18:28:37 CET 2021 I believe the reproducible builds now enabled by default in oe-core work reasonably well and forcing this to 0 as added in: uptane/meta-updater@3d3a0bf uptane/meta-updater@af1694c is no longer necessary. :Testing Performed: Only build tested. :QA Notes: No change to image. :Issues Addressed: [WRN-9820] Create GPVB with Yocto 3.5 Kirkstone --- conf/distro/sota.conf.inc | 3 --- 1 file changed, 3 deletions(-) diff --git a/conf/distro/sota.conf.inc b/conf/distro/sota.conf.inc index 9dc64dd..9b70fa4 100644 --- a/conf/distro/sota.conf.inc +++ b/conf/distro/sota.conf.inc @@ -8,8 +8,5 @@ DISTRO_FEATURES:append = " sota usrmerge" DISTRO_FEATURES_NATIVE:append = " sota" INHERIT += " sota" -export SOURCE_DATE_EPOCH = "0" -REPRODUCIBLE_TIMESTAMP_ROOTFS = "0" - HOSTTOOLS += "sync" HOSTTOOLS_NONFATAL += "java repo" Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
- Loading branch information