[yocto] How to patch local source files

Aaron_Wright at selinc.com Aaron_Wright at selinc.com
Fri Feb 16 10:03:41 PST 2018


I've been using "devtool modify/update-recipe" in order to generate 
patches in bbappends in my layer. However, I've run into a problem that 
seems like it should be easy, but it isn't.

I want to patch a local source file. As in, a file referenced in SRC_URI 
that isn't the source code but more like a configuration file or init 
script. 

Using the devtool method I get a copy of the file in my layer, but that 
seems like that would cause maintenance problems down the road when 
upstream changes the file as I won't automatically pick up the changes. 
This seems to be the intended behavior though, as this patch[1] says, "We 
don't want to create patches against the local source files but rather 
update them directly. Thus, 'oe-local-file' directory is ignored in patch 
generation when doing update-recipe..." This seems completely opposite of 
what I want. Why would I want a copy of the file if I changed one line, 
causing maintenance issues in the future?

Am I understanding this right? Is there a workflow that allows for 
patching local source files?

[1] https://urldefense.proofpoint.com/v2/url?u=https-3A__patchwork.openembedded.org_patch_104075_&d=DwIBAg&c=zVFQZQ67ypsA9mYKSCqWmQHiVkCCaN-Gb60_N6TVnLk&r=IZ3mUDA8X9CZR4hNctKngDDYs_BhK3qVNLG-nWGbW2E&m=8pcye74JGQLQcBV99bh9bpRb7bX3WqHFUiIq157bDY4&s=XLqetQZfaf9jTNco2uT4jCN6FbQ1tHD9F_ZJQvBouJI&e=
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20180216/57f7cb2a/attachment.html>


More information about the yocto mailing list