summaryrefslogtreecommitdiffstats
path: root/documentation
diff options
context:
space:
mode:
Diffstat (limited to 'documentation')
-rw-r--r--documentation/adt-manual/adt-command.xml13
-rw-r--r--documentation/adt-manual/adt-intro.xml108
-rw-r--r--documentation/adt-manual/adt-package.xml52
-rw-r--r--documentation/adt-manual/adt-prepare.xml351
4 files changed, 277 insertions, 247 deletions
diff --git a/documentation/adt-manual/adt-command.xml b/documentation/adt-manual/adt-command.xml
index e647a374a8..96b779c3b7 100644
--- a/documentation/adt-manual/adt-command.xml
+++ b/documentation/adt-manual/adt-command.xml
@@ -3,12 +3,13 @@
3 3
4<chapter id='using-the-command-line'> 4<chapter id='using-the-command-line'>
5<title>Using the Command Line</title> 5<title>Using the Command Line</title>
6
6 <para> 7 <para>
7 Recall that earlier we talked about how to use an existing toolchain 8 Recall that earlier the manual discussed how to use an existing toolchain
8 tarball that had been installed into <filename>/opt/poky</filename>, 9 tarball that had been installed into <filename>/opt/poky</filename>,
9 which is outside of the Yocto Project build tree 10 which is outside of the Yocto Project build tree
10 (see <xref linkend='using-an-existing-toolchain-tarball'> 11 (see the section "<link linkend='using-an-existing-toolchain-tarball'>Using an Existing
11 Using an Existing Toolchain Tarball)</xref>. 12 Toolchain Tarball)</link>".
12 And, that sourcing your architecture-specific environment setup script 13 And, that sourcing your architecture-specific environment setup script
13 initializes a suitable cross-toolchain development environment. 14 initializes a suitable cross-toolchain development environment.
14 This setup occurs by adding the compiler, QEMU scripts, QEMU binary, 15 This setup occurs by adding the compiler, QEMU scripts, QEMU binary,
@@ -20,11 +21,12 @@
20 test results for tests that need target hardware on which to run. 21 test results for tests that need target hardware on which to run.
21 These conditions allow you to easily use the toolchain outside of the 22 These conditions allow you to easily use the toolchain outside of the
22 Yocto Project build environment on both autotools-based projects and 23 Yocto Project build environment on both autotools-based projects and
23 makefile-based projects. 24 Makefile-based projects.
24 </para> 25 </para>
25 26
26<section id='autotools-based-projects'> 27<section id='autotools-based-projects'>
27<title>Autotools-Based Projects</title> 28<title>Autotools-Based Projects</title>
29
28 <para> 30 <para>
29 For an autotools-based project, you can use the cross-toolchain by just 31 For an autotools-based project, you can use the cross-toolchain by just
30 passing the appropriate host option to <filename>configure.sh</filename>. 32 passing the appropriate host option to <filename>configure.sh</filename>.
@@ -49,8 +51,9 @@
49 51
50<section id='makefile-based-projects'> 52<section id='makefile-based-projects'>
51<title>Makefile-Based Projects</title> 53<title>Makefile-Based Projects</title>
54
52 <para> 55 <para>
53 For a makefile-based project you use the cross-toolchain by making sure 56 For a Makefile-based project, you use the cross-toolchain by making sure
54 the tools are used. 57 the tools are used.
55 You can do this as follows: 58 You can do this as follows:
56 <literallayout class='monospaced'> 59 <literallayout class='monospaced'>
diff --git a/documentation/adt-manual/adt-intro.xml b/documentation/adt-manual/adt-intro.xml
index 220eb4b54b..211b174dc6 100644
--- a/documentation/adt-manual/adt-intro.xml
+++ b/documentation/adt-manual/adt-intro.xml
@@ -13,29 +13,41 @@
13 13
14<section id='book-intro'> 14<section id='book-intro'>
15 <title>Introducing the Application Development Toolkit (ADT)</title> 15 <title>Introducing the Application Development Toolkit (ADT)</title>
16
16 <para> 17 <para>
17 Fundamentally, the ADT consists of an architecture-specific cross-toolchain and 18 Fundamentally, the ADT consists of an architecture-specific cross-toolchain and
18 a matching sysroot that are both built by the Poky build system. 19 a matching sysroot that are both built by the Yocto Project build system Poky.
19 The toolchain and sysroot are based on a metadata configuration and extensions, 20 The toolchain and sysroot are based on a metadata configuration and extensions,
20 which allows you to cross develop for the target on the host machine. 21 which allows you to cross-develop on the host machine for the target.
21 </para> 22 </para>
23
22 <para> 24 <para>
23 Additionally, to provide an effective development platform, the Yocto Project 25 Additionally, to provide an effective development platform, the Yocto Project
24 makes available and suggests other tools you can use with the ADT. 26 makes available and suggests other tools you can use with the ADT.
25 These other tools include the Eclipse IDE Yocto Plug-in, an emulator (QEMU), 27 These other tools include the Eclipse IDE Yocto Plug-in, an emulator (QEMU),
26 and various user-space tools that greatly enhance your development experience. 28 and various user-space tools that greatly enhance your development experience.
27 </para> 29 </para>
30
28 <para> 31 <para>
29 The resulting combination of the architecture-specific cross-toolchain and sysroot 32 The resulting combination of the architecture-specific cross-toolchain and sysroot
30 along with these additional tools yields a custom-built, cross-development platform 33 along with these additional tools yields a custom-built, cross-development platform
31 for a user-targeted product. 34 for a user-targeted product.
32 </para> 35 </para>
36</section>
37
38<section id='adt-components'>
39 <title>ADT Components</title>
40
41 <para>
42 This section provides a brief description of what comprises the ADT.
43 </para>
33 44
34 <section id='the-cross-toolchain'> 45 <section id='the-cross-toolchain'>
35 <title>The Cross-Toolchain</title> 46 <title>The Cross-Toolchain</title>
47
36 <para> 48 <para>
37 The cross-toolchain consists of a cross-compiler, cross-linker, and cross-debugger 49 The cross-toolchain consists of a cross-compiler, cross-linker, and cross-debugger
38 that are used to develop for targeted hardware. 50 that are used to develop user-space applications for targeted hardware.
39 This toolchain is created either by running the ADT Installer script or 51 This toolchain is created either by running the ADT Installer script or
40 through a Yocto Project build tree that is based on your metadata 52 through a Yocto Project build tree that is based on your metadata
41 configuration or extension for your targeted device. 53 configuration or extension for your targeted device.
@@ -45,80 +57,76 @@
45 57
46 <section id='sysroot'> 58 <section id='sysroot'>
47 <title>Sysroot</title> 59 <title>Sysroot</title>
60
48 <para> 61 <para>
49 The matching target sysroot contains needed headers and libraries for generating 62 The matching target sysroot contains needed headers and libraries for generating
50 binaries that run on the target architecture. 63 binaries that run on the target architecture.
51 The sysroot is based on the target root filesystem image that is built by 64 The sysroot is based on the target root filesystem image that is built by
52 Poky and uses the same metadata configuration used to build the cross-toolchain. 65 the Yocto Project's build system Poky and uses the same metadata configuration
66 used to build the cross-toolchain.
53 </para> 67 </para>
54 </section> 68 </section>
55 69
56 <section id='the-qemu-emulator'> 70 <section id='the-qemu-emulator'>
57 <title>The QEMU Emulator</title> 71 <title>The QEMU Emulator</title>
72
58 <para> 73 <para>
59 The QEMU emulator allows you to simulate your hardware while running your 74 The QEMU emulator allows you to simulate your hardware while running your
60 application or image. 75 application or image.
61 QEMU is made available a number of ways: 76 QEMU is made available a number of ways:
62 <itemizedlist> 77 <itemizedlist>
63 <listitem><para>If you use the ADT Installer script to install ADT you can 78 <listitem><para>If you use the ADT Installer script to install ADT, you can
64 specify whether or not to install QEMU.</para></listitem> 79 specify whether or not to install QEMU.</para></listitem>
65 <listitem><para>If you have downloaded a Yocto Project release and unpacked 80 <listitem><para>If you have downloaded a Yocto Project release and unpacked
66 it to create a Yocto Project source directory followed by sourcing 81 it to create a Yocto Project file structure and you have sourced
67 the Yocto Project environment setup script, QEMU is installed and automatically 82 the Yocto Project environment setup script, QEMU is installed and automatically
68 available.</para></listitem> 83 available.</para></listitem>
69 <listitem><para>If you have installed the cross-toolchain 84 <listitem><para>If you have installed the cross-toolchain
70 tarball followed by sourcing the toolchain's setup environment script, QEMU 85 tarball and you have sourcing the toolchain's setup environment script, QEMU
71 is installed and automatically available.</para></listitem> 86 is also installed and automatically available.</para></listitem>
72 </itemizedlist> 87 </itemizedlist>
73 </para> 88 </para>
74 </section> 89 </section>
75 90
76 <section id='user-space-tools'> 91 <section id='user-space-tools'>
77 <title>User-Space Tools</title> 92 <title>User-Space Tools</title>
93
78 <para> 94 <para>
79 User-space tools are included as part of the distribution. 95 User-space tools are included as part of the distribution.
80 You will find these tools helpful during development. 96 You will find these tools helpful during development.
81 The tools include LatencyTOP, PowerTOP, OProfile, Perf, SystemTap, and Lttng-ust. 97 The tools include LatencyTOP, PowerTOP, OProfile, Perf, SystemTap, and Lttng-ust.
82 These tools are common development tools for the Linux platform. 98 These tools are common development tools for the Linux platform.
83 <itemizedlist> 99 <itemizedlist>
84 <listitem><para><emphasis>LatencyTOP</emphasis> – LatencyTOP focuses on latency 100 <listitem><para><emphasis>LatencyTOP:</emphasis> LatencyTOP focuses on latency
85 that causes skips in audio, 101 that causes skips in audio,
86 stutters in your desktop experience, or situations that overload your server 102 stutters in your desktop experience, or situations that overload your server
87 even when you have plenty of CPU power left. 103 even when you have plenty of CPU power left.
88 You can find out more about LatencyTOP at 104 You can find out more about LatencyTOP at
89 <ulink url='http://www.latencytop.org/'></ulink>. 105 <ulink url='http://www.latencytop.org/'></ulink>.</para></listitem>
90 </para></listitem> 106 <listitem><para><emphasis>PowerTOP:</emphasis> Helps you determine what
91 <listitem><para><emphasis>PowerTOP</emphasis> – Helps you determine what 107 software is using the most power.
92 software is using the most power. 108 You can find out more about PowerTOP at
93 You can find out more about PowerTOP at 109 <ulink url='http://www.linuxpowertop.org/'></ulink>.</para></listitem>
94 <ulink url='http://www.linuxpowertop.org/'></ulink>. 110 <listitem><para><emphasis>OProfile:</emphasis> A system-wide profiler for Linux
95 </para></listitem> 111 systems that is capable of profiling all running code at low overhead.
96 <listitem><para><emphasis>OProfile</emphasis> – A system-wide profiler for Linux 112 You can find out more about OProfile at
97 systems that is capable 113 <ulink url='http://oprofile.sourceforge.net/about/'></ulink>.</para></listitem>
98 of profiling all running code at low overhead. 114 <listitem><para><emphasis>Perf:</emphasis> Performance counters for Linux used
99 You can find out more about OProfile at 115 to keep track of certain types of hardware and software events.
100 <ulink url='http://oprofile.sourceforge.net/about/'></ulink>. 116 For more information on these types of counters see
101 </para></listitem> 117 <ulink url='https://perf.wiki.kernel.org/index.php'></ulink> and click
102 <listitem><para><emphasis>Perf</emphasis> – Performance counters for Linux used 118 on “Perf tools.”</para></listitem>
103 to keep track of certain 119 <listitem><para><emphasis>SystemTap:</emphasis> A free software infrastructure
104 types of hardware and software events. 120 that simplifies information gathering about a running Linux system.
105 For more information on these types of counters see 121 This information helps you diagnose performance or functional problems.
106 <ulink url='https://perf.wiki.kernel.org/index.php'></ulink> and click 122 SystemTap is not available as a user-space tool through the Yocto Eclipse IDE Plug-in.
107 on “Perf tools.” 123 See <ulink url='http://sourceware.org/systemtap'></ulink> for more information
108 </para></listitem> 124 on SystemTap.</para></listitem>
109 <listitem><para><emphasis>SystemTap</emphasis> – A free software infrastructure 125 <listitem><para><emphasis>Lttng-ust:</emphasis> A User-space Tracer designed to
110 that simplifies 126 provide detailed information on user-space activity.
111 information gathering about a running Linux system. 127 See <ulink url='http://lttng.org/ust'></ulink> for more information on Lttng-ust.
112 This information helps you diagnose performance or functional problems. 128 </para></listitem>
113 SystemTap is not available as a user-space tool through the Yocto Eclipse IDE Plug-in. 129 </itemizedlist>
114 See <ulink url='http://sourceware.org/systemtap'></ulink> for more information
115 on SystemTap.
116 </para></listitem>
117 <listitem><para><emphasis>Lttng-ust</emphasis> – A User-space Tracer designed to
118 provide detailed information on user-space activity.
119 See <ulink url='http://lttng.org/ust'></ulink> for more information on Lttng-ust.
120 </para></listitem>
121 </itemizedlist>
122 </para> 130 </para>
123 </section> 131 </section>
124</section> 132</section>
diff --git a/documentation/adt-manual/adt-package.xml b/documentation/adt-manual/adt-package.xml
index 449684d972..f7b236f8d5 100644
--- a/documentation/adt-manual/adt-package.xml
+++ b/documentation/adt-manual/adt-package.xml
@@ -3,6 +3,7 @@
3 3
4<chapter id='adt-package'> 4<chapter id='adt-package'>
5<title>Optionally Customizing the Development Packages Installation</title> 5<title>Optionally Customizing the Development Packages Installation</title>
6
6 <para> 7 <para>
7 Because the Yocto Project is suited for embedded Linux development, it is 8 Because the Yocto Project is suited for embedded Linux development, it is
8 likely that you will need to customize your development packages installation. 9 likely that you will need to customize your development packages installation.
@@ -13,32 +14,34 @@
13 14
14<section id='package-management-systems'> 15<section id='package-management-systems'>
15 <title>Package Management Systems</title> 16 <title>Package Management Systems</title>
17
16 <para> 18 <para>
17 The Yocto Project supports the generation of sysroot files using 19 The Yocto Project supports the generation of sysroot files using
18 three different Package Management Systems (PMS): 20 three different Package Management Systems (PMS):
19 <itemizedlist> 21 <itemizedlist>
20 <listitem><para><emphasis>OPKG</emphasis> A less well known PMS whose use 22 <listitem><para><emphasis>OPKG:</emphasis> A less well known PMS whose use
21 originated in the OpenEmbedded and OpenWrt embedded Linux projects. 23 originated in the OpenEmbedded and OpenWrt embedded Linux projects.
22 This PMS works with files packaged in an <filename>.ipk</filename> format. 24 This PMS works with files packaged in an <filename>.ipk</filename> format.
23 See <ulink url='http://en.wikipedia.org/wiki/Opkg'></ulink> for more 25 See <ulink url='http://en.wikipedia.org/wiki/Opkg'></ulink> for more
24 information about OPKG.</para></listitem> 26 information about OPKG.</para></listitem>
25 <listitem><para><emphasis>RPM</emphasis> A more widely known PMS intended for GNU/Linux 27 <listitem><para><emphasis>RPM:</emphasis> A more widely known PMS intended for GNU/Linux
26 distributions. 28 distributions.
27 This PMS works with files packaged in an <filename>.rms</filename> format. 29 This PMS works with files packaged in an <filename>.rms</filename> format.
28 The Yocto Project currently installs through this PMS by default. 30 The Yocto Project currently installs through this PMS by default.
29 See <ulink url='http://en.wikipedia.org/wiki/RPM_Package_Manager'></ulink> 31 See <ulink url='http://en.wikipedia.org/wiki/RPM_Package_Manager'></ulink>
30 for more information about RPM.</para></listitem> 32 for more information about RPM.</para></listitem>
31 <listitem><para><emphasis>Debian</emphasis> The PMS for Debian-based systems 33 <listitem><para><emphasis>Debian:</emphasis> The PMS for Debian-based systems
32 is built on many PMS tools. 34 is built on many PMS tools.
33 The lower-level PMS tool <filename>dpkg</filename> forms the base of the Debian PMS. 35 The lower-level PMS tool <filename>dpkg</filename> forms the base of the Debian PMS.
34 For information on dpkg see 36 For information on dpkg see
35 <ulink url='http://en.wikipedia.org/wiki/Dpkg'></ulink>.</para></listitem> 37 <ulink url='http://en.wikipedia.org/wiki/Dpkg'></ulink>.</para></listitem>
36 </itemizedlist> 38 </itemizedlist>
37 </para> 39 </para>
38</section> 40</section>
39 41
40<section id='configuring-the-pms'> 42<section id='configuring-the-pms'>
41 <title>Configuring the PMS</title> 43 <title>Configuring the PMS</title>
44
42 <para> 45 <para>
43 Whichever PMS you are using, you need to be sure that the 46 Whichever PMS you are using, you need to be sure that the
44 <filename>PACKAGE_CLASSES</filename> variable in the <filename>conf/local.conf</filename> 47 <filename>PACKAGE_CLASSES</filename> variable in the <filename>conf/local.conf</filename>
@@ -48,10 +51,12 @@
48 Additional values specify additional formats for convenience or testing. 51 Additional values specify additional formats for convenience or testing.
49 See the configuration file for details. 52 See the configuration file for details.
50 </para> 53 </para>
54
51 <para> 55 <para>
52 As an example, consider a scenario where you are using OPKG and you want to add 56 As an example, consider a scenario where you are using OPKG and you want to add
53 the <filename>libglade</filename> package to the target sysroot. 57 the <filename>libglade</filename> package to the target sysroot.
54 </para> 58 </para>
59
55 <para> 60 <para>
56 First, you should generate the <filename>ipk</filename> file for the 61 First, you should generate the <filename>ipk</filename> file for the
57 <filename>libglade</filename> package and add it 62 <filename>libglade</filename> package and add it
@@ -62,20 +67,21 @@
62 $ bitbake package-index 67 $ bitbake package-index
63 </literallayout> 68 </literallayout>
64 </para> 69 </para>
70
65 <para> 71 <para>
66 Next, source the environment setup script found in the Yocto Project files. 72 Next, source the environment setup script found in the Yocto Project files.
67 Follow that by setting up the installation destination to point to your 73 Follow that by setting up the installation destination to point to your
68 sysroot as <filename>&lt;sysroot_dir&gt;</filename>. 74 sysroot as <filename>&lt;sysroot_dir&gt;</filename>.
69 Finally, have an <filename>opkg</filename> configuration file <filename>&lt;conf_file&gt;</filename> 75 Finally, have an OPKG configuration file <filename>&lt;conf_file&gt;</filename>
70 that corresponds to the <filename>opkg</filename> repository you have just created. 76 that corresponds to the <filename>opkg</filename> repository you have just created.
71 The following command forms should now work: 77 The following command forms should now work:
72 <literallayout class='monospaced'> 78 <literallayout class='monospaced'>
73 $ opkg-cl –f &lt;conf_file&gt; -o &lt;sysroot-dir&gt; update 79 $ opkg-cl –f &lt;conf_file&gt; -o &lt;sysroot_dir&gt; update
74 $ opkg-cl –f &lt;cconf_file&gt; -o &lt;sysroot-dir&gt; \ 80 $ opkg-cl –f &lt;cconf_file&gt; -o &lt;sysroot_dir&gt; \
75 --force-overwrite install libglade 81 --force-overwrite install libglade
76 $ opkg-cl –f &lt;cconf_file&gt; -o &lt;sysroot-dir&gt; \ 82 $ opkg-cl –f &lt;cconf_file&gt; -o &lt;sysroot_dir&gt; \
77 --force-overwrite install libglade-dbg 83 --force-overwrite install libglade-dbg
78 $ opkg-cl –f &lt;conf_file&gt; -o &lt;sysroot-dir&gt; \ 84 $ opkg-cl –f &lt;conf_file&gt; -o &lt;sysroot_dir&gt; \
79 --force-overwrite install libglade-dev 85 --force-overwrite install libglade-dev
80 </literallayout> 86 </literallayout>
81 </para> 87 </para>
diff --git a/documentation/adt-manual/adt-prepare.xml b/documentation/adt-manual/adt-prepare.xml
index 63ff1131f9..c2cf1721fa 100644
--- a/documentation/adt-manual/adt-prepare.xml
+++ b/documentation/adt-manual/adt-prepare.xml
@@ -6,75 +6,84 @@
6<title>Preparing to Use the Application Development Toolkit (ADT)</title> 6<title>Preparing to Use the Application Development Toolkit (ADT)</title>
7 7
8<para> 8<para>
9 In order to use the ADT you must install it, source a script to set up the 9 In order to use the ADT, you must install it, <filename>source</filename> a script to set up the
10 environment, and be sure the kernel and filesystem image specific to the target architecture 10 environment, and be sure both the kernel and filesystem image specific to the target architecture
11 exists. 11 exist.
12</para> 12</para>
13 13
14<para> 14<para>
15 This section describes how to be sure you meet these requirements. 15 This chapter describes two important terms and how to be sure you meet the ADT requirements.
16 Throughout this section two important terms are used:
17 <itemizedlist>
18 <listitem><para><emphasis>The Yocto Project Files:</emphasis>
19 This term refers to the directory structure created as a result of downloading
20 and unpacking a Yocto Project release tarball or setting up a Git repository
21 by cloning <filename>git://git.yoctoproject.org/poky</filename>.
22 The Yocto Project files contain BitBake, Documentation, metadata and
23 other files that all support the development environment.
24 The name of the top-level directory of the Yocto Project files
25 is derived from the Yocto Project release tarball.
26 For example, downloading and unpacking <filename>poky-bernard-5.0.1.tar.bz2</filename>
27 results in a Yocto Project source tree whose Yocto Project source directory is named
28 <filename>poky-bernard-5.0.1</filename>.
29 If you create a Git repository then you can name the repository anything you like.
30 </para></listitem>
31 <listitem><para><emphasis>Yocto Project Build Tree:</emphasis>
32 This term refers to the area where Yocto Project builds images.
33 The area is created when you source the Yocto Project setup environment script
34 that is found in the Yocto Project files area.
35 (e.g. <filename>poky-init-build-env</filename>).
36 You can create the Yocto Project build tree anywhere you want on your
37 development system.
38 Here is an example that creates the tree in <filename>mybuilds</filename>
39 and names the Yocto Project build directory <filename>YP-5.0.1</filename>:
40 <literallayout class='monospaced'>
41 $ source poky-bernard-5.0.1/poky-init-build-env $HOME/mybuilds/YP-5.0.1
42 </literallayout>
43 If you don't specifically name the build directory then BitBake creates it
44 in the current directory and uses the name <filename>build</filename>.
45 Also, if you supply an existing directory then BitBake uses that
46 directory as the Yocto Project build directory and populates the build tree
47 beneath it.</para></listitem>
48 </itemizedlist>
49</para> 16</para>
50 17
18<section id='yocto-project-files'>
19 <title>Yocto Project Files and Build Areas</title>
20
21 <para>
22 Before learning how to prepare your system for the ADT, you need to understand
23 two important terms used throughout this manual:
24 <itemizedlist>
25 <listitem><para><emphasis>The Yocto Project Files:</emphasis>
26 This term refers to the directory structure created as a result of downloading
27 and unpacking a Yocto Project release tarball or setting up a Git repository
28 by cloning <filename>git://git.yoctoproject.org/poky</filename>.</para>
29 <para>The Yocto Project files contain BitBake, Documentation, metadata and
30 other files that all support the development environment.
31 Consequently, you must have the Yocto Project files in place on your development
32 system in order to do any development using the Yocto Project.</para>
33 <para>The name of the top-level directory of the Yocto Project file structure
34 is derived from the Yocto Project release tarball.
35 For example, downloading and unpacking <filename>poky-edison-6.0.tar.bz2</filename>
36 results in a Yocto Project source tree whose Yocto Project source directory is named
37 <filename>poky-edison-6.0</filename>.
38 If you create a Git repository, then you can name the repository anything you like.
39 </para></listitem>
40 <listitem><para><emphasis>Yocto Project Build Tree:</emphasis>
41 This term refers to the area where the Yocto Project builds images.
42 The area is created when you <filename>source</filename> the Yocto Project setup
43 environment script that is found in the Yocto Project files area.
44 (e.g. <filename>oe-init-build-env</filename>).
45 You can create the Yocto Project build tree anywhere you want on your
46 development system.
47 Here is an example that creates the tree in <filename>mybuilds</filename>
48 and names the Yocto Project build directory <filename>YP-6.0</filename>:
49 <literallayout class='monospaced'>
50 $ source poky-edison-6.0/oe-init-build-env $HOME/mybuilds/YP-6.0
51 </literallayout>
52 If you don't specifically name the build directory, then BitBake creates it
53 in the current directory and uses the name <filename>build</filename>.
54 Also, if you supply an existing directory, then BitBake uses that
55 directory as the Yocto Project build directory and populates the build tree
56 beneath it.</para></listitem>
57 </itemizedlist>
58 </para>
59</section>
60
51<section id='installing-the-adt'> 61<section id='installing-the-adt'>
52 <title>Installing the ADT</title> 62 <title>Installing the ADT</title>
53 63
54 <para> 64 <para>
55 The following list describes how you can install the ADT, which includes the cross-toolchain. 65 The following list describes how you can install the ADT, which includes the cross-toolchain.
56 Regardless of the installation you choose, however, you must source the cross-toolchain 66 Regardless of the installation you choose, you must <filename>source</filename> the cross-toolchain
57 environment setup script before you use the toolchain. 67 environment setup script before you use the toolchain.
58 See the <xref linkend='setting-up-the-environment'>Setting Up the Environment</xref> 68 See the "<link linkend='setting-up-the-environment'>Setting Up the Environment</link>"
59 section for more information. 69 section for more information.
60 <itemizedlist> 70 <itemizedlist>
61 <listitem><para><emphasis>Use the ADT Installer Script:</emphasis> 71 <listitem><para><emphasis>Use the ADT Installer Script:</emphasis>
62 This method is the recommended way to install the ADT because it 72 This method is the recommended way to install the ADT because it
63 automates much of the process for you. 73 automates much of the process for you.
64 For example, you can configure the installation to install the QEMU emulator 74 For example, you can configure the installation to install the QEMU emulator
65 and the user-space NFS, specify which root filesystem profiles to download, 75 and the user-space NFS, specify which root filesystem profiles to download,
66 and define the target sysroot location. 76 and define the target sysroot location.</para></listitem>
67 </para></listitem>
68 <listitem><para><emphasis>Use an Existing Toolchain Tarball:</emphasis> 77 <listitem><para><emphasis>Use an Existing Toolchain Tarball:</emphasis>
69 Using this method you select and download an architecture-specific 78 Using this method, you select and download an architecture-specific
70 toolchain tarball and then hand-install the toolchain. 79 toolchain tarball and then hand-install the toolchain.
71 If you use this method, you just get the cross-toolchain and QEMU - you do not 80 If you use this method, you just get the cross-toolchain and QEMU - you do not
72 get any of the other mentioned benefits had you run the ADT Installer script.</para></listitem> 81 get any of the other mentioned benefits had you run the ADT Installer script.</para></listitem>
73 <listitem><para><emphasis>Use the Toolchain from within a Yocto Project Build Tree:</emphasis> 82 <listitem><para><emphasis>Use the Toolchain from within a Yocto Project Build Tree:</emphasis>
74 If you already have a Yocto Project build tree, you can install the cross-toolchain 83 If you already have a Yocto Project build tree, you can install the cross-toolchain
75 using that tree. 84 using that tree.
76 However, like the previous method mentioned, you only get the cross-toolchain and QEMU - you 85 However, like the previous method mentioned, you only get the cross-toolchain and QEMU - you
77 do not get any of the other benefits without taking separate steps.</para></listitem> 86 do not get any of the other benefits without taking separate steps.</para></listitem>
78 </itemizedlist> 87 </itemizedlist>
79 </para> 88 </para>
80 89
@@ -92,32 +101,34 @@
92 <para> 101 <para>
93 The ADT Installer is contained in the ADT Installer tarball. 102 The ADT Installer is contained in the ADT Installer tarball.
94 You can download the tarball into any directory from 103 You can download the tarball into any directory from
95 <ulink url='http://autobuilder.yoctoproject.org/downloads/yocto-1.0/adt-installer/'></ulink>. 104 <ulink url='http://autobuilder.yoctoproject.org/downloads/yocto-1.1/adt-installer/'></ulink>.
96 Or, you can use BitBake to generate the tarball inside the existing Yocto Project build tree. 105 Or, you can use BitBake to generate the tarball inside the existing Yocto Project
106 build tree.
97 </para> 107 </para>
98 108
99 <para> 109 <para>
100 If you use BitBake to generate the ADT Installer tarball, you must 110 If you use BitBake to generate the ADT Installer tarball, you must
101 source the Yocto Project environment setup script located in the Yocto Project 111 <filename>source</filename> the Yocto Project environment setup script located
102 files before running the BitBake command that creates the tarball. 112 in the Yocto Project file structure before running the <filename>bitbake</filename>
113 command that creates the tarball.
103 </para> 114 </para>
104 115
105 <para> 116 <para>
106 The following example commands download the Yocto Project release tarball, set up the Yocto 117 The following example commands download the Yocto Project release tarball, set up the Yocto
107 Project files, set up the environment while also creating the Yocto Project build tree, 118 Project files structure, set up the environment while also creating the
108 and finally run the BitBake command that results in the tarball 119 default Yocto Project build tree,
120 and run the <filename>bitbake</filename> command that results in the tarball
109 <filename>~/yocto-project/build/tmp/deploy/sdk/adt_installer.tar.bz2</filename>: 121 <filename>~/yocto-project/build/tmp/deploy/sdk/adt_installer.tar.bz2</filename>:
110 <literallayout class='monospaced'> 122 <literallayout class='monospaced'>
111 $ cd ~ 123 $ cd ~
112 $ mkdir yocto-project 124 $ mkdir yocto-project
113 $ cd yocto-project 125 $ cd yocto-project
114 $ wget http://www.yoctoproject.org/downloads/poky/poky-bernard-5.0.1.tar.bz2 126 $ wget http://www.yoctoproject.org/downloads/poky/poky-edison-6.0.tar.bz2
115 $ tar xjf poky-bernard-5.0.1.tar.bz2 127 $ tar xjf poky-edison-6.0.tar.bz2
116 $ source poky-bernard-5.0.1/poky-init-build-env poky-5.0.1-build 128 $ source poky-edison-6.0/oe-init-build-env
117 $ bitbake adt-installer 129 $ bitbake adt-installer
118 </literallayout> 130 </literallayout>
119 </para> 131 </para>
120
121 </section> 132 </section>
122 133
123 <section id='configuring-and-running-the-adt-installer-script'> 134 <section id='configuring-and-running-the-adt-installer-script'>
@@ -138,57 +149,50 @@
138 149
139 <para> 150 <para>
140 The following list describes the configurations you can define for the ADT Installer. 151 The following list describes the configurations you can define for the ADT Installer.
141 For configuration values and restrictions see the comments in 152 For configuration values and restrictions, see the comments in
142 the <filename>adt-installer.conf</filename> file: 153 the <filename>adt-installer.conf</filename> file:
143 154
144 <itemizedlist> 155 <itemizedlist>
145 <listitem><para><filename>YOCTOADT_IPKG_REPO</filename> – This area 156 <listitem><para><filename>YOCTOADT_IPKG_REPO</filename>: This area
146 includes the IPKG-based packages and the root filesystem upon which 157 includes the IPKG-based packages and the root filesystem upon which
147 the installation is based. 158 the installation is based.
148 If you want to set up your own IPKG repository pointed to by 159 If you want to set up your own IPKG repository pointed to by
149 <filename>YOCTOADT_IPKG_REPO</filename>, you need to be sure that the 160 <filename>YOCTOADT_IPKG_REPO</filename>, you need to be sure that the
150 directory structure follows the same layout as the reference directory 161 directory structure follows the same layout as the reference directory
151 set up at <ulink url='http://adtrepo.yoctoproject.org'></ulink>. 162 set up at <ulink url='http://adtrepo.yoctoproject.org'></ulink>.
152 Also, your repository needs to be accessible through HTTP. 163 Also, your repository needs to be accessible through HTTP.</para></listitem>
153 </para></listitem> 164 <listitem><para><filename>YOCTOADT-TARGETS</filename>: The machine
154 <listitem><para><filename>YOCTOADT-TARGETS</filename> – The machine 165 target architectures for which you want to set up cross-development
155 target architectures for which you want to set up cross-development 166 environments.</para></listitem>
156 environments. 167 <listitem><para><filename>YOCTOADT_QEMU</filename>: Indicates whether
157 </para></listitem> 168 or not to install the emulator QEMU.</para></listitem>
158 <listitem><para><filename>YOCTOADT_QEMU</filename> – Indicates whether 169 <listitem><para><filename>YOCTOADT_NFS_UTIL</filename>: Indicates whether
159 or not to install the emulator QEMU. 170 or not to install user-mode NFS.
160 </para></listitem> 171 If you plan to use the Yocto Eclipse IDE plug-in against QEMU,
161 <listitem><para><filename>YOCTOADT_NFS_UTIL</filename> – Indicates whether 172 you should install NFS.
162 or not to install user-mode NFS. 173 <note>To boot QEMU images using our userspace NFS server, you need
163 If you plan to use the Yocto Eclipse IDE plug-in against QEMU, 174 to be running <filename>portmap</filename> or <filename>rpcbind</filename>.
164 you should install NFS. 175 If you are running <filename>rpcbind</filename>, you will also need to add the
165 <note> 176 <filename>-i</filename> option when <filename>rpcbind</filename> starts up.
166 To boot QEMU images using our userspace NFS server, you need 177 Please make sure you understand the security implications of doing this.
167 to be running <filename>portmap</filename> or <filename>rpcbind</filename>. 178 You might also have to modify your firewall settings to allow
168 If you are running <filename>rpcbind</filename>, you will also need to add the 179 NFS booting to work.</note></para></listitem>
169 <filename>-i</filename> option when <filename>rpcbind</filename> starts up. 180 <listitem><para><filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename>: The root
170 Please make sure you understand the security implications of doing this. 181 filesystem images you want to download from the
171 Your firewall settings may also have to be modified to allow 182 <filename>YOCTOADT_IPKG_REPO</filename> repository.</para></listitem>
172 NFS booting to work. 183 <listitem><para><filename>YOCTOADT_TARGET_SYSROOT_IMAGE_&lt;arch&gt;</filename>: The
173 </note> 184 particular root filesystem used to extract and create the target sysroot.
174 </para></listitem> 185 The value of this variable must have been specified with
175 <listitem><para><filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename> - The root 186 <filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename>.
176 filesystem images you want to download from the <filename>YOCTOADT_IPKG_REPO</filename> 187 For example, if you downloaded both <filename>minimal</filename> and
177 repository. 188 <filename>sato-sdk</filename> images by setting
178 </para></listitem> 189 <filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename>
179 <listitem><para><filename>YOCTOADT_TARGET_SYSROOT_IMAGE_&lt;arch&gt;</filename> - The 190 to "minimal sato-sdk", then <filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename>
180 particular root filesystem used to extract and create the target sysroot. 191 must be set to either <filename>minimal</filename> or
181 The value of this variable must have been specified with 192 <filename>sato-sdk</filename>.</para></listitem>
182 <filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename>. 193 <listitem><para><filename>YOCTOADT_TARGET_SYSROOT_LOC_&lt;arch&gt;</filename>: The
183 For example, if you downloaded both <filename>minimal</filename> and 194 location on the development host where the target sysroot is created.
184 <filename>sato-sdk</filename> images by setting <filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename> 195 </para></listitem>
185 to "minimal sato-sdk", then <filename>YOCTOADT_ROOTFS_&lt;arch&gt;</filename>
186 must be set to either <filename>minimal</filename> or
187 <filename>sato-sdk</filename>.
188 </para></listitem>
189 <listitem><para><filename>YOCTOADT_TARGET_SYSROOT_LOC_&lt;arch&gt;</filename> - The
190 location on the development host where the target sysroot will be created.
191 </para></listitem>
192 </itemizedlist> 196 </itemizedlist>
193 </para> 197 </para>
194 198
@@ -203,14 +207,16 @@
203 <note> 207 <note>
204 The ADT Installer requires the <filename>libtool</filename> package to complete. 208 The ADT Installer requires the <filename>libtool</filename> package to complete.
205 If you install the recommended packages as described in the 209 If you install the recommended packages as described in the
206 <ulink url='http://www.yoctoproject.org/docs/yocto-project-qs/yocto-project-qs.html'> 210 <ulink url='http://www.yoctoproject.org/docs/1.1/yocto-project-qs/yocto-project-qs.html#packages'>
207 Yocto Project Quick Start</ulink> then you will have libtool installed. 211 Packages</ulink> section of
212 <ulink url='http://www.yoctoproject.org/docs/1.1/yocto-project-qs/yocto-project-qs.html'>
213 The Yocto Project Quick Start</ulink>, then you will have libtool installed.
208 </note> 214 </note>
209 215
210 <para> 216 <para>
211 Once the installer begins to run, you are asked whether you want to run in 217 Once the installer begins to run, you are asked whether you want to run in
212 interactive or silent mode. 218 interactive or silent mode.
213 If you want to closely monitor the installation then choose “I” for interactive 219 If you want to closely monitor the installation, choose “I” for interactive
214 mode rather than “S” for silent mode. 220 mode rather than “S” for silent mode.
215 Follow the prompts from the script to complete the installation. 221 Follow the prompts from the script to complete the installation.
216 </para> 222 </para>
@@ -224,12 +230,12 @@
224 according to the <filename>YOCTOADT_TARGET_SYSROOT_LOC_&lt;arch&gt;</filename> variable 230 according to the <filename>YOCTOADT_TARGET_SYSROOT_LOC_&lt;arch&gt;</filename> variable
225 also in your configuration file. 231 also in your configuration file.
226 </para> 232 </para>
227 233 </section>
228 </section>
229 </section> 234 </section>
230 235
231 <section id='using-an-existing-toolchain-tarball'> 236 <section id='using-an-existing-toolchain-tarball'>
232 <title>Using a Cross-Toolchain Tarball</title> 237 <title>Using a Cross-Toolchain Tarball</title>
238
233 <para> 239 <para>
234 If you want to simply install the cross-toolchain by hand, you can do so by using an existing 240 If you want to simply install the cross-toolchain by hand, you can do so by using an existing
235 cross-toolchain tarball. 241 cross-toolchain tarball.
@@ -240,69 +246,73 @@
240 Follow these steps: 246 Follow these steps:
241 <orderedlist> 247 <orderedlist>
242 <listitem><para>Go to 248 <listitem><para>Go to
243 <ulink url='http://autobuilder.yoctoproject.org/downloads/yocto-1.0/toolchain'></ulink> 249 <ulink url='http://autobuilder.yoctoproject.org/downloads/yocto-1.1/toolchain'></ulink>
244 and find the folder that matches your host development system 250 and find the folder that matches your host development system
245 (i.e. <filename>i686</filename> for 32-bit machines or 251 (i.e. <filename>i686</filename> for 32-bit machines or
246 <filename>x86_64</filename> for 64-bit machines).</para> 252 <filename>x86_64</filename> for 64-bit machines).</para></listitem>
247 </listitem>
248 <listitem><para>Go into that folder and download the toolchain tarball whose name 253 <listitem><para>Go into that folder and download the toolchain tarball whose name
249 includes the appropriate target architecture. 254 includes the appropriate target architecture.
250 For example, if your host development system is an Intel-based 64-bit system and 255 For example, if your host development system is an Intel-based 64-bit system and
251 you are going to use your cross-toolchain for an arm target, go into the 256 you are going to use your cross-toolchain for an ARM-based target, go into the
252 <filename>x86_64</filename> folder and download the following tarball: 257 <filename>x86_64</filename> folder and download the following tarball:
253 <literallayout class='monospaced'> 258 <literallayout class='monospaced'>
254 yocto-eglibc-x86_64-arm-toolchain-gmae-1.1.tar.bz2 259 yocto-eglibc-x86_64-arm-toolchain-gmae-1.1.tar.bz2
255 </literallayout> 260 </literallayout>
256 <note> 261 <note>Alternatively, you can build the toolchain tarball if you have a Yocto
257 Alternatively, you can build the toolchain tarball if you have a Yocto Project build tree. 262 Project build tree.
258 Use the <filename>bitbake meta-toolchain</filename> command after you have 263 Use the <filename>bitbake meta-toolchain</filename> command after you have
259 sourced the <filename>poky-build-init script</filename> located in the Yocto Project 264 sourced the <filename>oe-build-init script</filename> located in the Yocto
260 files. 265 Project files.
261 When the <filename>bitbake</filename> command completes, the toolchain tarball will 266 When the <filename>bitbake</filename> command completes, the toolchain tarball will
262 be in <filename>tmp/deploy/sdk</filename> in the Yocto Project build tree. 267 be in <filename>tmp/deploy/sdk</filename> in the Yocto Project build tree.
263 </note></para></listitem> 268 </note></para></listitem>
264 <listitem><para>Make sure you are in the root directory and then expand 269 <listitem><para>Make sure you are in the root directory and then expand
265 the tarball. 270 the tarball.
266 The tarball expands into <filename>/opt/poky/$SDKVERSION</filename>. 271 The tarball expands into <filename>/opt/poky/$SDKVERSION</filename>.
267 Once the tarball in unpacked, the cross-toolchain is installed. 272 Once the tarball in unpacked, the cross-toolchain is installed.
268 You will notice environment setup files for the cross-toolchain in the directory. 273 You will notice environment setup files for the cross-toolchain in the directory.
269 </para></listitem> 274 </para></listitem>
270 </orderedlist> 275 </orderedlist>
271 </para> 276 </para>
272 </section> 277 </section>
273 278
274 <section id='using-the-toolchain-from-within-the-build-tree'> 279 <section id='using-the-toolchain-from-within-the-build-tree'>
275 <title>Using BitBake and the Yocto Project Build Tree</title> 280 <title>Using BitBake and the Yocto Project Build Tree</title>
281
276 <para> 282 <para>
277 A final way of installing just the cross-toolchain is to use BitBake within an existing 283 A final way of installing just the cross-toolchain is to use BitBake within an existing
278 Yocto Project build tree. 284 Yocto Project build tree.
279 Follow these steps: 285 Follow these steps:
280 <orderedlist> 286 <orderedlist>
281 <listitem><para>Source the environment setup script located in the Yocto Project 287 <listitem><para>Source the environment setup script located in the Yocto Project
282 files. 288 files.
283 The script has the string <filename>init-build-env</filename> 289 The script has the string <filename>init-build-env</filename>
284 as part of the name.</para></listitem> 290 as part of the name.</para></listitem>
285 <listitem><para>At this point you should be sure that the 291 <listitem><para>At this point, you should be sure that the
286 <filename>MACHINE</filename> variable 292 <filename>MACHINE</filename> variable
287 in the <filename>local.conf</filename> file is set for the target architecture. 293 in the <filename>local.conf</filename> file found in the Yocto Project
288 You can find the <filename>local.conf</filename> file in the Yocto Project files. 294 file structure's <filename>conf</filename> directory
289 Comments within the <filename>local.conf</filename> file list the values you 295 is set for the target architecture.
290 can use for the <filename>MACHINE</filename> variable. 296 Comments within the <filename>local.conf</filename> file list the values you
291 <note>You can populate the build tree with the cross-toolchains for more 297 can use for the <filename>MACHINE</filename> variable.
292 than a single architecture. 298 <note>You can populate the build tree with the cross-toolchains for more
293 You just need to edit the <filename>MACHINE</filename> variable in the 299 than a single architecture.
294 <filename>local.conf</filename> file and re-run the BitBake command.</note></para></listitem> 300 You just need to edit the <filename>MACHINE</filename> variable in the
301 <filename>local.conf</filename> file and re-run the BitBake
302 command.</note></para></listitem>
295 <listitem><para>Run <filename>bitbake meta-ide-support</filename> to complete the 303 <listitem><para>Run <filename>bitbake meta-ide-support</filename> to complete the
296 cross-toolchain installation. 304 cross-toolchain installation.
297 <note>If you change your working directory after you source the environment 305 <note>If you change your working directory after you
298 setup script and before you run the BitBake command, the command will not work. 306 <filename>source</filename> the environment setup script and before you run
299 Be sure to run the BitBake command immediately after checking or editing the 307 the BitBake command, the command will not work.
300 <filename>local.conf</filename> but without changing your working directory.</note> 308 Be sure to run the <filename>bitbake</filename> command immediately
301 Once BitBake finishes, the cross-toolchain is installed. 309 after checking or editing the <filename>local.conf</filename> but without
302 You will notice environment setup files for the cross-toolchain in the 310 changing your working directory.</note>
303 Yocto Project build tree in the <filename>tmp</filename> directory. 311 Once BitBake finishes, the cross-toolchain is installed.
304 Setup script filenames contain the strings <filename>environment-setup</filename>. 312 You will notice environment setup files for the cross-toolchain in the
305 </para></listitem> 313 Yocto Project build tree in the <filename>tmp</filename> directory.
314 Setup script filenames contain the strings <filename>environment-setup</filename>.
315 </para></listitem>
306 </orderedlist> 316 </orderedlist>
307 </para> 317 </para>
308 </section> 318 </section>
@@ -310,6 +320,7 @@
310 320
311<section id='setting-up-the-environment'> 321<section id='setting-up-the-environment'>
312 <title>Setting Up the Environment</title> 322 <title>Setting Up the Environment</title>
323
313 <para> 324 <para>
314 Before you can use the cross-toolchain, you need to set up the toolchain environment by 325 Before you can use the cross-toolchain, you need to set up the toolchain environment by
315 sourcing the environment setup script. 326 sourcing the environment setup script.
@@ -324,8 +335,8 @@
324 <para> 335 <para>
325 Be sure to run the environment setup script that matches the architecture for 336 Be sure to run the environment setup script that matches the architecture for
326 which you are developing. 337 which you are developing.
327 Environment setup scripts begin with the string “environment-setup” and include as 338 Environment setup scripts begin with the string “<filename>environment-setup</filename>”
328 part of their name the architecture. 339 and include as part of their name the architecture.
329 For example, the environment setup script for a 64-bit IA-based architecture would 340 For example, the environment setup script for a 64-bit IA-based architecture would
330 be the following: 341 be the following:
331 <literallayout class='monospaced'> 342 <literallayout class='monospaced'>
@@ -336,20 +347,22 @@
336 347
337<section id='kernels-and-filesystem-images'> 348<section id='kernels-and-filesystem-images'>
338 <title>Kernels and Filesystem Images</title> 349 <title>Kernels and Filesystem Images</title>
350
339 <para> 351 <para>
340 You will need to have a kernel and filesystem image to boot using your 352 You will need to have a kernel and filesystem image to boot using your
341 hardware or the QEMU emulator. 353 hardware or the QEMU emulator.
342 That means you either have to build them or know where to get them. 354 That means you either have to build them or know where to get them.
343 You can find lots of details on how to get or build images and kernels for your 355 You can find lots of details on how to get or build images and kernels for your
344 architecture in the "Yocto Project Quick Start" found at 356 architecture in
345 <ulink url='http://www.yoctoproject.org/docs/yocto-quick-start/yocto-project-qs.html'></ulink>. 357 <ulink url='http://www.yoctoproject.org/docs/1.1/yocto-quick-start/yocto-project-qs.html'>
358 The Yocto Project Quick Start</ulink>.
346 <note> 359 <note>
347 Yocto Project provides basic kernels and filesystem images for several 360 The Yocto Project provides basic kernels and filesystem images for several
348 architectures (<filename>x86</filename>, <filename>x86-64</filename>, 361 architectures (<filename>x86</filename>, <filename>x86-64</filename>,
349 <filename>mips</filename>, <filename>powerpc</filename>, and <filename>arm</filename>) 362 <filename>mips</filename>, <filename>powerpc</filename>, and <filename>arm</filename>)
350 that you can use unaltered in the QEMU emulator. 363 that you can use unaltered in the QEMU emulator.
351 These kernels and filesystem images reside in the Yocto Project release 364 These kernels and filesystem images reside in the Yocto Project release
352 area - <ulink url='http://autobuilder.yoctoproject.org/downloads/yocto-1.0/machines/'></ulink> 365 area - <ulink url='http://autobuilder.yoctoproject.org/downloads/yocto-1.1/machines/'></ulink>
353 and are ideal for experimentation within Yocto Project. 366 and are ideal for experimentation within Yocto Project.
354 </note> 367 </note>
355 </para> 368 </para>