Bug 4474

Summary: bitbake fails to find patch files moved to a second valid location
Product: [Build System, Metadata & Runtime] BitBake Reporter: Jerrod Peach <peachj>
Component: bitbakeAssignee: Paul Eggleton <bluelightning>
Status: RESOLVED FIXED QA Contact:
Severity: minor    
Priority: Medium CC: poky.bs.watcher, poky.watcher, sgw
Version: 1.4   
Target Milestone: 1.5   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---

Description Jerrod Peach 2013-05-09 13:42:55 UTC
If you have a recipe applying patches (via SRC_URI += <patch file>), build that recipe at least once, then move the patch file to a second valid location (e.g. from <pn>/<patch file> to files/<patch file>), bitbake will spit out the following warning:

WARNING: Unable to get checksum for <PN> SRC_URI entry <patch file>: [Errno 2] No such file or directory: '<path to patch file's previous location>'

The only way to clear the warning appears to be wiping out your parse cache, e.g. rm -r tmp/cache.  Rebuilding from that point on will make the warning go away.  I'm believe the patch is still being applied even when the warning appears (though I am not certain), but the message might lead you to believe otherwise.  This warning should probably not appear if the patch is found in a second location.
Comment 1 Paul Eggleton 2013-06-04 09:02:49 UTC
Patch sent to the bitbake-devel mailing list to fix this.

FYI, you can work around this problem by running "touch" on the recipe file - no need to delete the cache. You are correct in that the patch file is being applied even when the warning is shown; all that breaks is the calculation of the checksum which we use to trigger a re-run of do_fetch and all tasks that depend upon it when one of the local files referred to in SRC_URI changes.