Skip to contentSkip to conversation

os-release change - build failure #bitbake #os-release

DISCUSSION Gangadhar N 1 participant 1 message Aug 1, 2022

lore
Share & tools
lore
#0 lore raw

Hi All,
I made below change in recipes-core/os-release/os-release.bbappend. It results in build failure. Please give me pointers to resolve the issue. I deleted build/cache and build/sstate-cache. But it didn't resolve the issue.

Thanks & Regards,
Gangadhar

Change made:
--------------------

@@ -18,7 +18,7 @@ python() {
if target_machine:
d.setVar('OPENBMC_TARGET_MACHINE', target_machine)

-    date_str = bb.process.run('date +"%Y%m%d-%H"')[0].strip('\n') +    date_str = bb.process.run('date +"%Y-%m-%d %H:%M:%S"')[0].strip('\n')

version_id = "${DISTRO_VERSION}" + "-" + date_str

Original code:
___________

python() {
target_machine = d.getVar('MACHINE', True) if target_machine:
d.setVar('OPENBMC_TARGET_MACHINE', target_machine)

date_str = bb.process.run('date +"%Y%m%d-%H"')[0].strip('\n')

version_id = "${DISTRO_VERSION}" + "-" + date_str

git_description = run_git(d, 'describe --dirty --long')

d.setVar('VERSION_ID', version_id)
build_id = git_description
d.setVar('BUILD_ID', build_id)
}

-----------------------------Error log--------------------------------------------------
ERROR: When reparsing /home/gangadhar/openbmc/meta/recipes-core/os-release/os-release.bb:do_compile, the basehash value changed from d097fd959c9279c6f46ce70c65b20dd566269c3b3ff068543a49dbd5ba0e2b6a to 536804bd358edc0dc61059e12c5b5e4a2e6d4658c0d4ec4ff9cf39fceb769f1f. The metadata is not deterministic and this needs to be fixed.
ERROR: The following commands may help:
ERROR: $ bitbake os-release -cdo_compile -Snone
ERROR: Then:
ERROR: $ bitbake os-release -cdo_compile -Sprintdiff

ERROR: os-release-1.0-r0 do_compile: Taskhash mismatch ab507017c7cb41dee34112e53705212c320f8432ebd0368d161f173aa97083c3 versus 4de80f60ca66d55cec2c36ddf5470b295be215dacede6e0dba0c698b81fde649 for /home/gangadhar/openbmc/meta/recipes-core/os-release/os-release.bb:do_compile
ERROR: Taskhash mismatch ab507017c7cb41dee34112e53705212c320f8432ebd0368d161f173aa97083c3 versus 4de80f60ca66d55cec2c36ddf5470b295be215dacede6e0dba0c698b81fde649 for /home/gangadhar/openbmc/meta/recipes-core/os-release/os-release.bb:do_compile
ERROR: When reparsing /home/gangadhar/openbmc/meta/recipes-core/os-release/os-release.bb:do_compile, the basehash value changed from d097fd959c9279c6f46ce70c65b20dd566269c3b3ff068543a49dbd5ba0e2b6a to 536804bd358edc0dc61059e12c5b5e4a2e6d4658c0d4ec4ff9cf39fceb769f1f. The metadata is not deterministic and this needs to be fixed.
ERROR: The following commands may help:
ERROR: $ bitbake os-release -cdo_compile -Snone
ERROR: Then:
ERROR: $ bitbake os-release -cdo_compile -Sprintdiff

ERROR: When reparsing /home/gangadhar/openbmc/meta/recipes-core/os-release/os-release.bb:do_compile, the basehash value changed from d097fd959c9279c6f46ce70c65b20dd566269c3b3ff068543a49dbd5ba0e2b6a to 536804bd358edc0dc61059e12c5b5e4a2e6d4658c0d4ec4ff9cf39fceb769f1f. The metadata is not deterministic and this needs to be fixed.
ERROR: The following commands may help:
ERROR: $ bitbake os-release -cdo_compile -Snone
ERROR: Then:
ERROR: $ bitbake os-release -cdo_compile -Sprintdiff

ERROR: When reparsing /home/gangadhar/openbmc/meta/recipes-core/os-release/os-release.bb:do_compile, the basehash value changed from d097fd959c9279c6f46ce70c65b20dd566269c3b3ff068543a49dbd5ba0e2b6a to 536804bd358edc0dc61059e12c5b5e4a2e6d4658c0d4ec4ff9cf39fceb769f1f. The metadata is not deterministic and this needs to be fixed.
ERROR: The following commands may help:
ERROR: $ bitbake os-release -cdo_compile -Snone
ERROR: Then:
ERROR: $ bitbake os-release -cdo_compile -Sprintdiff