Personal tools
You are here: Home Members gillesgigan gumstix Setting up build environment
Document Actions

Setting up build environment

by Gilles Gigan last modified 2008-09-30 22:21

Steps to set up an OpenEmbedded build environment on debian lenny

Installing OpenEmbedded

followed the instructions at

mkdir ~/gumstix 
cd ~/gumstix
svn co gumstix-oe

(this will install just under 600MB worth of stuff !!)

cat gumstix-oe/extras/profile >> ~/.bashrc
sudo groupadd oe
sudo usermod -a -G oe your_username
sudo mkdir /usr/share/sources
sudo chgrp oe /usr/share/sources
sudo chmod 0775 /usr/share/sources
sudo chmod ug+s /usr/share/sources

log out and log back in.

BitBaking the first program

To complete the installation of OpenEmbedded, bitbake a hello world program. However, make sure gcc-4.2 is used, not gcc-4.3 otherwise build will fail around the compilation of gmp-native (if required, rm -Rf tmp and start again)

sudo apt-get install gcc-4.2
sudo ln -sf /usr/bin/gcc-4.2 /usr/bin/gcc

Then compile the hello world example:

cd gumstix/gumstix-oe
mkdir -p user.collection/packages/helloworld/files
cat > hello.c <<EOF
#include <stdio.h>
void main(int argc, char **argv){
printf("hello world");
cd ..
cat > <<EOF
DESCRIPTION = "hello world sample program"

PR = "r0"


SRC_URI = " \
file://hello.c \

S = "${WORKDIR}"

do_compile () {
${CC} ${CFLAGS} ${LDFLAGS} -o hello hello.c

do_install () {
install -d ${D}${bindir}/
install -m 0755 ${S}/hello ${D}${bindir}/

bitbake helloworld

This will download a lot more source packages. However

Powered by Plone CMS, the Open Source Content Management System

This site conforms to the following standards: