From ba6887404aa400bbed125dce3614399e42438f26 Mon Sep 17 00:00:00 2001 From: Scott Rifenbark Date: Wed, 28 Jun 2017 09:20:48 -0700 Subject: documentation: Re-write of dev-manual setup chapter Fixes [YOCTO #11630] The chapter on setting up YP has been completely re-written to move towards a "how-to" manual. This involved touching every aspect of the chapter. All subsections now have procedures surrounding set up stuff. There are some development sections that still need fleshed out. Many, many links and references in other chapters were affected. These have been fixed. A couple style-sheet (*.css) files were also updated to support the "writernotes" style, which renders paragraph text in red. (From yocto-docs rev: c4c2a6cf575ce5c783b1cc84d9f7e961aebef49c) Signed-off-by: Scott Rifenbark Signed-off-by: Richard Purdie --- documentation/bsp-guide/bsp.xml | 2 +- documentation/dev-manual/dev-manual-model.xml | 12 +- documentation/dev-manual/dev-manual-newbie.xml | 2 +- documentation/dev-manual/dev-manual-start.xml | 576 +++++++++++++-------- documentation/mega-manual/mega-manual.xml | 2 +- documentation/mega-manual/mega-style.css | 5 + documentation/ref-manual/introduction.xml | 2 +- .../ref-manual/ref-development-environment.xml | 2 +- documentation/ref-manual/ref-structure.xml | 5 +- .../yocto-project-qs/yocto-project-qs.xml | 4 +- 10 files changed, 383 insertions(+), 229 deletions(-) diff --git a/documentation/bsp-guide/bsp.xml b/documentation/bsp-guide/bsp.xml index 787645324d..50822db2c2 100644 --- a/documentation/bsp-guide/bsp.xml +++ b/documentation/bsp-guide/bsp.xml @@ -87,7 +87,7 @@ section in the Yocto Project Development Manual. For more information on how to set up a local copy of source files from a Git repository, see the - "Getting Set Up" + "Working With Yocto Project Source Files" section also in the Yocto Project Development Manual. diff --git a/documentation/dev-manual/dev-manual-model.xml b/documentation/dev-manual/dev-manual-model.xml index 5c0f5cd851..d2c84eae03 100644 --- a/documentation/dev-manual/dev-manual-model.xml +++ b/documentation/dev-manual/dev-manual-model.xml @@ -130,14 +130,17 @@ process and to the tools you need. For information on how to set up the Source Directory, see the - "Getting Set Up" section. + "Working With Yocto Project Source Files" + section. + Establish the meta-intel repository on your system: Having local copies of these supported BSP layers on your system gives you access to layers you might be able to build on or modify to create your BSP. For information on how to get these files, see the - "Getting Set Up" section. + "Setting Up BSP Layers" section. + Create your own BSP layer using the yocto-bsp script: Layers are ideal for @@ -475,8 +478,9 @@ Source Directory on your system gives you access to the build process and tools you need. - For information on how to get these files, see the bulleted item - "Yocto Project Release" earlier in this manual. + For information on how to get these files, see the + "Cloning the poky Repository" + section. Establish the temporary kernel source files: Temporary kernel source files are kept in the diff --git a/documentation/dev-manual/dev-manual-newbie.xml b/documentation/dev-manual/dev-manual-newbie.xml index 6dfec666be..86561271ba 100644 --- a/documentation/dev-manual/dev-manual-newbie.xml +++ b/documentation/dev-manual/dev-manual-newbie.xml @@ -326,7 +326,7 @@ "Yocto Project Source Repositories" section for information on these repositories. See the - "Getting Set Up" + "Working With Yocto Project Source Files" section for information on how to set up local Git repositories for related upstream Yocto Project Git repositories. diff --git a/documentation/dev-manual/dev-manual-start.xml b/documentation/dev-manual/dev-manual-start.xml index cdb349be3a..e1b2e5d4c7 100644 --- a/documentation/dev-manual/dev-manual-start.xml +++ b/documentation/dev-manual/dev-manual-start.xml @@ -14,236 +14,354 @@ Yocto Project Quick Start. -
- Getting Set Up +
+ Setting Up the Development Host to Use the Yocto Project - Here is what you need to use the Yocto Project: - - Host System: You should have a reasonably current - Linux-based host system. - You will have the best results with a recent release of Fedora, - openSUSE, Debian, Ubuntu, or CentOS as these releases are frequently tested against the Yocto Project - and officially supported. - For a list of the distributions under validation and their status, see the - "Supported Linux Distributions" section - in the Yocto Project Reference Manual and the wiki page at - Distribution Support. - - You should also have about 50 Gbytes of free disk space for building images. - - Packages: The OpenEmbedded build system - requires that certain packages exist on your development system (e.g. Python 2.7). - See "The Build Host Packages" - section in the Yocto Project Quick Start and the - "Required Packages for the Host Development System" - section in the Yocto Project Reference Manual for the exact - package requirements and the installation commands to install - them for the supported distributions. - - Yocto Project Release: - You need a release of the Yocto Project locally installed on - your development system. - The documentation refers to this set of locally installed files - as the Source Directory. - You create your Source Directory by using - Git to clone a local copy - of the upstream poky repository, - or by downloading and unpacking a tarball of an official - Yocto Project release. - The preferred method is to create a clone of the repository. - - Working from a copy of the upstream repository allows you - to contribute back into the Yocto Project or simply work with - the latest software on a development branch. - Because Git maintains and creates an upstream repository with - a complete history of changes and you are working with a local - clone of that repository, you have access to all the Yocto - Project development branches and tag names used in the upstream - repository. - You can view the Yocto Project Source Repositories at - + This section provides procedures to set up your development host to + use the Yocto Project. + For a Linux system to use the Yocto Project, you need to be sure + you are running a supported Linux distribution and have the proper + host packages installed. + If you are using + CROPS + that leverages + Docker Containers, + host setup differs from that of a native Linux machine. + + +
+ Setting Up a Native Linux Host + + + Need text - Following is some basics for a Linux host system. + This information needs to be worked in. + + + + Setup consists of making sure you have a supported operating system, + installing host packages, and Here is what you need to use the Yocto Project: + + + Host System: + You should have a reasonably current Linux-based host + system. + You will have the best results with a recent release of + Fedora, openSUSE, Debian, Ubuntu, or CentOS as these + releases are frequently tested against the Yocto Project + and officially supported. + For a list of the distributions under validation and their + status, see the + "Supported Linux Distributions" section + in the Yocto Project Reference Manual and the wiki page at + Distribution Support. + + You should also have about 50 Gbytes of free disk space + for building images. + + + Packages: + The OpenEmbedded build system requires that certain + packages exist on your development system + (e.g. Python 2.7). + See the + "Build Host Packages" + section in the Yocto Project Quick Start and the + "Required Packages for the Host Development System" + section in the Yocto Project Reference Manual for the + exact package requirements and the installation commands + to install them for the supported distributions. + + + +
+ +
+ Setting Up to Use CROPS + + + Need text. + With CROPS, not sure what the basic package requirements are. + Need to find this out. + +
+ +
+ Setting Up BSP Layers + + + This section describes how to set up a layer for a Board Support + Package (BSP). + For structural information on BSPs, see the + Yocto Project Board Support Package (BSP) Developer's Guide. + + + Determine the BSP Layer You Want: + The Yocto Project supports many BSPs, which are maintained in + their own layers or in layers designed to contain several + BSPs. + To get an idea of machine support through BSP layers, you can + look at the + index of machines + for the release. + + The Yocto Project uses the following BSP layer naming + scheme: + + meta-bsp_name + + where bsp_name is the recognized + BSP name. + Here is an example: + + meta-raspberrypi + + See the + "BSP Layers" + section in the Yocto Project Board Support Package (BSP) + Developer's Guide for more information on BSP Layers. + + + + Optionally Set Up the meta-intel BSP Layer: + If your hardware is based on current Intel CPUs and devices, + you can leverage this BSP layer. + For details on the meta-intel BSP layer, + see the layer's + README + file. + + + Navigate to Your Source Directory: + Typically, you set up the + meta-intel Git repository + inside the + Source Directory + (e.g. poky). + + + Clone the Layer: + + $ git clone git://git.yoctoproject.org/meta-intel.git + Cloning into 'meta-intel'... + remote: Counting objects: 14224, done. + remote: Compressing objects: 100% (4591/4591), done. + remote: Total 14224 (delta 8245), reused 13985 (delta 8006) + Receiving objects: 100% (14224/14224), 4.29 MiB | 2.90 MiB/s, done. + Resolving deltas: 100% (8245/8245), done. + Checking connectivity... done. + + + + Check Out the Proper Branch: + The branch you check out for + meta-intel must match the same + branch you are using for the Yocto Project release + (e.g. &DISTRO_NAME_NO_CAP;): + + $ git checkout branch_name + + For an example on how to discover branch names and + checkout on a branch, see the + "Checking Out By Branch in Poky" + section. + + + + + Optionally Set Up an Alternative BSP Layer: + If your hardware can be more closely leveraged to an + existing BSP not within the meta-intel + BSP layer, you can clone that BSP layer. + + The process is identical to the process used for the + meta-intel layer except for the layer's + name. + For example, if you determine that your hardware most + closely matches the meta-minnow, + clone that layer: + + $ git clone git://git.yoctoproject.org/meta-minnow + Cloning into 'meta-minnow'... + remote: Counting objects: 456, done. + remote: Compressing objects: 100% (283/283), done. + remote: Total 456 (delta 163), reused 384 (delta 91) + Receiving objects: 100% (456/456), 96.74 KiB | 0 bytes/s, done. + Resolving deltas: 100% (163/163), done. + Checking connectivity... done. + + + + +
+ +
+ Setting Up to Work on a Kernel + + + Kernel development is best accomplished using the + devtool tool and not through traditional + kernel workflow methods. + This section provides procedures for both. + + +
+ Getting Ready to Develop using <filename>devtool</filename> + + + Need the updated wiki stuff here + +
+ +
+ Getting Ready for Traditional Kernel Development + + + For traditional kernel development using the Yocto + Project, you need to establish local copies of the + kernel source. + You can find Git repositories of supported Yocto Project + kernels organized under "Yocto Linux Kernel" in the Yocto + Project Source Repositories at + . + + + + This setup can involve creating a bare clone of the + Yocto Project kernel and then copying that cloned + repository. + You can create the bare clone and the copy of the bare + clone anywhere you like. + For simplicity, it is recommended that you create these + structures outside of the + Source Directory, + which is usually named poky. + + + + The following steps show how to create a bare clone of the + linux-yocto-4.4 kernel and then + create a copy of that clone: + + When you have a local Yocto Project kernel Git + repository, you can reference that repository rather than + the upstream Git repository as part of the + clone command. + Doing so can speed up the process. - The following transcript shows how to clone the - poky Git repository into the current - working directory. - The command creates the local repository in a directory - named poky. - For information on Git used within the Yocto Project, see - the "Git" section. - - $ git clone git://git.yoctoproject.org/poky - Cloning into 'poky'... - remote: Counting objects: 226790, done. - remote: Compressing objects: 100% (57465/57465), done. - remote: Total 226790 (delta 165212), reused 225887 (delta 164327) - Receiving objects: 100% (226790/226790), 100.98 MiB | 263 KiB/s, done. - Resolving deltas: 100% (165212/165212), done. - - For another example of how to set up your own local Git - repositories, see this - - wiki page, which describes how to create local - Git repositories for both - poky and meta-intel. - - - You can also get the Yocto Project Files by downloading - Yocto Project releases from the - Yocto Project website. - From the website, you just click "Downloads" in the navigation - pane to the left to display all Yocto Project downloads. - Current and archived releases are available for download. - Nightly and developmental builds are also maintained at - . - One final site you can visit for information on Yocto Project - releases is the - Releases - wiki. - - Yocto Project Kernel: - If you are going to be making modifications to a supported Yocto Project kernel, you - need to establish local copies of the source. - You can find Git repositories of supported Yocto Project kernels organized under - "Yocto Linux Kernel" in the Yocto Project Source Repositories at - . - This setup can involve creating a bare clone of the Yocto Project kernel and then - copying that cloned repository. - You can create the bare clone and the copy of the bare clone anywhere you like. - For simplicity, it is recommended that you create these structures outside of the - Source Directory, which is usually named poky. - As an example, the following transcript shows how to create the bare clone - of the linux-yocto-3.19 kernel and then create a copy of - that clone. - When you have a local Yocto Project kernel Git repository, you can - reference that repository rather than the upstream Git repository as - part of the clone command. - Doing so can speed up the process. - In the following example, the bare clone is named - linux-yocto-3.19.git, while the - copy is named my-linux-yocto-3.19-work: - - $ git clone --bare git://git.yoctoproject.org/linux-yocto-3.19 linux-yocto-3.19.git - Cloning into bare repository 'linux-yocto-3.19.git'... - remote: Counting objects: 3983256, done. - remote: Compressing objects: 100% (605006/605006), done. - remote: Total 3983256 (delta 3352832), reused 3974503 (delta 3344079) - Receiving objects: 100% (3983256/3983256), 843.66 MiB | 1.07 MiB/s, done. - Resolving deltas: 100% (3352832/3352832), done. + + + Create the Bare Clone: + In the following example, the bare clone is named + linux-yocto-4.4.git: + + $ git clone ‐‐bare git://git.yoctoproject.org/linux-yocto-4.4 linux-yocto-4.4.git + Cloning into bare repository 'linux-yocto-4.4.git'... + remote: Counting objects: 4543903, done. + remote: Compressing objects: 100% (695618/695618), done. + remote: Total 4543903 (delta 3818435), reused 4541724 (delta 3816256) + Receiving objects: 100% (4543903/4543903), 801.08 MiB | 6.55 MiB/s, done. + Resolving deltas: 100% (3818435/3818435), done. Checking connectivity... done. - - Now create a clone of the bare clone just created: - - $ git clone linux-yocto-3.19.git my-linux-yocto-3.19-work - Cloning into 'my-linux-yocto-3.19-work'... + + + + Create the Copy of the Bare Clone: + In the following command, the copy of the bare clone + is named my-linux-yocto-4.4-work: + + $ git clone linux-yocto-4.4.git my-linux-yocto-4.4-work + Cloning into 'my-linux-yocto-4.4-work'... done. - Checking out files: 100% (48440/48440), done. - - - The meta-yocto-kernel-extras Git Repository: - The meta-yocto-kernel-extras Git repository contains Metadata needed - only if you are modifying and building the kernel image. - In particular, it contains the kernel BitBake append (.bbappend) - files that you - edit to point to your locally modified kernel source files and to build the kernel - image. - Pointing to these local files is much more efficient than requiring a download of the - kernel's source files from upstream each time you make changes to the kernel. - You can find the meta-yocto-kernel-extras Git Repository in the - "Yocto Metadata Layers" area of the Yocto Project Source Repositories at - . - It is good practice to create this Git repository inside the Source Directory. - Following is an example that creates the meta-yocto-kernel-extras Git - repository inside the Source Directory, which is named poky - in this case: - + Checking out files: 100% (52221/52221), done. + + + + Cloning the meta-yocto-kernel-extras Repository: + The meta-yocto-kernel-extras Git + repository contains Metadata needed only if you are + modifying and building the kernel image. + In particular, it contains the kernel BitBake append + (.bbappend) files that you edit to + point to your locally modified kernel source files and to + build the kernel image. + Pointing to these local files is much more efficient than + requiring a download of the kernel's source files from + upstream each time you make changes to the kernel. + + You can find the + meta-yocto-kernel-extras Git + Repository in the "Yocto Metadata Layers" area of the + Yocto Project Source Repositories at + . + It is good practice to create this Git repository + inside the Source Directory. + + Following is an example that creates the + meta-yocto-kernel-extras Git + repository inside the Source Directory, which is named + poky, in this case: + $ cd ~/poky $ git clone git://git.yoctoproject.org/meta-yocto-kernel-extras meta-yocto-kernel-extras Cloning into 'meta-yocto-kernel-extras'... remote: Counting objects: 727, done. remote: Compressing objects: 100% (452/452), done. remote: Total 727 (delta 260), reused 719 (delta 252) - Receiving objects: 100% (727/727), 536.36 KiB | 240 KiB/s, done. + Receiving objects: 100% (727/727), 536.36 KiB | 0 bytes/s, done. Resolving deltas: 100% (260/260), done. - - Supported Board Support Packages (BSPs): - The Yocto Project supports many BSPs, which are maintained in - their own layers or in layers designed to contain several - BSPs. - To get an idea of machine support through BSP layers, you can - look at the - index of machines - for the release. - - The Yocto Project uses the following BSP layer naming - scheme: - - meta-bsp_name - - where bsp_name is the recognized - BSP name. - Here is an example: - - meta-raspberrypi - - See the - "BSP Layers" - section in the Yocto Project Board Support Package (BSP) - Developer's Guide for more information on BSP Layers. - - A useful Git repository released with the Yocto - Project is meta-intel, which is a - parent layer that contains many supported - BSP Layers. - You can locate the meta-intel Git - repository in the "Yocto Metadata Layers" area of the Yocto - Project Source Repositories at - . - - Using - Git to create a local clone of the - upstream repository can be helpful if you are working with - BSPs. - Typically, you set up the meta-intel - Git repository inside the Source Directory. - For example, the following transcript shows the steps to clone - meta-intel. - - Be sure to work in the meta-intel - branch that matches your - Source Directory - (i.e. poky) branch. - For example, if you have checked out the "master" branch - of poky and you are going to use - meta-intel, be sure to checkout the - "master" branch of meta-intel. - - - $ cd ~/poky - $ git clone git://git.yoctoproject.org/meta-intel.git - Cloning into 'meta-intel'... - remote: Counting objects: 11917, done. - remote: Compressing objects: 100% (3842/3842), done. - remote: Total 11917 (delta 6840), reused 11699 (delta 6622) - Receiving objects: 100% (11917/11917), 2.92 MiB | 2.88 MiB/s, done. - Resolving deltas: 100% (6840/6840), done. Checking connectivity... done. - + + + + +
+
- The same - wiki page - referenced earlier covers how to set up the - meta-intel Git repository. - - Eclipse Yocto Plug-in: If you are developing - applications using the Eclipse Integrated Development Environment (IDE), - you will need this plug-in. - See the - "Using Eclipse" - section in the Yocto Project Software Development Kit (SDK) - Developer's Guide for more information. - - +
+ Setting Up to Use Eclipse + + + This section presents the steps needed to set up your host if you + are going to be using the popular + Eclipse IDE. + The steps in this procedure are links to sections in the + Yocto Project Software Development Kit (SDK) Developer's Guide + that provide detailed procedures given the Neon version of + Eclipse. + For procedures on the entire development process using + Eclipse, see the + "Developing Applications Using Eclipse" + section in the Yocto Project Software Development Kit (SDK) + Developer's Guide. + + + Install Eclipse: + See the + "Installing the Neon Eclipse IDE" + section. + + + Configure Eclipse: + See the + "Configuring the Neon Eclipse IDE" + section. + + + Configure Eclipse: + See the + "Installing or Accessing the Neon Eclipse Yocto Plug-in" + section. + + + Configure Eclipse: + See the + "Configuring the Neon Eclipse Yocto Plug-in" + section. + + + +
@@ -399,6 +517,32 @@
Cloning the <filename>poky</filename> Repository + + To use the Yocto Project, you need a release of the Yocto Project + locally installed on your development system. + The locally installed set of files is referred to as the + Source Directory + in the Yocto Project documentation. + + + + You create your Source Directory by using + Git to clone a local + copy of the upstream poky repository. + Tip + The preferred method of getting the Yocto Project Source + Directory set up is to clone the repository. + + Working from a copy of the upstream repository allows you + to contribute back into the Yocto Project or simply work with + the latest software on a development branch. + Because Git maintains and creates an upstream repository with + a complete history of changes and you are working with a local + clone of that repository, you have access to all the Yocto + Project development branches and tag names used in the upstream + repository. + + Follow these steps to create a local version of the upstream diff --git a/documentation/mega-manual/mega-manual.xml b/documentation/mega-manual/mega-manual.xml index 1e9c50c2c1..a6fdce5e6c 100644 --- a/documentation/mega-manual/mega-manual.xml +++ b/documentation/mega-manual/mega-manual.xml @@ -214,7 +214,7 @@ xmlns:xi="http://www.w3.org/2003/XInclude" href="../ref-manual/usingpoky.xml"/> + xmlns:xi="http://www.w3.org/2003/XInclude" href="../ref-manual/ref-development-environment.xml"/> diff --git a/documentation/mega-manual/mega-style.css b/documentation/mega-manual/mega-style.css index df71a20a02..cd71eb6425 100644 --- a/documentation/mega-manual/mega-style.css +++ b/documentation/mega-manual/mega-style.css @@ -731,6 +731,11 @@ div.navfooter { } +.writernotes { + color: red; +} + + /*********** / / graphics / / ***********/ diff --git a/documentation/ref-manual/introduction.xml b/documentation/ref-manual/introduction.xml index 473afb53ad..2fad3a93c9 100644 --- a/documentation/ref-manual/introduction.xml +++ b/documentation/ref-manual/introduction.xml @@ -594,7 +594,7 @@ You can set up the Source Directory by cloning a copy of the upstream poky Git repository. For information on how to do this, see the - "Getting Set Up" + "Working With Yocto Project Source Files" section in the Yocto Project Development Manual.
diff --git a/documentation/ref-manual/ref-development-environment.xml b/documentation/ref-manual/ref-development-environment.xml index 6922736d61..d0b1f0f1d3 100644 --- a/documentation/ref-manual/ref-development-environment.xml +++ b/documentation/ref-manual/ref-development-environment.xml @@ -333,7 +333,7 @@ Once you have a local copy of a repository, you can take steps to develop locally. For examples on how to clone Git repositories, see the - "Getting Set Up" + "Working With Yocto Project Source Files" section in the Yocto Project Development Manual. diff --git a/documentation/ref-manual/ref-structure.xml b/documentation/ref-manual/ref-structure.xml index 3b3f0779cd..008b95a36a 100644 --- a/documentation/ref-manual/ref-structure.xml +++ b/documentation/ref-manual/ref-structure.xml @@ -14,8 +14,9 @@ - For information on how to establish a local Source Directory on your development system, see the - "Getting Set Up" + For information on how to establish a local Source Directory on your + development system, see the + "Working With Yocto Project Source Files" section in the Yocto Project Development Manual. diff --git a/documentation/yocto-project-qs/yocto-project-qs.xml b/documentation/yocto-project-qs/yocto-project-qs.xml index 285d326334..58e8a30766 100644 --- a/documentation/yocto-project-qs/yocto-project-qs.xml +++ b/documentation/yocto-project-qs/yocto-project-qs.xml @@ -423,8 +423,8 @@ For more information on getting set up with the Yocto Project release, see the - "Yocto Project Release" - item in the Yocto Project Development Manual. + "Cloning the poky Repository" + section in the Yocto Project Development Manual.
-- cgit v1.2.3-54-g00ecf