From 5486dd368070ec1c868f32d72a5f9ce07e34d189 Mon Sep 17 00:00:00 2001 From: "rpjday@crashcourse.ca" Date: Mon, 23 Mar 2020 09:57:52 -0400 Subject: ref-manual: update PROVIDES example, clarify use of "+=" Update the example used in explaining the PROVIDES variable to one that actually exists, and point out that "+=" is unnecessary, a simple assignment is sufficient. (From yocto-docs rev: 80cd888ee81757bc5281f174b26974391ee45522) Signed-off-by: Robert P. J. Day Signed-off-by: Richard Purdie --- documentation/ref-manual/ref-variables.xml | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/documentation/ref-manual/ref-variables.xml b/documentation/ref-manual/ref-variables.xml index c400d1e142..9723cbb4d4 100644 --- a/documentation/ref-manual/ref-variables.xml +++ b/documentation/ref-manual/ref-variables.xml @@ -11542,23 +11542,35 @@ By default, a recipe's own PN is implicitly already in its PROVIDES - list. + list and therefore does not need to mention that it provides itself. If a recipe uses PROVIDES, the additional aliases are synonyms for the recipe and can - be useful satisfying dependencies of other recipes during + be useful for satisfying dependencies of other recipes during the build as specified by DEPENDS. Consider the following example - PROVIDES statement from a recipe - file libav_0.8.11.bb: + PROVIDES statement from the recipe + file eudev_3.2.9.bb: - PROVIDES += "libpostproc" + PROVIDES = "udev" The PROVIDES statement results in - the "libav" recipe also being known as "libpostproc". + the "eudev" recipe also being available as simply "udev". + + + Given that a recipe's own recipe name is already + implicitly in its own PROVIDES list, + it is unnecessary to add aliases with the "+=" operator; + using a simple assignment will be sufficient. In other + words, while you could write: + + PROVIDES += "udev" + + in the above, the "+=" is overkill and unnecessary. + -- cgit v1.2.3-54-g00ecf