summaryrefslogtreecommitdiffstats
path: root/bitbake/doc/manual/usermanual.xml
diff options
context:
space:
mode:
authorChris Larson <chris_larson@mentor.com>2010-03-19 17:22:19 -0700
committerRichard Purdie <rpurdie@linux.intel.com>2010-03-25 17:25:45 +0000
commitc24424327409544807a781bba4e6f9a8e178dcce (patch)
tree5df97b6f8665f6cdf9a9698c05e2a98f58bd5975 /bitbake/doc/manual/usermanual.xml
parentcefeeb1aa30a9d8744a6ff9c51811ebc8d18c735 (diff)
downloadpoky-c24424327409544807a781bba4e6f9a8e178dcce.tar.gz
Implement BBVERSIONS
This implements a feature similar to BBCLASSEXTEND, but for generating multiple versions of a given recipe. For example: BBVERSIONS = "1.0 2.0 git". In addition to the above, one can utilize [a-b] style patterns, and can have a :<basever> postfix, which allows you to essentially name the range of versions. Both the current version and the basever end up in OVERRIDES, and the basever gets placed into the BPV variable. The default BPV, if none is specified, is the original PV of the recipe, before bbversions processing. In this way, you can do things like: BBVERSIONS = "1.0.[0-6]:1.0.0+ 1.0.[7-9]:1.0.7+" SRC_URI_append_1.0.7+ = "file://some_extra_patch.patch;patch=1" Or you can create a recipe per range, and name the recipe file as such: nano_1.0.7+.bb. (Bitbake rev: 4ee9a56e16f1eb3c1649eaa3127b09ab0e93d1ec) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/doc/manual/usermanual.xml')
-rw-r--r--bitbake/doc/manual/usermanual.xml14
1 files changed, 13 insertions, 1 deletions
diff --git a/bitbake/doc/manual/usermanual.xml b/bitbake/doc/manual/usermanual.xml
index 29cdf97a0a..6424a7ebd9 100644
--- a/bitbake/doc/manual/usermanual.xml
+++ b/bitbake/doc/manual/usermanual.xml
@@ -228,6 +228,18 @@ This event handler gets called every time an event is triggered. A global variab
228method one can get the name of the triggered event.</para><para>The above event handler prints the name 228method one can get the name of the triggered event.</para><para>The above event handler prints the name
229of the event and the content of the <varname>FILE</varname> variable.</para> 229of the event and the content of the <varname>FILE</varname> variable.</para>
230 </section> 230 </section>
231 <section>
232 <title>Variants</title>
233 <para>Two Bitbake features exist to facilitate the creation of multiple buildable incarnations from a single recipe file.</para>
234 <para>The first is <varname>BBCLASSEXTEND</varname>. This variable is a space separated list of classes to utilize to "extend" the recipe for each variant. As an example, setting <screen>BBCLASSEXTEND = "native"</screen> results in a second incarnation of the current recipe being available. This second incarantion will have the "native" class inherited.</para>
235 <para>The second feature is <varname>BBVERSIONS</varname>. This variable allows a single recipe to be able to build multiple versions of a project from a single recipe file, and allows you to specify conditional metadata (using the <varname>OVERRIDES</varname> mechanism) for a single version, or an optionally named range of versions:</para>
236 <para><screen>BBVERSIONS = "1.0 2.0 git"
237SRC_URI_git = "git://someurl/somepath.git"</screen></para>
238 <para><screen>BBVERSIONS = "1.0.[0-6]:1.0.0+ \
239 1.0.[7-9]:1.0.7+"
240SRC_URI_append_1.0.7+ = "file://some_patch_which_the_new_versions_need.patch;patch=1"</screen></para>
241 <para>Note that the name of the range will default to the original version of the recipe, so given OE, a recipe file of foo_1.0.0+.bb will default the name of its versions to 1.0.0+. This is useful, as the range name is not only placed into overrides, it's also made available for the metadata to use in the form of the <varname>BPV</varname> variable, for use in file:// search paths (<varname>FILESPATH</varname>).</para>
242 </section>
231 </section> 243 </section>
232 <section> 244 <section>
233 <title>Dependency Handling</title> 245 <title>Dependency Handling</title>
@@ -270,7 +282,7 @@ of the event and the content of the <varname>FILE</varname> variable.</para>
270 <section> 282 <section>
271 <title>Configuration Files</title> 283 <title>Configuration Files</title>
272 <para>The first of the classifications of metadata in BitBake is configuration metadata. This metadata is global, and therefore affects <emphasis>all</emphasis> packages and tasks which are executed.</para> 284 <para>The first of the classifications of metadata in BitBake is configuration metadata. This metadata is global, and therefore affects <emphasis>all</emphasis> packages and tasks which are executed.</para>
273 <papa>Bitbake will first search the current working directory for an optional "conf/bblayers.conf" configuration file. This file is expected to contain a BBLAYERS variable which is a space delimited list of 'layer' directories. For each directory in this list a "conf/layer.conf" file will be searched for and parsed with the LAYERDIR variable being set to the directory where the layer was found. The idea is these files will setup BBPATH and other variables correctly for a given build directory automatically for the user.</para> 285 <para>Bitbake will first search the current working directory for an optional "conf/bblayers.conf" configuration file. This file is expected to contain a BBLAYERS variable which is a space delimited list of 'layer' directories. For each directory in this list a "conf/layer.conf" file will be searched for and parsed with the LAYERDIR variable being set to the directory where the layer was found. The idea is these files will setup BBPATH and other variables correctly for a given build directory automatically for the user.</para>
274 <para>Bitbake will then expect to find 'conf/bitbake.conf' somewhere in the user specified <envar>BBPATH</envar>. That configuration file generally has include directives to pull in any other metadata (generally files specific to architecture, machine, <emphasis>local</emphasis> and so on.</para> 286 <para>Bitbake will then expect to find 'conf/bitbake.conf' somewhere in the user specified <envar>BBPATH</envar>. That configuration file generally has include directives to pull in any other metadata (generally files specific to architecture, machine, <emphasis>local</emphasis> and so on.</para>
275 <para>Only variable definitions and include directives are allowed in .conf files.</para> 287 <para>Only variable definitions and include directives are allowed in .conf files.</para>
276 </section> 288 </section>