summaryrefslogtreecommitdiff
path: root/poky/documentation/kernel-dev/common.rst
diff options
context:
space:
mode:
Diffstat (limited to 'poky/documentation/kernel-dev/common.rst')
-rw-r--r--poky/documentation/kernel-dev/common.rst93
1 files changed, 45 insertions, 48 deletions
diff --git a/poky/documentation/kernel-dev/common.rst b/poky/documentation/kernel-dev/common.rst
index 58adcc9b7..56217b9d3 100644
--- a/poky/documentation/kernel-dev/common.rst
+++ b/poky/documentation/kernel-dev/common.rst
@@ -57,7 +57,7 @@ section:
the build environment script (i.e. :ref:`structure-core-script`):
::
- $ cd ~/poky
+ $ cd poky
$ source oe-init-build-env
.. note::
@@ -74,7 +74,7 @@ section:
``MACHINE`` variable appropriately in your ``conf/local.conf`` file
found in the
:term:`Build Directory` (i.e.
- ``~/poky/build`` in this example).
+ ``poky/build`` in this example).
Also, since you are preparing to work on the kernel image, you need
to set the
@@ -94,7 +94,7 @@ section:
``bitbake-layers create-layer`` command as follows:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake-layers create-layer ../../meta-mylayer
NOTE: Starting bitbake server...
Add your new layer with 'bitbake-layers add-layer ../../meta-mylayer'
@@ -119,7 +119,7 @@ section:
``bblayers.conf`` file as follows:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake-layers add-layer ../../meta-mylayer
NOTE: Starting bitbake server...
$
@@ -128,7 +128,7 @@ section:
specifically for use with images to be run using QEMU:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake core-image-minimal -c populate_sdk_ext
Once
@@ -136,21 +136,21 @@ section:
``*.sh`` file) in the following directory:
::
- ~/poky/build/tmp/deploy/sdk
+ poky/build/tmp/deploy/sdk
For this example, the installer file is named
``poky-glibc-x86_64-core-image-minimal-i586-toolchain-ext-&DISTRO;.sh``.
6. *Install the Extensible SDK:* Use the following command to install
the SDK. For this example, install the SDK in the default
- ``~/poky_sdk`` directory:
+ ``poky_sdk`` directory:
::
- $ cd ~/poky/build/tmp/deploy/sdk
+ $ cd poky/build/tmp/deploy/sdk
$ ./poky-glibc-x86_64-core-image-minimal-i586-toolchain-ext-&DISTRO;.sh
Poky (Yocto Project Reference Distro) Extensible SDK installer version &DISTRO;
============================================================================
- Enter target directory for SDK (default: ~/poky_sdk):
+ Enter target directory for SDK (default: poky_sdk):
You are about to install the SDK to "/home/scottrif/poky_sdk". Proceed [Y/n]? Y
Extracting SDK......................................done
Setting it up...
@@ -175,7 +175,7 @@ section:
directed by the output from installing the SDK:
::
- $ source ~/poky_sdk/environment-setup-i586-poky-linux
+ $ source poky_sdk/environment-setup-i586-poky-linux
"SDK environment now set up; additionally you may now run devtool to perform development tasks.
Run devtool --help for further details.
@@ -240,7 +240,7 @@ section:
section in the Yocto Project Development Tasks Manual.
::
- $ cd ~/poky
+ $ cd poky
$ git branch
master
* &DISTRO_NAME_NO_CAP;
@@ -260,7 +260,7 @@ section:
``MACHINE`` variable appropriately in your ``conf/local.conf`` file
found in the
:term:`Build Directory` (i.e.
- ``~/poky/build`` in this example).
+ ``poky/build`` in this example).
Also, since you are preparing to work on the kernel image, you need
to set the
@@ -280,7 +280,7 @@ section:
``bitbake-layers create-layer`` command as follows:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake-layers create-layer ../../meta-mylayer
NOTE: Starting bitbake server...
Add your new layer with 'bitbake-layers add-layer ../../meta-mylayer'
@@ -304,7 +304,7 @@ section:
``bblayers.conf`` file as follows:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake-layers add-layer ../../meta-mylayer
NOTE: Starting bitbake server ...
$
@@ -365,8 +365,7 @@ section:
At this point, you are ready to start making modifications to the kernel
using traditional kernel development steps. For a continued example, see
-the "`Using Traditional Kernel Development to Patch the
-Kernel <#using-traditional-kernel-development-to-patch-the-kernel>`__"
+the ":ref:`kernel-dev/common:using traditional kernel development to patch the kernel`"
section.
Creating and Preparing a Layer
@@ -398,7 +397,6 @@ home directory:
1. *Create Structure*: Create the layer's structure:
::
- $ cd $HOME
$ mkdir meta-mylayer
$ mkdir meta-mylayer/conf
$ mkdir meta-mylayer/recipes-kernel
@@ -464,8 +462,8 @@ Modifying an existing recipe can consist of the following:
- :ref:`kernel-dev/common:changing the configuration`
Before modifying an existing recipe, be sure that you have created a
-minimal, custom layer from which you can work. See the "`Creating and
-Preparing a Layer <#creating-and-preparing-a-layer>`__" section for
+minimal, custom layer from which you can work. See the
+":ref:`kernel-dev/common:creating and preparing a layer`" section for
information.
Creating the Append File
@@ -711,7 +709,7 @@ Linux kernel, BitBake detects the change in the recipe and fetches and
applies the new configuration before building the kernel.
For a detailed example showing how to configure the kernel, see the
-"`Configuring the Kernel <#configuring-the-kernel>`__" section.
+":ref:`kernel-dev/common:configuring the kernel`" section.
Using an "In-Tree"  ``defconfig`` File
--------------------------------------
@@ -819,12 +817,12 @@ the ":ref:`kernel-dev/common:getting ready to develop using \`\`devtool\`\``" Se
1. *Change the working directory*: In the previous step, the output
noted where you can find the source files (e.g.
- ``~/poky_sdk/workspace/sources/linux-yocto``). Change to where the
+ ``poky_sdk/workspace/sources/linux-yocto``). Change to where the
kernel source code is before making your edits to the
``calibrate.c`` file:
::
- $ cd ~/poky_sdk/workspace/sources/linux-yocto
+ $ cd poky_sdk/workspace/sources/linux-yocto
2. *Edit the source file*: Edit the ``init/calibrate.c`` file to have
the following changes:
@@ -896,7 +894,7 @@ the ":ref:`kernel-dev/common:getting ready to develop using \`\`devtool\`\``" Se
and use these Git commands to stage and commit your changes:
::
- $ cd ~/poky_sdk/workspace/sources/linux-yocto
+ $ cd poky_sdk/workspace/sources/linux-yocto
$ git status
$ git add init/calibrate.c
$ git commit -m "calibrate: Add printk example"
@@ -926,7 +924,7 @@ the ":ref:`kernel-dev/common:getting ready to develop using \`\`devtool\`\``" Se
set up to run BitBake:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake core-image-minimal
Using Traditional Kernel Development to Patch the Kernel
@@ -955,15 +953,14 @@ emulator console output at boot time through ``printk`` statements in
the kernel's ``calibrate.c`` source code file. Applying the patch and
booting the modified image causes the added messages to appear on the
emulator's console. The example is a continuation of the setup procedure
-found in the "`Getting Ready for Traditional Kernel
-Development <#getting-ready-for-traditional-kernel-development>`__"
+found in the
+":ref:`kernel-dev/common:getting ready for traditional kernel development`"
Section.
1. *Edit the Source Files* Prior to this step, you should have used Git
to create a local copy of the repository for your kernel. Assuming
- you created the repository as directed in the "`Getting Ready for
- Traditional Kernel
- Development <#getting-ready-for-traditional-kernel-development>`__"
+ you created the repository as directed in the
+ ":ref:`kernel-dev/common:getting ready for traditional kernel development`"
section, use the following commands to edit the ``calibrate.c`` file:
1. *Change the working directory*: You need to locate the source
@@ -1015,7 +1012,7 @@ Section.
to the following to your ``local.conf``:
::
- $ cd ~/poky/build/conf
+ $ cd poky/build/conf
Add the following to the ``local.conf``:
::
@@ -1037,7 +1034,7 @@ Section.
you can now use BitBake to build the image:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake core-image-minimal
5. *Boot the image*: Boot the modified image in the QEMU emulator using
@@ -1045,7 +1042,7 @@ Section.
with no password:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ runqemu qemux86
6. *Look for Your Changes:* As QEMU booted, you might have seen your
@@ -1105,9 +1102,9 @@ Section.
The :term:`FILESEXTRAPATHS` and :term:`SRC_URI` statements
enable the OpenEmbedded build system to find the patch file.
- For more information on append files and patches, see the "`Creating
- the Append File <#creating-the-append-file>`__" and "`Applying
- Patches <#applying-patches>`__" sections. You can also see the
+ For more information on append files and patches, see the
+ ":ref:`kernel-dev/common:creating the append file`" and
+ ":ref:`kernel-dev/common:applying patches`" sections. You can also see the
":ref:`dev-manual/common-tasks:using .bbappend files in your layer`"
section in the Yocto Project Development Tasks Manual.
@@ -1119,7 +1116,7 @@ Section.
the following sequence of commands:
::
- $ cd ~/poky/build
+ $ cd poky/build
$ bitbake -c cleanall yocto-linux
$ bitbake core-image-minimal -c cleanall
$ bitbake core-image-minimal
@@ -1141,8 +1138,8 @@ configuration fragments, and how to interactively modify your
``.config`` file to create the leanest kernel configuration file
possible.
-For more information on kernel configuration, see the "`Changing the
-Configuration <#changing-the-configuration>`__" section.
+For more information on kernel configuration, see the
+":ref:`kernel-dev/common:changing the configuration`" section.
Using  ``menuconfig``
---------------------
@@ -1172,7 +1169,7 @@ environment, you must do the following:
The following commands initialize the BitBake environment, run the
:ref:`ref-tasks-kernel_configme`
task, and launch ``menuconfig``. These commands assume the Source
-Directory's top-level folder is ``~/poky``:
+Directory's top-level folder is ``poky``:
::
$ cd poky
@@ -1298,8 +1295,8 @@ created to hold the configuration changes.
applies these on top of and after applying the existing ``defconfig`` file
configurations.
-For more information on configuring the kernel, see the "`Changing the
-Configuration <#changing-the-configuration>`__" section.
+For more information on configuring the kernel, see the
+":ref:`kernel-dev/common:changing the configuration`" section.
Creating Configuration Fragments
--------------------------------
@@ -1370,8 +1367,8 @@ steps:
$ bitbake linux-yocto -c diffconfig
The ``diffconfig`` command creates a file that is a list of Linux kernel
-``CONFIG_`` assignments. See the "`Changing the
-Configuration <#changing-the-configuration>`__" section for additional
+``CONFIG_`` assignments. See the
+":ref:`kernel-dev/common:changing the configuration`" section for additional
information on how to use the output as a configuration fragment.
.. note::
@@ -1615,8 +1612,7 @@ source directory. Follow these steps to clean up the version string:
":ref:`kernel-dev/common:using \`\`devtool\`\` to patch the kernel`"
section. For
information on building the kernel image when using Bitbake, see the
- "`Using Traditional Kernel Development to Patch the
- Kernel <#using-traditional-kernel-development-to-patch-the-kernel>`__"
+ ":ref:`kernel-dev/common:using traditional kernel development to patch the kernel`"
section.
Working With Your Own Sources
@@ -1734,8 +1730,9 @@ Here are some basic steps you can use to work with your own sources:
5. *Customize Your Recipe as Needed:* Provide further customizations to
your recipe as needed just as you would customize an existing
- linux-yocto recipe. See the "`Modifying an Existing
- Recipe <#modifying-an-existing-recipe>`__" section for information.
+ linux-yocto recipe. See the
+ ":ref:`ref-manual/devtool-reference:modifying an existing recipe`" section
+ for information.
Working with Out-of-Tree Modules
================================
@@ -1915,7 +1912,7 @@ differences:
$ git show origin/standard/base..origin/standard/emenlow
Use this command to create individual patches for each change. Here is
-an example that that creates patch files for each commit and places them
+an example that creates patch files for each commit and places them
in your ``Documents`` directory:
::