diff options
Diffstat (limited to 'documentation/ref-manual/eclipse/html/poky-ref-manual/faq.html')
-rw-r--r-- | documentation/ref-manual/eclipse/html/poky-ref-manual/faq.html | 791 |
1 files changed, 791 insertions, 0 deletions
diff --git a/documentation/ref-manual/eclipse/html/poky-ref-manual/faq.html b/documentation/ref-manual/eclipse/html/poky-ref-manual/faq.html new file mode 100644 index 0000000..8b8cafb --- /dev/null +++ b/documentation/ref-manual/eclipse/html/poky-ref-manual/faq.html @@ -0,0 +1,791 @@ +<html> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> +<title>Chapter 12. FAQ</title> +<link rel="stylesheet" type="text/css" href="../book.css"> +<meta name="generator" content="DocBook XSL Stylesheets V1.76.1"> +<link rel="home" href="index.html" title="The Yocto Project Reference Manual"> +<link rel="up" href="index.html" title="The Yocto Project Reference Manual"> +<link rel="prev" href="ref-varlocality-recipe-build.html" title="11.2.4. Extra Build Information"> +<link rel="next" href="resources.html" title="Chapter 13. Contributing to the Yocto Project"> +</head> +<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="chapter" title="Chapter 12. FAQ"> +<div class="titlepage"><div><div><h2 class="title"> +<a name="faq"></a>Chapter 12. FAQ</h2></div></div></div> +<div class="qandaset" title="Frequently Asked Questions"> +<a name="idm1966160"></a><dl> +<dt>12.1. <a href="faq.html#idm1965696"> + How does Poky differ from OpenEmbedded? + </a> +</dt> +<dt>12.2. <a href="faq.html#idm1961792"> + I only have Python 2.4 or 2.5 but BitBake requires Python 2.6 or 2.7. + Can I still use the Yocto Project? + </a> +</dt> +<dt>12.3. <a href="faq.html#idm2605168"> + How can you claim Poky / OpenEmbedded-Core is stable? + </a> +</dt> +<dt>12.4. <a href="faq.html#idm3232752"> + How do I get support for my board added to the Yocto Project? + </a> +</dt> +<dt>12.5. <a href="faq.html#idm3230416"> + Are there any products built using the OpenEmbedded build system? + </a> +</dt> +<dt>12.6. <a href="faq.html#idm3227696"> + What does the OpenEmbedded build system produce as output? + </a> +</dt> +<dt>12.7. <a href="faq.html#idm5359408"> + How do I add my package to the Yocto Project? + </a> +</dt> +<dt>12.8. <a href="faq.html#idm5357680"> + Do I have to reflash my entire board with a new Yocto Project image when recompiling + a package? + </a> +</dt> +<dt>12.9. <a href="faq.html#idm5354224"> + What is GNOME Mobile and what is the difference between GNOME Mobile and GNOME? + </a> +</dt> +<dt>12.10. <a href="faq.html#idm2088960"> + I see the error 'chmod: XXXXX new permissions are r-xrwxrwx, not r-xr-xr-x'. + What is wrong? + </a> +</dt> +<dt>12.11. <a href="faq.html#idm2085168"> + How do I make the Yocto Project work in RHEL/CentOS? + </a> +</dt> +<dt>12.12. <a href="faq.html#idm3829808"> + I see lots of 404 responses for files on + http://www.yoctoproject.org/sources/*. Is something wrong? + </a> +</dt> +<dt>12.13. <a href="faq.html#idm3827408"> + I have machine-specific data in a package for one machine only but the package is + being marked as machine-specific in all cases, how do I prevent this? + </a> +</dt> +<dt>12.14. <a href="faq.html#idm5331776"> + I'm behind a firewall and need to use a proxy server. How do I do that? + </a> +</dt> +<dt>12.15. <a href="faq.html#idm1524432"> + What’s the difference between foo and foo-native? + </a> +</dt> +<dt>12.16. <a href="faq.html#idm1520336"> + I'm seeing random build failures. Help?! + </a> +</dt> +<dt>12.17. <a href="faq.html#idm4636672"> + What do we need to ship for license compliance? + </a> +</dt> +<dt>12.18. <a href="faq.html#idm4635216"> + How do I disable the cursor on my touchscreen device? + </a> +</dt> +<dt>12.19. <a href="faq.html#idm4631744"> + How do I make sure connected network interfaces are brought up by default? + </a> +</dt> +<dt>12.20. <a href="faq.html#idm3888832"> + How do I create images with more free space? + </a> +</dt> +<dt>12.21. <a href="faq.html#idm619504"> + Why don't you support directories with spaces in the pathnames? + </a> +</dt> +<dt>12.22. <a href="faq.html#idm617456"> + How do I use an external toolchain? + </a> +</dt> +<dt>12.23. <a href="faq.html#idm4577168"> + How does the OpenEmbedded build system obtain source code and will it work behind my + firewall or proxy server? + </a> +</dt> +<dt>12.24. <a href="faq.html#idm3953616"> + Can I get rid of build output so I can start over? + </a> +</dt> +</dl> +<table border="0" width="100%" summary="Q and A Set"> +<col align="left" width="1%"> +<col> +<tbody> +<tr class="question" title="12.1."> +<td align="left" valign="top"> +<a name="idm1965696"></a><a name="idm1965568"></a><p><b>12.1.</b></p> +</td> +<td align="left" valign="top"><p> + How does Poky differ from <a class="ulink" href="http://www.openembedded.org" target="_self">OpenEmbedded</a>? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + The term "Poky" refers to the specific reference build system that + the Yocto Project provides. + Poky is based on <a class="link" href="../dev-manual/oe-core.html" target="_self">OE-Core</a> + and BitBake. + Thus, the generic term used here for the build system is + the "OpenEmbedded build system." + Development in the Yocto Project using Poky is closely tied to OpenEmbedded, with + changes always being merged to OE-Core or BitBake first before being pulled back + into Poky. + This practice benefits both projects immediately. + For a fuller description of the term "Poky", see the + <a class="link" href="../dev-manual/poky.html" target="_self">poky</a> term in the Yocto Project + Development Manual. + </p></td> +</tr> +<tr class="question" title="12.2."> +<td align="left" valign="top"> +<a name="idm1961792"></a><a name="idm1961664"></a><p><b>12.2.</b></p> +</td> +<td align="left" valign="top"><p> + I only have Python 2.4 or 2.5 but BitBake requires Python 2.6 or 2.7. + Can I still use the Yocto Project? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + You can use a stand-alone tarball to provide Python 2.6. + You can find pre-built 32 and 64-bit versions of Python 2.6 at the following locations: + </p> +<div class="itemizedlist"><ul class="itemizedlist" type="disc"> +<li class="listitem"><p><a class="ulink" href="http://downloads.yoctoproject.org/releases/miscsupport/python-nativesdk-standalone-i686.tar.bz2" target="_self">32-bit tarball</a></p></li> +<li class="listitem"><p><a class="ulink" href="http://downloads.yoctoproject.org/releases/miscsupport/python-nativesdk-standalone-x86_64.tar.bz2" target="_self">64-bit tarball</a></p></li> +</ul></div> +<p> + </p> +<p> + These tarballs are self-contained with all required libraries and should work + on most Linux systems. + To use the tarballs extract them into the root + directory and run the appropriate command: + </p> +<pre class="literallayout"> + $ export PATH=/opt/poky/sysroots/i586-pokysdk-linux/usr/bin/:$PATH + $ export PATH=/opt/poky/sysroots/x86_64-pokysdk-linux/usr/bin/:$PATH + </pre> +<p> + </p> +<p> + Once you run the command, BitBake uses Python 2.6. + </p> +</td> +</tr> +<tr class="question" title="12.3."> +<td align="left" valign="top"> +<a name="idm2605168"></a><a name="idm2605040"></a><p><b>12.3.</b></p> +</td> +<td align="left" valign="top"><p> + How can you claim Poky / OpenEmbedded-Core is stable? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + There are three areas that help with stability; + </p> +<div class="itemizedlist"><ul class="itemizedlist" type="disc"> +<li class="listitem"><p>The Yocto Project team keeps + <a class="link" href="../dev-manual/oe-core.html" target="_self">OE-Core</a> small + and focused, containing around 830 recipes as opposed to the thousands + available in other OpenEmbedded community layers. + Keeping it small makes it easy to test and maintain.</p></li> +<li class="listitem"><p>The Yocto Project team runs manual and automated tests + using a small, fixed set of reference hardware as well as emulated + targets.</p></li> +<li class="listitem"><p>The Yocto Project uses an an autobuilder, + which provides continuous build and integration tests.</p></li> +</ul></div> +<p> + </p> +</td> +</tr> +<tr class="question" title="12.4."> +<td align="left" valign="top"> +<a name="idm3232752"></a><a name="idm3232624"></a><p><b>12.4.</b></p> +</td> +<td align="left" valign="top"><p> + How do I get support for my board added to the Yocto Project? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + Support for an additional board is added by creating a BSP layer for it. + For more information on how to create a BSP layer, see the + <a class="link" href="../bsp-guide/index.html" target="_self">Yocto Project Board Support Package (BSP) Developer's Guide</a>. + </p> +<p> + Usually, if the board is not completely exotic, adding support in + the Yocto Project is fairly straightforward. + </p> +</td> +</tr> +<tr class="question" title="12.5."> +<td align="left" valign="top"> +<a name="idm3230416"></a><a name="idm3230288"></a><p><b>12.5.</b></p> +</td> +<td align="left" valign="top"><p> + Are there any products built using the OpenEmbedded build system? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + The software running on the <a class="ulink" href="http://vernier.com/labquest/" target="_self">Vernier LabQuest</a> + is built using the OpenEmbedded build system. + See the <a class="ulink" href="http://www.vernier.com/products/interfaces/labq/" target="_self">Vernier LabQuest</a> + website for more information. + There are a number of pre-production devices using the OpenEmbedded build system + and the Yocto Project team + announces them as soon as they are released. + </p></td> +</tr> +<tr class="question" title="12.6."> +<td align="left" valign="top"> +<a name="idm3227696"></a><a name="idm3227568"></a><p><b>12.6.</b></p> +</td> +<td align="left" valign="top"><p> + What does the OpenEmbedded build system produce as output? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + Because the same set of recipes can be used to create output of various formats, the + output of an OpenEmbedded build depends on how it was started. + Usually, the output is a flashable image ready for the target device. + </p></td> +</tr> +<tr class="question" title="12.7."> +<td align="left" valign="top"> +<a name="idm5359408"></a><a name="idm5359280"></a><p><b>12.7.</b></p> +</td> +<td align="left" valign="top"><p> + How do I add my package to the Yocto Project? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + To add a package, you need to create a BitBake recipe. + For information on how to add a package, see the section + "<a class="link" href="../dev-manual/usingpoky-extend-addpkg.html" target="_self">Adding a Package</a>" + in the Yocto Project Development Manual. + </p></td> +</tr> +<tr class="question" title="12.8."> +<td align="left" valign="top"> +<a name="idm5357680"></a><a name="idm5357552"></a><p><b>12.8.</b></p> +</td> +<td align="left" valign="top"><p> + Do I have to reflash my entire board with a new Yocto Project image when recompiling + a package? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + The OpenEmbedded build system can build packages in various formats such as + <code class="filename">ipk</code> for <code class="filename">opkg</code>, + Debian package (<code class="filename">.deb</code>), or RPM. + The packages can then be upgraded using the package tools on the device, much like + on a desktop distribution such as Ubuntu or Fedora. + </p></td> +</tr> +<tr class="question" title="12.9."> +<td align="left" valign="top"> +<a name="idm5354224"></a><a name="idm5354096"></a><p><b>12.9.</b></p> +</td> +<td align="left" valign="top"><p> + What is GNOME Mobile and what is the difference between GNOME Mobile and GNOME? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + GNOME Mobile is a subset of the <a class="ulink" href="http://www.gnome.org" target="_self">GNOME</a> + platform targeted at mobile and embedded devices. + The the main difference between GNOME Mobile and standard GNOME is that + desktop-orientated libraries have been removed, along with deprecated libraries, + creating a much smaller footprint. + </p></td> +</tr> +<tr class="question" title="12.10."> +<td align="left" valign="top"> +<a name="idm2088960"></a><a name="idm2088832"></a><p><b>12.10.</b></p> +</td> +<td align="left" valign="top"><p> + I see the error '<code class="filename">chmod: XXXXX new permissions are r-xrwxrwx, not r-xr-xr-x</code>'. + What is wrong? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + You are probably running the build on an NTFS filesystem. + Use <code class="filename">ext2</code>, <code class="filename">ext3</code>, or <code class="filename">ext4</code> instead. + </p></td> +</tr> +<tr class="question" title="12.11."> +<td align="left" valign="top"> +<a name="idm2085168"></a><a name="idm2085040"></a><p><b>12.11.</b></p> +</td> +<td align="left" valign="top"><p> + How do I make the Yocto Project work in RHEL/CentOS? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + To get the Yocto Project working under RHEL/CentOS 5.1 you need to first + install some required packages. + The standard CentOS packages needed are: + </p> +<div class="itemizedlist"><ul class="itemizedlist" type="disc"> +<li class="listitem"><p>"Development tools" (selected during installation)</p></li> +<li class="listitem"><p><code class="filename">texi2html</code></p></li> +<li class="listitem"><p><code class="filename">compat-gcc-34</code></p></li> +</ul></div> +<p> + On top of these, you need the following external packages: + </p> +<div class="itemizedlist"><ul class="itemizedlist" type="disc"> +<li class="listitem"><p><code class="filename">python-sqlite2</code> from + <a class="ulink" href="http://dag.wieers.com/rpm/packages/python-sqlite2/" target="_self">DAG repository</a> + </p></li> +<li class="listitem"><p><code class="filename">help2man</code> from + <a class="ulink" href="http://centos.karan.org/el4/extras/stable/x86_64/RPMS/repodata/repoview/help2man-0-1.33.1-2.html" target="_self">Karan repository</a></p></li> +</ul></div> +<p> + </p> +<p> + Once these packages are installed, the OpenEmbedded build system will be able + to build standard images. + However, there might be a problem with the QEMU emulator segfaulting. + You can either disable the generation of binary locales by setting + <code class="filename"><a class="link" href="ref-variables-glos.html#var-ENABLE_BINARY_LOCALE_GENERATION" title="ENABLE_BINARY_LOCALE_GENERATION">ENABLE_BINARY_LOCALE_GENERATION</a> + </code> to "0" or by removing the <code class="filename">linux-2.6-execshield.patch</code> + from the kernel and rebuilding it since that is the patch that causes the problems with QEMU. + </p> +</td> +</tr> +<tr class="question" title="12.12."> +<td align="left" valign="top"> +<a name="idm3829808"></a><a name="idm3829680"></a><p><b>12.12.</b></p> +</td> +<td align="left" valign="top"><p> + I see lots of 404 responses for files on + <code class="filename">http://www.yoctoproject.org/sources/*</code>. Is something wrong? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + Nothing is wrong. + The OpenEmbedded build system checks any configured source mirrors before downloading + from the upstream sources. + The build system does this searching for both source archives and + pre-checked out versions of SCM managed software. + These checks help in large installations because it can reduce load on the SCM servers + themselves. + The address above is one of the default mirrors configured into the + build system. + Consequently, if an upstream source disappears, the team + can place sources there so builds continue to work. + </p></td> +</tr> +<tr class="question" title="12.13."> +<td align="left" valign="top"> +<a name="idm3827408"></a><a name="idm3827280"></a><p><b>12.13.</b></p> +</td> +<td align="left" valign="top"><p> + I have machine-specific data in a package for one machine only but the package is + being marked as machine-specific in all cases, how do I prevent this? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + Set <code class="filename"><a class="link" href="ref-variables-glos.html#var-SRC_URI_OVERRIDES_PACKAGE_ARCH" title="SRC_URI_OVERRIDES_PACKAGE_ARCH">SRC_URI_OVERRIDES_PACKAGE_ARCH</a> + </code> = "0" in the <code class="filename">.bb</code> file but make sure the package is + manually marked as + machine-specific in the case that needs it. + The code that handles <code class="filename">SRC_URI_OVERRIDES_PACKAGE_ARCH</code> is in <code class="filename">base.bbclass</code>. + </p></td> +</tr> +<tr class="question" title="12.14."> +<td align="left" valign="top"> +<a name="idm5331776"></a><a name="idm5331648"></a><p><b>12.14.</b></p> +</td> +<td align="left" valign="top"><p> + I'm behind a firewall and need to use a proxy server. How do I do that? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + Most source fetching by the OpenEmbedded build system is done by <code class="filename">wget</code> + and you therefore need to specify the proxy settings in a + <code class="filename">.wgetrc</code> file in your home directory. + Example settings in that file would be + </p> +<pre class="literallayout"> + http_proxy = http://proxy.yoyodyne.com:18023/ + ftp_proxy = http://proxy.yoyodyne.com:18023/ + </pre> +<p> + The Yocto Project also includes a <code class="filename">site.conf.sample</code> + file that shows how to configure CVS and Git proxy servers + if needed. + </p> +</td> +</tr> +<tr class="question" title="12.15."> +<td align="left" valign="top"> +<a name="idm1524432"></a><a name="idm1524304"></a><p><b>12.15.</b></p> +</td> +<td align="left" valign="top"><p> + What’s the difference between <code class="filename">foo</code> and <code class="filename">foo-native</code>? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + The <code class="filename">*-native</code> targets are designed to run on the system + being used for the build. + These are usually tools that are needed to assist the build in some way such as + <code class="filename">quilt-native</code>, which is used to apply patches. + The non-native version is the one that runs on the target device. + </p></td> +</tr> +<tr class="question" title="12.16."> +<td align="left" valign="top"> +<a name="idm1520336"></a><a name="idm1520208"></a><p><b>12.16.</b></p> +</td> +<td align="left" valign="top"><p> + I'm seeing random build failures. Help?! + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + If the same build is failing in totally different and random ways, + the most likely explanation is that either the hardware you're running the + build on has some problem, or, if you are running the build under virtualisation, + the virtualisation probably has bugs. + The OpenEmbedded build system processes a massive amount of data causing lots of network, disk and + CPU activity and is sensitive to even single bit failures in any of these areas. + True random failures have always been traced back to hardware or virtualisation issues. + </p></td> +</tr> +<tr class="question" title="12.17."> +<td align="left" valign="top"> +<a name="idm4636672"></a><a name="idm4636544"></a><p><b>12.17.</b></p> +</td> +<td align="left" valign="top"><p> + What do we need to ship for license compliance? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + This is a difficult question and you need to consult your lawyer for the answer + for your specific case. + It is worth bearing in mind that for GPL compliance there needs to be enough + information shipped to allow someone else to rebuild the same end result + you are shipping. + This means sharing the source code, any patches applied to it, and also any + configuration information about how that package was configured and built. + </p></td> +</tr> +<tr class="question" title="12.18."> +<td align="left" valign="top"> +<a name="idm4635216"></a><a name="idm4635088"></a><p><b>12.18.</b></p> +</td> +<td align="left" valign="top"><p> + How do I disable the cursor on my touchscreen device? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + You need to create a form factor file as described in the + "<a class="link" href="../bsp-guide/bsp-filelayout-misc-recipes.html" target="_self">Miscellaneous Recipe Files</a>" + section and set the <code class="filename">HAVE_TOUCHSCREEN</code> variable equal to one as follows: + </p> +<pre class="literallayout"> + HAVE_TOUCHSCREEN=1 + </pre> +<p> + </p> +</td> +</tr> +<tr class="question" title="12.19."> +<td align="left" valign="top"> +<a name="idm4631744"></a><a name="idm4631616"></a><p><b>12.19.</b></p> +</td> +<td align="left" valign="top"><p> + How do I make sure connected network interfaces are brought up by default? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + The default interfaces file provided by the netbase recipe does not + automatically bring up network interfaces. + Therefore, you will need to add a BSP-specific netbase that includes an interfaces + file. + See the "<a class="link" href="../bsp-guide/bsp-filelayout-misc-recipes.html" target="_self">Miscellaneous Recipe Files</a>" + section for information on creating these types of miscellaneous recipe files. + </p> +<p> + For example, add the following files to your layer: + </p> +<pre class="literallayout"> + meta-MACHINE/recipes-bsp/netbase/netbase/MACHINE/interfaces + meta-MACHINE/recipes-bsp/netbase/netbase_5.0.bbappend + </pre> +<p> + </p> +</td> +</tr> +<tr class="question" title="12.20."> +<td align="left" valign="top"> +<a name="idm3888832"></a><a name="idm3888704"></a><p><b>12.20.</b></p> +</td> +<td align="left" valign="top"><p> + How do I create images with more free space? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + Images are created to be 1.2 times the size of the populated root filesystem. + To modify this ratio so that there is more free space available, you need to + set the configuration value <code class="filename">IMAGE_OVERHEAD_FACTOR</code>. + For example, setting <code class="filename">IMAGE_OVERHEAD_FACTOR</code> to 1.5 sets + the image size ratio to one and a half times the size of the populated + root filesystem. + </p> +<pre class="literallayout"> + IMAGE_OVERHEAD_FACTOR = "1.5" + </pre> +<p> + </p> +</td> +</tr> +<tr class="question" title="12.21."> +<td align="left" valign="top"> +<a name="idm619504"></a><a name="idm619376"></a><p><b>12.21.</b></p> +</td> +<td align="left" valign="top"><p> + Why don't you support directories with spaces in the pathnames? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"><p> + The Yocto Project team has tried to do this before but too many of the tools + the OpenEmbedded build system depends on such as <code class="filename">autoconf</code> + break when they find spaces in pathnames. + Until that situation changes, the team will not support spaces in pathnames. + </p></td> +</tr> +<tr class="question" title="12.22."> +<td align="left" valign="top"> +<a name="idm617456"></a><a name="idm617328"></a><p><b>12.22.</b></p> +</td> +<td align="left" valign="top"><p> + How do I use an external toolchain? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + The toolchain configuration is very flexible and customizable. + It is primarily controlled with the + <code class="filename"><a class="link" href="ref-variables-glos.html#var-TCMODE" title="TCMODE">TCMODE</a></code> variable. + This variable controls which <code class="filename">tcmode-*.inc</code> file to include + from the <code class="filename">meta/conf/distro/include</code> directory within the + <a class="link" href="../dev-manual/source-directory.html" target="_self">source directory</a>. + </p> +<p> + The default value of <code class="filename">TCMODE</code> is "default" + (i.e. <code class="filename">tcmode-default.inc</code>). + However, other patterns are accepted. + In particular, "external-*" refers to external toolchains of which there are some + basic examples included in the OpenEmbedded Core (<code class="filename">meta</code>). + You can use your own custom toolchain definition in your own layer + (or as defined in the <code class="filename">local.conf</code> file) at the location + <code class="filename">conf/distro/include/tcmode-*.inc</code>. + </p> +<p> + In addition to the toolchain configuration, you also need a corresponding toolchain recipe file. + This recipe file needs to package up any pre-built objects in the toolchain such as + <code class="filename">libgcc</code>, <code class="filename">libstdcc++</code>, + any locales, and <code class="filename">libc</code>. + An example is the <code class="filename">external-sourcery-toolchain.bb</code>, which is located + in <code class="filename">meta/recipes-core/meta/</code> within the source directory. + </p> +</td> +</tr> +<tr class="question" title="12.23."> +<td align="left" valign="top"> +<a name="idm4577168"></a><a name="idm5139136"></a><p><b>12.23.</b></p> +</td> +<td align="left" valign="top"><p><a name="how-does-the-yocto-project-obtain-source-code-and-will-it-work-behind-my-firewall-or-proxy-server"></a> + How does the OpenEmbedded build system obtain source code and will it work behind my + firewall or proxy server? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + The way the build system obtains source code is highly configurable. + You can setup the build system to get source code in most environments if + HTTP transport is available. + </p> +<p> + When the build system searches for source code, it first tries the local download directory. + If that location fails, Poky tries PREMIRRORS, the upstream source, + and then MIRRORS in that order. + </p> +<p> + By default, the OpenEmbedded build system uses the Yocto Project source PREMIRRORS + for SCM-based sources, + upstreams for normal tarballs, and then falls back to a number of other mirrors + including the Yocto Project source mirror if those fail. + </p> +<p> + As an example, you could add a specific server for Poky to attempt before any + others by adding something like the following to the <code class="filename">local.conf</code> + configuration file: + </p> +<pre class="literallayout"> + PREMIRRORS_prepend = "\ + git://.*/.* http://www.yoctoproject.org/sources/ \n \ + ftp://.*/.* http://www.yoctoproject.org/sources/ \n \ + http://.*/.* http://www.yoctoproject.org/sources/ \n \ + https://.*/.* http://www.yoctoproject.org/sources/ \n" + </pre> +<p> + </p> +<p> + These changes cause Poky to intercept Git, FTP, HTTP, and HTTPS + requests and direct them to the <code class="filename">http://</code> sources mirror. + You can use <code class="filename">file://</code> URLs to point to local directories + or network shares as well. + </p> +<p> + Aside from the previous technique, these options also exist: + </p> +<pre class="literallayout"> + BB_NO_NETWORK = "1" + </pre> +<p> + This statement tells BitBake to throw an error instead of trying to access the + Internet. + This technique is useful if you want to ensure code builds only from local sources. + </p> +<p> + Here is another technique: + </p> +<pre class="literallayout"> + BB_FETCH_PREMIRRORONLY = "1" + </pre> +<p> + This statement limits Poky to pulling source from the PREMIRRORS only. + Again, this technique is useful for reproducing builds. + </p> +<p> + Here is another technique: + </p> +<pre class="literallayout"> + BB_GENERATE_MIRROR_TARBALLS = "1" + </pre> +<p> + This statement tells Poky to generate mirror tarballs. + This technique is useful if you want to create a mirror server. + If not, however, the technique can simply waste time during the build. + </p> +<p> + Finally, consider an example where you are behind an HTTP-only firewall. + You could make the following changes to the <code class="filename">local.conf</code> + configuration file as long as the PREMIRROR server is up to date: + </p> +<pre class="literallayout"> + PREMIRRORS_prepend = "\ + ftp://.*/.* http://www.yoctoproject.org/sources/ \n \ + http://.*/.* http://www.yoctoproject.org/sources/ \n \ + https://.*/.* http://www.yoctoproject.org/sources/ \n" + BB_FETCH_PREMIRRORONLY = "1" + </pre> +<p> + These changes would cause Poky to successfully fetch source over HTTP and + any network accesses to anything other than the PREMIRROR would fail. + </p> +<p> + The build system also honors the standard shell environment variables + <code class="filename">http_proxy</code>, <code class="filename">ftp_proxy</code>, + <code class="filename">https_proxy</code>, and <code class="filename">all_proxy</code> + to redirect requests through proxy servers. + </p> +</td> +</tr> +<tr class="question" title="12.24."> +<td align="left" valign="top"> +<a name="idm3953616"></a><a name="idm3685632"></a><p><b>12.24.</b></p> +</td> +<td align="left" valign="top"><p> + Can I get rid of build output so I can start over? + </p></td> +</tr> +<tr class="answer"> +<td align="left" valign="top"></td> +<td align="left" valign="top"> +<p> + Yes - you can easily do this. + When you use BitBake to build an image, all the build output goes into the + directory created when you source the <code class="filename">oe-init-build-env</code> + setup file. + By default, this <a class="link" href="../dev-manual/build-directory.html" target="_self">build directory</a> + is named <code class="filename">build</code> but can be named + anything you want. + </p> +<p> + Within the build directory is the <code class="filename">tmp</code> directory. + To remove all the build output yet preserve any source code or downloaded files + from previous builds, simply remove the <code class="filename">tmp</code> directory. + </p> +</td> +</tr> +</tbody> +</table> +</div> +</div></body> +</html> |