Changes between Version 9 and Version 10 of OSSIEBeagleboard_BitBake

Show
Ignore:
Timestamp:
02/17/11 13:51:49 (2 years ago)
Author:
jawil06
Comment:

Revised initial setup instructions. Building OSSIE section still needs work.

Legend:

Unmodified
Added
Removed
Modified
  • OSSIEBeagleboard_BitBake

    v9 v10  
    66[[PageOutline]] 
    77== Getting Started With !OpenEmbedded == 
    8 Note: If you have already set up !OpenEmbedded and would just like to !BitBake OSSIE you may skip to the Building OSSIE section. 
     8Note: If you have already set up !OpenEmbedded and would just like to !BitBake OSSIE you may skip to the [http://ossie.wireless.vt.edu/trac/wiki/OSSIEBeagleboard_BitBake#BuildingOSSIE Building OSSIE] section. 
    99 
    10 Note: This section is adopted from the !OpenEmbedded Wiki: [http://wiki.openembedded.org/index.php/Getting_started]. 
     10Note: This section is adopted from the !OpenEmbedded Wiki: [http://wiki.openembedded.org/index.php/Getting_started OE Getting Started]. Please read [http://www.openembedded.org/index.php/OEandYourDistro OE and Your Distro] for advice on how to configure your operating system. 
    1111 
    1212=== Prerequisites === 
    13 Before starting, make sure you have the following before preceding (see your distributions documentation on how to install software): 
     13Before starting, make sure you have the following software before preceding (see your distributions documentation on how to install software): 
    1414    1. Git 
    1515    2. SVN 
     16    3. CVS 
     17    4. C++ Compiler (e.g. g++) 
     18    5. diffstat 
     19    6. texi2html 
     20    7. GNU Autotools (specifically autoconf, automake and libtool) 
     21    8. makeinfo 
     22    9. chrpath 
     23    10. qemu (may not be necessary on some systems) 
    1624 
     25Other software may be required, but most distributions already include it. 
    1726 
    1827=== Getting The Toolchain === 
    1928First, create your directory structure. I recommend creating an OE directory in your home folder: 
    2029{{{ 
    21 $ mkdir -p $HOME/OE/build/conf 
    22 $ cd $HOME/OE 
     30mkdir -p $HOME/OE/build/conf 
     31cd $HOME/OE 
    2332}}} 
    2433 
    2534Now, get the lastest !BitBake (1.10.1 as of this writing, to find the latest version visit http://download.berlios.de/bitbake/), and unpack it: 
    2635{{{ 
    27 $ wget http://download.berlios.de/bitbake/bitbake-1.10.1.tar.gz # Download the BitBake package 
    28 $ tar zxvf bitbake-1.10.1.tar.gz                                # Extract it 
    29 $ mv bitbake{-1.10.1,}                                          # Rename the directory to bitbake 
     36wget http://download.berlios.de/bitbake/bitbake-1.10.1.tar.gz # Download the BitBake package 
     37tar zxvf bitbake-1.10.1.tar.gz                                # Extract it 
     38mv bitbake{-1.10.1,}                                          # Rename the directory to bitbake 
    3039}}} 
    3140 
    32 Now that we have !BitBake, we need to get !OpenEmbedded. Before simply checking out !OpenEmbedded trunk, let's look for a recently tested tag here: http://git.openembedded.org/cgit.cgi/openembedded/refs/tags. As of this writing, the newest tested tag is "tested_2010-10-29". Be sure to check the commit log to ensure that a "beagleboard angstrom-2008.1" build was at least tested with a simple console-image. To get !OpenEmdedd run (this may take a while depending on your connection speed): 
     41Now that we have !BitBake, we need to get !OpenEmbedded. Before simply checking out !OpenEmbedded trunk, let's look for a recently tested tag (or even better, a recent release) here: http://git.openembedded.org/cgit.cgi/openembedded/refs/tags. As of this writing, the newest tested tag is "tested_2010-10-29". Be sure to check the commit log to ensure that a "beagleboard angstrom-2008.1" build was at least tested with a simple console-image. To get !OpenEmdedd run (this may take a while depending on your connection speed): 
    3342{{{ 
    34 $ git clone git://git.openembedded.org/openembedded 
    35 $ cd openembedded 
     43git clone git://git.openembedded.org/openembedded 
     44cd openembedded 
    3645# Replace "tested_2010-10-29" with the tag/branch you want 
    37 $ git checkout tested_2010-10-29 
     46git checkout tested_2010-10-29 
    3847}}} 
    3948 
     
    4150Before configuring !BitBake, we should set some environment variables. There are many places to do this, including at build time, but we recommend placing the following lines at the end of your .bashrc file: 
    4251{{{ 
    43 $ cat >> $HOME/.bashrc << EOF 
     52cat >> $HOME/.bashrc << EOF 
     53 
    4454# OpenEmbedded Environment Setup 
    45 export OEBASE=$HOME/OE 
    46 export PATH=$OEBASE/bitbake/bin:$PATH 
    47 export BBPATH=$OEBASE/build:$OEBASE/openembedded 
     55export OEBASE=\$HOME/OE 
     56export PATH=\$OEBASE/bitbake/bin:\$PATH 
     57export BBPATH=\$OEBASE/build:\$OEBASE/openembedded 
    4858export BB_ENV_EXTRAWHITE="OEBASE" 
    4959EOF 
    50 $ . $HOME/.bashrc # Update environment 
     60. $HOME/.bashrc # Update environment 
    5161}}} 
    5262 
     
    5565Now that we have the toolchain and OSSIE recipes, we need to set up our configuration. Copy a sample configuration and edit it to fit our needs: 
    5666{{{ 
    57 $ cd $HOME/OE/ 
    58 $ cp openembedded/conf/local.conf.sample build/conf/local.conf 
    59 $ vim build/conf/local.conf # Use your favorite text-editor 
     67cd $HOME/OE/ 
     68cp openembedded/conf/local.conf.sample build/conf/local.conf 
     69vim build/conf/local.conf # Use your favorite text-editor 
    6070}}} 
    6171 
     
    8090DISTRO = "angstrom-2008.1" 
    8191... 
     92# These lines may be necessary depending on your build system 
     93ENABLE_BINARY_LOCALE_GENERATION = "0" 
     94ASSUME_PROVIDED += "qemu-native" 
     95GLIBC_GENERATE_LOCALES = "en_US.UTF-8" # Add any locales you may need 
     96... 
    8297IMAGE_FSTYPES = " tar.bz2 " 
    8398... 
     
    85100}}} 
    86101 
    87 Other options that may be of interest are PARALLEL_MAKE and BB_NUMBER_THREADS especially for multi-core or multi-processor build systems. 
     102Other options that may be of interest are PARALLEL_MAKE and BB_NUMBER_THREADS especially for multi-threaded, multi-core and/or multi-processor build systems. 
    88103 
    89104=== Building a Console Image === 
    90105This step is not required but recommended to ensure that your setup is working properly before you try to build the OSSIE recipes. We will build task-base and console-image. For more information on what exactly is happening here, see the !OpenEmbedded documentation. Together, these can take hours on a standard machine. We recommend you let it run over night. 
    91106{{{ 
    92 $ cd $HOME/OE/build 
    93 $ bitbake task-base && bitbake console-image 
     107cd $OEBASE/build 
     108bitbake task-base && bitbake console-image 
    94109}}} 
    95110If both builds succeed (run the bitbake command again to ensure success) then you will have a kernel image located at: [[br]] 
     
    103118The OSSIE recipes are located in the OSSIE SVN repository. 
    104119{{{ 
    105 $ cd $HOME/OE/ 
    106 $ svn --username anon --password ossiesdr co \ 
     120cd $OEBASE 
     121svn --username anon --password ossiesdr co \ 
    107122  https://ossie.wireless.vt.edu/repos/ossie/ossiedev/branches/jawil06/recipes ossie-recipes 
    108123}}} 
    109 Note: if you skipped the instructions on setting up !OpenEmbedded, you must add ossie-recipes to BBFILES in your local.conf. 
     124Note: if you skipped the instructions on setting up !OpenEmbedded, you must add ossie-recipes to the BBFILES variable in your local.conf. 
    110125 
    111126=== omniORBpy Workarounds === 
     
    114129First, modify the omniORB-native recipe to stage all of the necessary header files: 
    115130{{{ 
    116 $ vim $OEHOME/openembedded/recipes/omniorb/omniorb_4.1.4.bb # Use your favorite text-editor 
     131vim $OEBASE/openembedded/recipes/omniorb/omniorb_4.1.4.bb # Use your favorite text-editor 
    117132# Add the following to the bottom of the file 
    118133TODO: what needs to be added? 
     
    121136Finally, !BitBake the modified recipe. 
    122137{{{ 
    123 $ cd $OEHOME/build 
    124 $ bitbake omniorb-native # This could take some time 
     138cd $OEBASE/build 
     139bitbake omniorb-native # This could take some time 
    125140}}} 
    126141 
     
    128143This will create a console image with all the necessary development files to build other OSSIE components and tools for which there is not already a recipe natively on the !BeagleBoard 
    129144{{{ 
    130 $ cd $HOME/OE/build 
    131 $ bitbake ossie-dev-console-image 
     145cd $OEBASE/build 
     146bitbake ossie-dev-console-image 
    132147}}}