summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrpjday@crashcourse.ca <rpjday@crashcourse.ca>2020-03-23 09:57:52 -0400
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-04-06 14:40:24 +0100
commit5486dd368070ec1c868f32d72a5f9ce07e34d189 (patch)
tree78597db49ca79a09741c48bd05ca468d12855592
parentf63d44ab32a4438c3b0708e6bf759b4d6ff01bf0 (diff)
downloadpoky-5486dd368070ec1c868f32d72a5f9ce07e34d189.tar.gz
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 <rpjday@crashcourse.ca> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--documentation/ref-manual/ref-variables.xml24
1 files 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 @@
11542 By default, a recipe's own 11542 By default, a recipe's own
11543 <filename><link linkend='var-PN'>PN</link></filename> 11543 <filename><link linkend='var-PN'>PN</link></filename>
11544 is implicitly already in its <filename>PROVIDES</filename> 11544 is implicitly already in its <filename>PROVIDES</filename>
11545 list. 11545 list and therefore does not need to mention that it provides itself.
11546 If a recipe uses <filename>PROVIDES</filename>, the 11546 If a recipe uses <filename>PROVIDES</filename>, the
11547 additional aliases are synonyms for the recipe and can 11547 additional aliases are synonyms for the recipe and can
11548 be useful satisfying dependencies of other recipes during 11548 be useful for satisfying dependencies of other recipes during
11549 the build as specified by 11549 the build as specified by
11550 <filename><link linkend='var-DEPENDS'>DEPENDS</link></filename>. 11550 <filename><link linkend='var-DEPENDS'>DEPENDS</link></filename>.
11551 </para> 11551 </para>
11552 11552
11553 <para> 11553 <para>
11554 Consider the following example 11554 Consider the following example
11555 <filename>PROVIDES</filename> statement from a recipe 11555 <filename>PROVIDES</filename> statement from the recipe
11556 file <filename>libav_0.8.11.bb</filename>: 11556 file <filename>eudev_3.2.9.bb</filename>:
11557 <literallayout class='monospaced'> 11557 <literallayout class='monospaced'>
11558 PROVIDES += "libpostproc" 11558 PROVIDES = "udev"
11559 </literallayout> 11559 </literallayout>
11560 The <filename>PROVIDES</filename> statement results in 11560 The <filename>PROVIDES</filename> statement results in
11561 the "libav" recipe also being known as "libpostproc". 11561 the "eudev" recipe also being available as simply "udev".
11562
11563 <note>
11564 Given that a recipe's own recipe name is already
11565 implicitly in its own <filename>PROVIDES</filename> list,
11566 it is unnecessary to add aliases with the "+=" operator;
11567 using a simple assignment will be sufficient. In other
11568 words, while you could write:
11569 <literallayout class='monospaced'>
11570 PROVIDES += "udev"
11571 </literallayout>
11572 in the above, the "+=" is overkill and unnecessary.
11573 </note>
11562 </para> 11574 </para>
11563 11575
11564 <para> 11576 <para>