summaryrefslogtreecommitdiffstats
path: root/documentation
diff options
context:
space:
mode:
authorScott Rifenbark <srifenbark@gmail.com>2017-10-26 09:04:12 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-10-30 15:55:08 +0000
commitf29cdba71ac93494ea68fdea89dd5fa755694114 (patch)
tree203ca9f297ab84ee97639b8c3980735b52b5da2a /documentation
parent4cbdb705ded70462e4107b3f577aa32958a16035 (diff)
downloadpoky-f29cdba71ac93494ea68fdea89dd5fa755694114.tar.gz
dev-manual, kernel-dev: Replaced yocto-layers with bitbake-layers command
The yocto-layers script is being deprecated in the 2.4 YP release and the preferred script is now bitbake-layers. In particular, the section that talks about creating a general layer was using yocto-layers create. I have replaced it with bitbake-layers create-layer command. The bsp-guide and kernel-dev manual had links that used (in the case of kernel-dev) and referenced yocto-layers. I had to change these to reflect using bitbake-layers create-layers. (From yocto-docs rev: 73ec4d0c8c2c093b7c9df86038d132f0da975273) Signed-off-by: Scott Rifenbark <srifenbark@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'documentation')
-rw-r--r--documentation/bsp-guide/bsp.xml6
-rw-r--r--documentation/dev-manual/dev-manual-common-tasks.xml193
-rw-r--r--documentation/kernel-dev/kernel-dev-common.xml58
3 files changed, 138 insertions, 119 deletions
diff --git a/documentation/bsp-guide/bsp.xml b/documentation/bsp-guide/bsp.xml
index e80c37970a..d7b6f15b26 100644
--- a/documentation/bsp-guide/bsp.xml
+++ b/documentation/bsp-guide/bsp.xml
@@ -1593,10 +1593,10 @@
1593 necessary to create a BSP and perform basic kernel maintenance on that BSP using 1593 necessary to create a BSP and perform basic kernel maintenance on that BSP using
1594 the tools. 1594 the tools.
1595 <note> 1595 <note>
1596 You can also use the <filename>yocto-layer</filename> tool to create 1596 You can also use the <filename>bitbake-layers</filename> script to create
1597 a "generic" layer. 1597 a "generic" layer.
1598 For information on this tool, see the 1598 For information on using this script to create a layer, see the
1599 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-yocto-layer-script'>Creating a General Layer Using the yocto-layer Script</ulink>" 1599 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-bitbake-layers-script'>Creating a General Layer Using the <filename>bitbake-layers</filename> Script</ulink>"
1600 section in the Yocto Project Development Tasks Manual. 1600 section in the Yocto Project Development Tasks Manual.
1601 </note> 1601 </note>
1602 </para> 1602 </para>
diff --git a/documentation/dev-manual/dev-manual-common-tasks.xml b/documentation/dev-manual/dev-manual-common-tasks.xml
index ac82dad0a3..2d6bdf5cd9 100644
--- a/documentation/dev-manual/dev-manual-common-tasks.xml
+++ b/documentation/dev-manual/dev-manual-common-tasks.xml
@@ -108,7 +108,7 @@
108 "<ulink url='&YOCTO_DOCS_BSP_URL;#creating-a-new-bsp-layer-using-the-yocto-bsp-script'>Creating a New BSP Layer Using the yocto-bsp Script</ulink>" 108 "<ulink url='&YOCTO_DOCS_BSP_URL;#creating-a-new-bsp-layer-using-the-yocto-bsp-script'>Creating a New BSP Layer Using the yocto-bsp Script</ulink>"
109 section in the Yocto Project Board Support Package (BSP) 109 section in the Yocto Project Board Support Package (BSP)
110 Developer's Guide and the 110 Developer's Guide and the
111 "<link linkend='creating-a-general-layer-using-the-yocto-layer-script'>Creating a General Layer Using the yocto-layer Script</link>" 111 "<link linkend='creating-a-general-layer-using-the-bitbake-layers-script'>Creating a General Layer Using the <filename>bitbake-layers</filename> Script</link>"
112 section further down in this manual. 112 section further down in this manual.
113 </para> 113 </para>
114 114
@@ -968,122 +968,141 @@
968 </para> 968 </para>
969 </section> 969 </section>
970 970
971 <section id='creating-a-general-layer-using-the-yocto-layer-script'> 971 <section id='creating-a-general-layer-using-the-bitbake-layers-script'>
972 <title>Creating a General Layer Using the yocto-layer Script</title> 972 <title>Creating a General Layer Using the <filename>bitbake-layers</filename> Script</title>
973 973
974 <para> 974 <para>
975 The <filename>yocto-layer</filename> script simplifies 975 The <filename>bitbake-layers</filename> script with the
976 <filename>create-layer</filename> subcommand simplifies
976 creating a new general layer. 977 creating a new general layer.
977 <note> 978 <note><title>Notes</title>
978 For information on BSP layers, see the 979 <itemizedlist>
979 "<ulink url='&YOCTO_DOCS_BSP_URL;#bsp-layers'>BSP Layers</ulink>" 980 <listitem><para>
980 section in the Yocto Project Board Specific (BSP) 981 For information on BSP layers, see the
981 Developer's Guide. 982 "<ulink url='&YOCTO_DOCS_BSP_URL;#bsp-layers'>BSP Layers</ulink>"
983 section in the Yocto Project Board Specific (BSP)
984 Developer's Guide.
985 </para></listitem>
986 <listitem><para>
987 The <filename>bitbake-layers</filename> script
988 replaces the <filename>yocto-layer</filename>
989 script, which is deprecated in the Yocto Project
990 2.4 release.
991 The <filename>yocto-layer</filename> script
992 continues to function as part of the 2.4 release
993 but will be removed post 2.4.
994 </para></listitem>
995 </itemizedlist>
982 </note> 996 </note>
983 The default mode of the script's operation is to prompt you for 997 The default mode of the script's operation with this
984 information needed to generate the layer: 998 subcommand is to create a layer with the following:
985 <itemizedlist> 999 <itemizedlist>
986 <listitem><para>The layer priority. 1000 <listitem><para>A layer priority of 6.
987 </para></listitem> 1001 </para></listitem>
988 <listitem><para>Whether or not to create a sample recipe. 1002 <listitem><para>A <filename>conf</filename>
1003 subdirectory that contains a
1004 <filename>layer.conf</filename> file.
989 </para></listitem> 1005 </para></listitem>
990 <listitem><para>Whether or not to create a sample 1006 <listitem><para>
991 append file. 1007 A <filename>recipes-example</filename> subdirectory
992 </para></listitem> 1008 that contains a further subdirectory named
993 </itemizedlist> 1009 <filename>example</filename>, which contains
994 </para> 1010 an <filename>example.bb</filename> recipe file.
995
996 <para>
997 Use the <filename>yocto-layer create</filename> sub-command
998 to create a new general layer.
999 In its simplest form, you can create a layer as follows:
1000 <literallayout class='monospaced'>
1001 $ yocto-layer create mylayer
1002 </literallayout>
1003 The previous example creates a layer named
1004 <filename>meta-mylayer</filename> in the current directory.
1005 </para>
1006
1007 <para>
1008 As the <filename>yocto-layer create</filename> command runs,
1009 default values for the prompts appear in brackets.
1010 Pressing enter without supplying anything for the prompts
1011 or pressing enter and providing an invalid response causes the
1012 script to accept the default value.
1013 Once the script completes, the new layer
1014 is created in the current working directory.
1015 The script names the layer by prepending
1016 <filename>meta-</filename> to the name you provide.
1017 </para>
1018
1019 <para>
1020 Minimally, the script creates the following within the layer:
1021 <itemizedlist>
1022 <listitem><para><emphasis>The <filename>conf</filename>
1023 directory:</emphasis>
1024 This directory contains the layer's configuration file.
1025 The root name for the file is the same as the root name
1026 your provided for the layer (e.g.
1027 <filename><replaceable>layer</replaceable>.conf</filename>).
1028 </para></listitem> 1011 </para></listitem>
1029 <listitem><para><emphasis>The 1012 <listitem><para>A <filename >COPYING.MIT</filename>,
1030 <filename>COPYING.MIT</filename> file:</emphasis> 1013 which is the license statement for the layer.
1031 The copyright and use notice for the software. 1014 The script assumes you want to use the MIT license,
1015 which is typical for most layers, for the contents of
1016 the layer itself.
1032 </para></listitem> 1017 </para></listitem>
1033 <listitem><para><emphasis>The <filename>README</filename> 1018 <listitem><para>
1034 file:</emphasis> 1019 A <filename>README</filename> file, which is a file
1035 A file describing the contents of your new layer. 1020 describing the contents of your new layer.
1036 </para></listitem> 1021 </para></listitem>
1037 </itemizedlist> 1022 </itemizedlist>
1038 </para> 1023 </para>
1039 1024
1040 <para> 1025 <para>
1041 If you choose to generate a sample recipe file, the script 1026 In its simplest form, you can use the following command form
1042 prompts you for the name for the recipe and then creates it 1027 to create a layer.
1043 in <filename><replaceable>layer</replaceable>/recipes-example/example/</filename>. 1028 The command creates a layer whose name corresponds to
1044 The script creates a <filename>.bb</filename> file and a 1029 <replaceable>your_layer_name</replaceable> in the current
1045 directory, which contains a sample 1030 directory:
1046 <filename>helloworld.c</filename> source file, along with 1031 <literallayout class='monospaced'>
1047 a sample patch file. 1032 $ bitbake-layers create-layer <replaceable>your_layer_name</replaceable>
1048 If you do not provide a recipe name, the script uses 1033 </literallayout>
1049 "example".
1050 </para> 1034 </para>
1051 1035
1052 <para> 1036 <para>
1053 If you choose to generate a sample append file, the script 1037 If you want to set the priority of the layer to other than the
1054 prompts you for the name for the file and then creates it 1038 default value of "6", you can either use the
1055 in <filename><replaceable>layer</replaceable>/recipes-example-bbappend/example-bbappend/</filename>. 1039 <filename>&dash;&dash;priority</filename> option or you can
1056 The script creates a <filename>.bbappend</filename> file and a 1040 edit the
1057 directory, which contains a sample patch file. 1041 <ulink url='&YOCTO_DOCS_REF_URL;#var-BBFILE_PRIORITY'><filename>BBFILE_PRIORITY</filename></ulink>
1058 If you do not provide a recipe name, the script uses 1042 value in the <filename>conf/layer.conf</filename> after the
1059 "example". 1043 script creates it.
1060 The script also prompts you for the version of the append file. 1044 Furthermore, if you want to give the example recipe file
1061 The version should match the recipe to which the append file 1045 some name other than the default, you can
1062 is associated. 1046 use the
1047 <filename>&dash;&dash;example-recipe-name</filename> option.
1063 </para> 1048 </para>
1064 1049
1065 <para> 1050 <para>
1066 The easiest way to see how the <filename>yocto-layer</filename> 1051 The easiest way to see how the
1067 script works is to experiment with the script. 1052 <filename>bitbake-layers create-layer</filename> command
1053 works is to experiment with the script.
1068 You can also read the usage information by entering the 1054 You can also read the usage information by entering the
1069 following: 1055 following:
1070 <literallayout class='monospaced'> 1056 <literallayout class='monospaced'>
1071 $ yocto-layer help 1057 $ bitbake-layers create-layer --help
1058 NOTE: Starting bitbake server...
1059 usage: bitbake-layers create-layer [-h] [--priority PRIORITY]
1060 [--example-recipe-name EXAMPLERECIPE]
1061 layerdir
1062
1063 Create a basic layer
1064
1065 positional arguments:
1066 layerdir Layer directory to create
1067
1068 optional arguments:
1069 -h, --help show this help message and exit
1070 --priority PRIORITY, -p PRIORITY
1071 Layer directory to create
1072 --example-recipe-name EXAMPLERECIPE, -e EXAMPLERECIPE
1073 Filename of the example recipe
1072 </literallayout> 1074 </literallayout>
1073 </para> 1075 </para>
1074 1076
1075 <para> 1077 <para>
1076 Once you create your general layer, you must add it to your 1078 Once you create your general layer, you must add it to your
1077 <filename>bblayers.conf</filename> file. 1079 <filename>bblayers.conf</filename> file.
1080 You can add your layer by using the
1081 <filename>bitbake-layers add-layer</filename> command:
1082 <literallayout class='monospaced'>
1083 $ bitbake-layers add-layer <replaceable>your_layer_name</replaceable>
1084 </literallayout>
1078 Here is an example where a layer named 1085 Here is an example where a layer named
1079 <filename>meta-mylayer</filename> is added: 1086 <filename>meta-scottrif</filename> is added and then the
1087 layers are shown using the
1088 <filename>bitbake-layers show-layers</filename> command:
1080 <literallayout class='monospaced'> 1089 <literallayout class='monospaced'>
1081 BBLAYERS = ?" \ 1090 $ bitbake-layers add-layer meta-scottrif
1082 /usr/local/src/yocto/meta \ 1091 NOTE: Starting bitbake server...
1083 /usr/local/src/yocto/meta-poky \ 1092 Loading cache: 100% |############################################| Time: 0:00:00
1084 /usr/local/src/yocto/meta-yocto-bsp \ 1093 Loaded 1275 entries from dependency cache.
1085 /usr/local/src/yocto/meta-mylayer \ 1094 Parsing recipes: 100% |##########################################| Time: 0:00:00
1086 " 1095 Parsing of 819 .bb files complete (817 cached, 2 parsed). 1276 targets, 44 skipped, 0 masked, 0 errors.
1096 $ bitbake-layers show-layers
1097 NOTE: Starting bitbake server...
1098 layer path priority
1099 ==========================================================================
1100 meta /home/scottrif/poky/meta 5
1101 meta-poky /home/scottrif/poky/meta-poky 5
1102 meta-yocto-bsp /home/scottrif/poky/meta-yocto-bsp 5
1103 meta-mylayer /home/scottrif/meta-mylayer 6
1104 workspace /home/scottrif/poky/build/workspace 99
1105 meta-scottrif /home/scottrif/poky/build/meta-scottrif 6
1087 </literallayout> 1106 </literallayout>
1088 Adding the layer to this file enables the build system to 1107 Adding the layer to this file enables the build system to
1089 locate the layer during the build. 1108 locate the layer during the build.
@@ -6060,7 +6079,7 @@ Some notes from Cal:
6060 configuration file makes it easier to reproduce the same 6079 configuration file makes it easier to reproduce the same
6061 build configuration when using multiple build machines. 6080 build configuration when using multiple build machines.
6062 See the 6081 See the
6063 "<link linkend='creating-a-general-layer-using-the-yocto-layer-script'>Creating a General Layer Using the yocto-layer Script</link>" 6082 "<link linkend='creating-a-general-layer-using-the-bitbake-layers-script'>Creating a General Layer Using the <filename>bitbake-layers</filename> Script</link>"
6064 section for information on how to quickly set up a layer. 6083 section for information on how to quickly set up a layer.
6065 </para></listitem> 6084 </para></listitem>
6066 <listitem><para><emphasis>Create the distribution configuration file:</emphasis> 6085 <listitem><para><emphasis>Create the distribution configuration file:</emphasis>
diff --git a/documentation/kernel-dev/kernel-dev-common.xml b/documentation/kernel-dev/kernel-dev-common.xml
index 3b4428549d..b8fd870162 100644
--- a/documentation/kernel-dev/kernel-dev-common.xml
+++ b/documentation/kernel-dev/kernel-dev-common.xml
@@ -115,18 +115,15 @@
115 <emphasis>Create a Layer for Patches:</emphasis> 115 <emphasis>Create a Layer for Patches:</emphasis>
116 You need to create a layer to hold patches created 116 You need to create a layer to hold patches created
117 for the kernel image. 117 for the kernel image.
118 You can use the <filename>yocto-layer</filename> command 118 You can use the
119 as follows: 119 <filename>bitbake-layers create-layer</filename>
120 command as follows:
120 <literallayout class='monospaced'> 121 <literallayout class='monospaced'>
121 $ cd ~/poky 122 $ cd ~/poky/build
122 $ yocto-layer create mylayer -o ../meta-mylayer 123 $ bitbake-layers create-layer ../../meta-mylayer
123 Please enter the layer priority you'd like to use for the layer: [default: 6] 124 NOTE: Starting bitbake server...
124 Would you like to have an example recipe created? (y/n) [default: n] 125 Add your new layer with 'bitbake-layers add-layer ../../meta-mylayer'
125 Would you like to have an example bbappend file created? (y/n) [default: n] 126 $
126
127 New layer created in ../meta-mylayer.
128
129 Don't forget to add it to your BBLAYERS (for details see ../meta-mylayer/README).
130 </literallayout> 127 </literallayout>
131 <note> 128 <note>
132 For background information on working with 129 For background information on working with
@@ -138,8 +135,9 @@
138 section in the Yocto Project Board Support (BSP) 135 section in the Yocto Project Board Support (BSP)
139 Developer's Guide, respectively. 136 Developer's Guide, respectively.
140 For information on how to use the 137 For information on how to use the
141 <filename>yocto-layer</filename> script, see the 138 <filename>bitbake-layers create-layer</filename>
142 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-yocto-layer-script'>Creating a General Layer Using the yocto-layer Script</ulink>" 139 command, see the
140 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-bitbake-layers-script'>Creating a General Layer Using the <filename>bitbake-layers</filename> Script</ulink>"
143 section in the Yocto Project Development Tasks 141 section in the Yocto Project Development Tasks
144 Manual. 142 Manual.
145 </note> 143 </note>
@@ -155,6 +153,8 @@
155 <literallayout class='monospaced'> 153 <literallayout class='monospaced'>
156 $ cd ~/poky/build 154 $ cd ~/poky/build
157 $ bitbake-layers add-layer ../../meta-mylayer 155 $ bitbake-layers add-layer ../../meta-mylayer
156 NOTE: Starting bitbake server...
157 $
158 </literallayout> 158 </literallayout>
159 </para></listitem> 159 </para></listitem>
160 <listitem><para> 160 <listitem><para>
@@ -340,18 +340,14 @@
340 <emphasis>Create a Layer for Patches:</emphasis> 340 <emphasis>Create a Layer for Patches:</emphasis>
341 You need to create a layer to hold patches created 341 You need to create a layer to hold patches created
342 for the kernel image. 342 for the kernel image.
343 You can use the <filename>yocto-layer</filename> command 343 You can use the
344 as follows: 344 <filename>bitbake-layers create-layer</filename>
345 command as follows:
345 <literallayout class='monospaced'> 346 <literallayout class='monospaced'>
346 $ cd ~/poky 347 $ cd ~/poky/build
347 $ yocto-layer create mylayer -o ../meta-mylayer 348 $ bitbake-layers create-layer ../../meta-mylayer
348 Please enter the layer priority you'd like to use for the layer: [default: 6] 349 NOTE: Starting bitbake server...
349 Would you like to have an example recipe created? (y/n) [default: n] 350 Add your new layer with 'bitbake-layers add-layer ../../meta-mylayer'
350 Would you like to have an example bbappend file created? (y/n) [default: n]
351
352 New layer created in ../meta-mylayer.
353
354 Don't forget to add it to your BBLAYERS (for details see ../meta-mylayer/README).
355 </literallayout> 351 </literallayout>
356 <note> 352 <note>
357 For background information on working with 353 For background information on working with
@@ -363,8 +359,9 @@
363 section in the Yocto Project Board Support (BSP) 359 section in the Yocto Project Board Support (BSP)
364 Developer's Guide, respectively. 360 Developer's Guide, respectively.
365 For information on how to use the 361 For information on how to use the
366 <filename>yocto-layer</filename> script, see the 362 <filename>bitbake-layers create-layer</filename>
367 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-yocto-layer-script'>Creating a General Layer Using the yocto-layer Script</ulink>" 363 command, see the
364 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-bitbake-layers-script'>Creating a General Layer Using the <filename>bitbake-layers</filename> Script</ulink>"
368 section in the Yocto Project Development Tasks 365 section in the Yocto Project Development Tasks
369 Manual. 366 Manual.
370 </note> 367 </note>
@@ -380,6 +377,8 @@
380 <literallayout class='monospaced'> 377 <literallayout class='monospaced'>
381 $ cd ~/poky/build 378 $ cd ~/poky/build
382 $ bitbake-layers add-layer ../../meta-mylayer 379 $ bitbake-layers add-layer ../../meta-mylayer
380 NOTE: Starting bitbake server ...
381 $
383 </literallayout> 382 </literallayout>
384 </para></listitem> 383 </para></listitem>
385 <listitem><para> 384 <listitem><para>
@@ -484,10 +483,11 @@
484 <note><title>Tip</title> 483 <note><title>Tip</title>
485 The Yocto Project comes with many tools that simplify 484 The Yocto Project comes with many tools that simplify
486 tasks you need to perform. 485 tasks you need to perform.
487 One such tool is the <filename>yocto-layer create</filename> 486 One such tool is the
488 script, which simplifies creating a new layer. 487 <filename>bitbake-layers create-layer</filename>
488 command, which simplifies creating a new layer.
489 See the 489 See the
490 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-yocto-layer-script'>Creating a General Layer Using the yocto-layer Script</ulink>" 490 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-general-layer-using-the-bitbake-layers-script'>Creating a General Layer Using the <filename>bitbake-layers</filename> Script</ulink>"
491 section in the Yocto Project Development Tasks Manual for 491 section in the Yocto Project Development Tasks Manual for
492 information on how to use this script. 492 information on how to use this script.
493 </note> 493 </note>