When a file (a patch or a generic file) is included in SRC_URI, BitBake searches for FILESPATH and FILESEXTRAPTH variables. The default setting is to look in the following locations:
As well as this, it also checks for a OVERRIDES for a specific files to be overrided in each folder. To illustrate this, consider a recipe, foo_1.0.bb, and the variable OVERRIDES = "<board>:<arch>" the file will be searched in the following directories, respecting the exact order, shown:
This is just illustrative as the list of OVERRIDES is huge and machine-specific. When we work ...