diff --git a/documentation/ref-manual/ref-tasks.xml b/documentation/ref-manual/ref-tasks.xml
index b4db97c53b..93ad692775 100644
--- a/documentation/ref-manual/ref-tasks.xml
+++ b/documentation/ref-manual/ref-tasks.xml
@@ -429,12 +429,80 @@
Locates patch files and applies them to the source code.
- See the
+
+
+
+ After fetching and unpacking source files, the build system locates
+ and applies patches to the source code.
+ Patch files, by default, are *.patch and
+ *.diff files created and kept in a
+ subdirectory of the directory holding the recipe file.
+ For example, consider the
+ bluez5
+ recipe from the OE-Core layer (i.e.
+ poky/meta):
+
+ poky/meta/recipes-connectivity/bluez5
+
+ This recipe has two patch files located here:
+
+ poky/meta/recipes-connectivity/bluez5/bluez5
+
+
+
+
+ The recipe for bluez5 uses the
+ SRC_URI
+ variable to point to the source and patch files needed to build
+ the recipe.
+
+ In the case for the bluez5_5.48.bb
+ recipe, the SRC_URI statements are from an
+ include file bluez5.inc.
+
+
+
+
+ As mentioned earlier, the build system treats files whose file
+ types are .patch and
+ .diff as patch files.
+ However, you can use the "apply=yes" parameter with the
+ SRC_URI statement to indicate any file as a
+ patch file:
+
+ SRC_URI = " \
+ git://path_to_repo/some_recipe \
+ file://file;apply=yes \
+ "
+
+
+
+
+ Conversely, if you have a directory full of patch files and you
+ want to exclude some so that the do_patch
+ task does not apply them during the patch phase, you can use
+ the "apply=no" parameter with the SRC_URI
+ statement:
+
+ SRC_URI = " \
+ git://path_to_repo/some_recipe \
+ file://path_to_lots_of_patch_files \
+ file://path_to_lots_of_patch_files/patch_file5;apply=no \
+ "
+
+ In the previous example, assuming all the files in the directory
+ holding the patch files end with either .patch
+ or .diff, every file would be applied as a
+ patch by default except for the
+ patch_file5 patch.
+
+
+
+ You can find out more about the patching process in the
"Patching"
section in the Yocto Project Overview and Concepts Manual and the
- "Patching Code""
- section in the Yocto Project Development Tasks Manual for more
- information.
+ "Patching Code"
+ section in the Yocto Project Development Tasks Manual.