summaryrefslogtreecommitdiffstats
path: root/documentation/adt-manual
diff options
context:
space:
mode:
Diffstat (limited to 'documentation/adt-manual')
-rw-r--r--documentation/adt-manual/adt-prepare.xml78
1 files changed, 44 insertions, 34 deletions
diff --git a/documentation/adt-manual/adt-prepare.xml b/documentation/adt-manual/adt-prepare.xml
index 845c783d24..e67487b224 100644
--- a/documentation/adt-manual/adt-prepare.xml
+++ b/documentation/adt-manual/adt-prepare.xml
@@ -4,29 +4,30 @@
4 4
5<chapter id='adt-prepare'> 5<chapter id='adt-prepare'>
6 6
7<title>Preparing to Use the Application Development Toolkit (ADT)</title> 7<title>Preparing for Application Development</title>
8 8
9<para> 9<para>
10 In order to use the ADT, you must install it, <filename>source</filename> a script to set up the 10 In order to develop applications, you need set up your host development system.
11 environment, and be sure both the kernel and filesystem image specific to the target architecture 11 Several ways exist that allow you to install cross-development tools, QEMU, the
12 exist. 12 Eclipse Yocto Plug-in, and other tools.
13 This chapter describes how to be sure you meet the ADT requirements. 13 This chapter describes how to prepare for application development.
14</para> 14</para>
15 15
16<section id='installing-the-adt'> 16<section id='installing-the-adt'>
17 <title>Installing the ADT</title> 17 <title>Installing the ADT and Toolchains</title>
18 18
19 <para> 19 <para>
20 The following list describes how you can install the ADT, which includes the cross-toolchain. 20 The following list describes installation methods that set up varying degrees of tool
21 Regardless of the installation you choose, you must <filename>source</filename> the cross-toolchain 21 availabiltiy on your system.
22 environment setup script before you use the toolchain. 22 Regardless of the installation method you choose,
23 you must <filename>source</filename> the cross-toolchain
24 environment setup script before you use a toolchain.
23 See the "<link linkend='setting-up-the-cross-development-environment'>Setting Up the 25 See the "<link linkend='setting-up-the-cross-development-environment'>Setting Up the
24 Cross-Development Environment</link>" 26 Cross-Development Environment</link>" section for more information.
25 section for more information.
26 </para> 27 </para>
27 28
28 <note> 29 <note>
29 <para>Avoid mixing installation methods when installing the ADT for different architectures. 30 <para>Avoid mixing installation methods when installing toolchains for different architectures.
30 For example, avoid using the ADT Installer to install some toolchains and then hand-installing 31 For example, avoid using the ADT Installer to install some toolchains and then hand-installing
31 cross-development toolchains from downloaded tarballs to install toolchains 32 cross-development toolchains from downloaded tarballs to install toolchains
32 for different architectures. 33 for different architectures.
@@ -50,9 +51,10 @@
50 toolchain tarball and then hand-install the toolchain. 51 toolchain tarball and then hand-install the toolchain.
51 If you use this method, you just get the cross-toolchain and QEMU - you do not 52 If you use this method, you just get the cross-toolchain and QEMU - you do not
52 get any of the other mentioned benefits had you run the ADT Installer script.</para></listitem> 53 get any of the other mentioned benefits had you run the ADT Installer script.</para></listitem>
53 <listitem><para><emphasis>Use the Toolchain from within a Yocto Project Build Tree:</emphasis> 54 <listitem><para><emphasis>Use the Toolchain from within the Build Directory:</emphasis>
54 If you already have a build directory, you can build the cross-toolchain 55 If you already have a
55 within that structure. 56 <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>build directory</ulink>,
57 you can build the cross-toolchain within the directory.
56 However, like the previous method mentioned, you only get the cross-toolchain and QEMU - you 58 However, like the previous method mentioned, you only get the cross-toolchain and QEMU - you
57 do not get any of the other benefits without taking separate steps.</para></listitem> 59 do not get any of the other benefits without taking separate steps.</para></listitem>
58 </itemizedlist> 60 </itemizedlist>
@@ -75,7 +77,8 @@
75 <ulink url='&YOCTO_DL_URL;/releases'>Index of Releases</ulink>, specifically 77 <ulink url='&YOCTO_DL_URL;/releases'>Index of Releases</ulink>, specifically
76 at 78 at
77 <ulink url='&YOCTO_ADTINSTALLER_DL_URL;'></ulink>. 79 <ulink url='&YOCTO_ADTINSTALLER_DL_URL;'></ulink>.
78 Or, you can use BitBake to generate the tarball inside the existing build directory. 80 Or, you can use BitBake to generate the tarball inside the existing
81 <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>build directory</ulink>.
79 </para> 82 </para>
80 83
81 <para> 84 <para>
@@ -87,9 +90,9 @@
87 </para> 90 </para>
88 91
89 <para> 92 <para>
90 The following example commands download the Yocto Project release tarball, set up the 93 The following example commands download the Poky tarball, set up the
91 source directory, set up the environment while also creating the 94 <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>source directory</ulink>,
92 default build directory, 95 set up the environment while also creating the default build directory,
93 and run the <filename>bitbake</filename> command that results in the tarball 96 and run the <filename>bitbake</filename> command that results in the tarball
94 <filename>~/yocto-project/build/tmp/deploy/sdk/adt_installer.tar.bz2</filename>: 97 <filename>~/yocto-project/build/tmp/deploy/sdk/adt_installer.tar.bz2</filename>:
95 <literallayout class='monospaced'> 98 <literallayout class='monospaced'>
@@ -243,7 +246,7 @@
243 poky-eglibc-x86_64-i586-toolchain-gmae-&DISTRO;.tar.bz2 246 poky-eglibc-x86_64-i586-toolchain-gmae-&DISTRO;.tar.bz2
244 </literallayout> 247 </literallayout>
245 <note><para>As an alternative to steps one and two, you can build the toolchain tarball 248 <note><para>As an alternative to steps one and two, you can build the toolchain tarball
246 if you have a build directory. 249 if you have a <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>build directory</ulink>.
247 If you need GMAE, you should use the <filename>bitbake meta-toolchain-gmae</filename> 250 If you need GMAE, you should use the <filename>bitbake meta-toolchain-gmae</filename>
248 command. 251 command.
249 The resulting tarball will support such development. 252 The resulting tarball will support such development.
@@ -270,27 +273,29 @@
270 273
271 <para> 274 <para>
272 A final way of making the cross-toolchain available is to use BitBake 275 A final way of making the cross-toolchain available is to use BitBake
273 to generate the toolchain within an existing build directory. 276 to generate the toolchain within an existing
277 <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>build directory</ulink>.
274 This method does not install the toolchain into the 278 This method does not install the toolchain into the
275 <filename>/opt</filename> directory. 279 <filename>/opt</filename> directory.
276 As with the previous method, if you need to install the target sysroot, you must 280 As with the previous method, if you need to install the target sysroot, you must
277 do this separately. 281 do that separately as well.
278 </para> 282 </para>
279 283
280 <para> 284 <para>
281 Follow these steps to generate the toolchain into the build tree: 285 Follow these steps to generate the toolchain into the build directory:
282 <orderedlist> 286 <orderedlist>
283 <listitem><para>Source the environment setup script 287 <listitem><para>Source the environment setup script
284 <filename>oe-init-build-env</filename> located in the source directory. 288 <filename>oe-init-build-env</filename> located in the
289 <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>source directory</ulink>.
285 </para></listitem> 290 </para></listitem>
286 <listitem><para>At this point, you should be sure that the 291 <listitem><para>At this point, you should be sure that the
287 <filename>MACHINE</filename> variable 292 <ulink url='&YOCTO_DOCS_REF_URL;#var-MACHINE'><filename>MACHINE</filename></ulink> variable
288 in the <filename>local.conf</filename> file found in the 293 in the <filename>local.conf</filename> file found in the
289 <filename>conf</filename> directory of the build directory 294 <filename>conf</filename> directory of the build directory
290 is set for the target architecture. 295 is set for the target architecture.
291 Comments within the <filename>local.conf</filename> file list the values you 296 Comments within the <filename>local.conf</filename> file list the values you
292 can use for the <filename>MACHINE</filename> variable. 297 can use for the <filename>MACHINE</filename> variable.
293 <note>You can populate the build tree with the cross-toolchains for more 298 <note>You can populate the build directory with the cross-toolchains for more
294 than a single architecture. 299 than a single architecture.
295 You just need to edit the <filename>MACHINE</filename> variable in the 300 You just need to edit the <filename>MACHINE</filename> variable in the
296 <filename>local.conf</filename> file and re-run the BitBake 301 <filename>local.conf</filename> file and re-run the BitBake
@@ -320,10 +325,12 @@
320 <para> 325 <para>
321 Before you can develop using the cross-toolchain, you need to set up the 326 Before you can develop using the cross-toolchain, you need to set up the
322 cross-development environment by sourcing the toolchain's environment setup script. 327 cross-development environment by sourcing the toolchain's environment setup script.
323 If you used the ADT Installer or used an existing ADT tarball to install the ADT, 328 If you used the ADT Installer or hand-installed cross-toolchain,
324 then you can find this script in the <filename>&YOCTO_ADTPATH_DIR;</filename> 329 then you can find this script in the <filename>&YOCTO_ADTPATH_DIR;</filename>
325 directory. 330 directory.
326 If you installed the toolchain in the build tree, you can find the environment setup 331 If you installed the toolchain in the
332 <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>build directory</ulink>,
333 you can find the environment setup
327 script for the toolchain in the build directory's <filename>tmp</filename> directory. 334 script for the toolchain in the build directory's <filename>tmp</filename> directory.
328 </para> 335 </para>
329 336
@@ -358,7 +365,7 @@
358 pre-built versions. 365 pre-built versions.
359 You can find examples for both these situations in the 366 You can find examples for both these situations in the
360 "<ulink url='&YOCTO_DOCS_QS_URL;#test-run'>A Quick Test Run</ulink>" section of 367 "<ulink url='&YOCTO_DOCS_QS_URL;#test-run'>A Quick Test Run</ulink>" section of
361 The Yocto Project Quick Start. 368 the Yocto Project Quick Start.
362 </para> 369 </para>
363 370
364 <para> 371 <para>
@@ -372,7 +379,7 @@
372 For information on the image types you can build using the OpenEmbedded build system, 379 For information on the image types you can build using the OpenEmbedded build system,
373 see the 380 see the
374 "<ulink url='&YOCTO_DOCS_REF_URL;#ref-images'>Images</ulink>" chapter in 381 "<ulink url='&YOCTO_DOCS_REF_URL;#ref-images'>Images</ulink>" chapter in
375 The Yocto Project Reference Manual. 382 the Yocto Project Reference Manual.
376 </para> 383 </para>
377 384
378 <para> 385 <para>
@@ -389,8 +396,10 @@
389 you can do so one of two ways: 396 you can do so one of two ways:
390 <itemizedlist> 397 <itemizedlist>
391 <listitem><para>Modify the <filename>conf/local.conf</filename> configuration in 398 <listitem><para>Modify the <filename>conf/local.conf</filename> configuration in
392 the build directory and then rebuild the image. 399 the <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>build directory</ulink>
393 With this method, you need to modify the <filename>EXTRA_IMAGE_FEATURES</filename> 400 and then rebuild the image.
401 With this method, you need to modify the
402 <ulink url='&YOCTO_DOCS_REF_URL;#var-EXTRA_IMAGE_FEATURES'><filename>EXTRA_IMAGE_FEATURES</filename></ulink>
394 variable to have the value of "tools-debug" before rebuilding the image. 403 variable to have the value of "tools-debug" before rebuilding the image.
395 Once the image is rebuilt, the <filename>tcf-agent</filename> will be included 404 Once the image is rebuilt, the <filename>tcf-agent</filename> will be included
396 in the image and is launched automatically after the boot.</para></listitem> 405 in the image and is launched automatically after the boot.</para></listitem>
@@ -398,7 +407,7 @@
398 To build the agent, follow these steps: 407 To build the agent, follow these steps:
399 <orderedlist> 408 <orderedlist>
400 <listitem><para>Be sure the ADT is installed as described in the 409 <listitem><para>Be sure the ADT is installed as described in the
401 "<link linkend='installing-the-adt'>Installing the ADT</link>" section. 410 "<link linkend='installing-the-adt'>Installing the ADT and Toolchains</link>" section.
402 </para></listitem> 411 </para></listitem>
403 <listitem><para>Set up the cross-development environment as described in the 412 <listitem><para>Set up the cross-development environment as described in the
404 "<link linkend='setting-up-the-cross-development-environment'>Setting 413 "<link linkend='setting-up-the-cross-development-environment'>Setting
@@ -411,7 +420,8 @@
411 </literallayout></para></listitem> 420 </literallayout></para></listitem>
412 <listitem><para>Modify the <filename>Makefile.inc</filename> file 421 <listitem><para>Modify the <filename>Makefile.inc</filename> file
413 for the cross-compilation environment by setting the 422 for the cross-compilation environment by setting the
414 <filename>OPSYS</filename> and <filename>MACHINE</filename> 423 <filename>OPSYS</filename> and
424 <ulink url='&YOCTO_DOCS_REF_URL;#var-MACHINE'><filename>MACHINE</filename></ulink>
415 variables according to your target.</para></listitem> 425 variables according to your target.</para></listitem>
416 <listitem><para>Use the cross-development tools to build the 426 <listitem><para>Use the cross-development tools to build the
417 <filename>tcf-agent</filename>. 427 <filename>tcf-agent</filename>.