Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The Yocto Project is a set of tools that helps to create customized Linux systems. This is a short description of how to prepare the host computer and how to create a project with yocto.

Build Host

Scroll Ignore
scroll-pdftrue
scroll-officetrue
scroll-chmtrue
scroll-docbooktrue
scroll-eclipsehelptrue
scroll-epubtrue
scroll-htmltrue

Yocto Project is supported in many Linux Distributions, this descriptions refers to Ubuntu 20.04 LTS. For other Distributions you need to refer to the Yocto Project Reference Manual.

General requirements

This requirements are generally needed for Yocto Project in Ubuntu 20.04:

  • free disk space: at least 50 GB
  • required packages: 

    Code Block
    languagebash
    themeMidnight
    linenumberstrue
    sudo apt install gawk wget git-core diffstat unzip texinfo gcc-multilib build-essential chrpath socat cpio \
                     python3 python3-pip python3-pexpect xz-utils debianutils iputils-ping python3-git python3-jinja2 \
                     libegl1-mesa libsdl1.2-dev pylint3 xterm


(optional) VM with supported Linux OS

If you do not have installled Linux OS on your host computer, you can optionally run VM with a supported Linux OS:

    • e.g. with OracleVM:

      • VM Setup:

        • RAM: >= 8 GB

        • CPU:  >= 4

        • HDD: 150 GB dynamically

          • ubuntu-20.04-desktop-amd64.iso

          • install vm guest additions

        • Network: network bridge

        • optional: add shared folder, enable drag and drop

      • Note the general requirements

Install Yocto Project

Scroll Ignore
scroll-pdftrue
scroll-officetrue
scroll-chmtrue
scroll-docbooktrue
scroll-eclipsehelptrue
scroll-epubtrue
scroll-htmltrue

  1. Create and navigate to yocto directory:

    Code Block
    languagebash
    themeMidnight
    linenumberstrue
    mkdir yocto && cd yocto


  2. Clone the Yocto Project sources (selected branch is 'Hardknott'. For other branches see: https://wiki.yoctoproject.org/wiki/Releases) :

    Code Block
    languagebash
    themeMidnight
    linenumberstrue
    git clone -b hardknott https://git.yoctoproject.org/poky.git


Create a project for an Intel FPGA device

Scroll Ignore
scroll-pdftrue
scroll-officetrue
scroll-chmtrue
scroll-docbooktrue
scroll-eclipsehelptrue
scroll-epubtrue
scroll-htmltrue

The following steps are required to create an image for the Intel FPGA devices:

  1. For Intel FPGA devices you need the meta-layer 'meta-altera'. Run following command to clone this meta-layer from github into the 'poky' folder:

    Code Block
    languagebash
    themeMidnight
    linenumberstrue
    cd poky
    git clone -b master https://github.com/kraj/meta-altera.git


  2. Run the oe-init-build-env script to initialize the environment:

    Code Block
    languagebash
    themeMidnight
    linenumberstrue
    source oe-init-build-env


  3. Add meta-altera layer to /yocto/poky/build/conf/bblayers.conf:

    Code Block
    themeMidnight
    linenumberstrue
    echo 'BBLAYERS += " ${TOPDIR}/../meta-altera "' >> conf/bblayers.conf


  4. Modify the /yocto/poky/build/conf/local.conf file:
    1. Remove default configuration of the MACHINE variable and set it to a supported machine (see meta-altera for more information) of meta-altera layer e.g 'cyclone5':

      Code Block
      themeMidnight
      linenumberstrue
      sed -i /MACHINE\ \?\?=\ \"qemux86-64\"/d conf/local.conf
      echo "MACHINE = \"cyclone5\"" >> conf/local.conf


    2. Set kernel version for meta-altera:

      Code Block
      themeMidnight
      linenumberstrue
      echo 'PREFERRED_PROVIDER_virtual/kernel = "linux-altera-lts"' >> conf/local.conf
      echo 'PREFERRED_VERSION_linux-altera = "5.4%"' >> conf/local.conf


  5. Build the image:

    Code Block
    themeMidnight
    linenumberstrue
    bitbake core-image-minimal

    This command can take several hours to run the first time.

References

Scroll Ignore
scroll-pdftrue
scroll-officetrue
scroll-chmtrue
scroll-docbooktrue
scroll-eclipsehelptrue
scroll-epubtrue
scroll-htmltrue

  1. Yocto Project Reference Manual
  2. Yocto Project Quick Build
  3. OpenEmbedded Layer Index


Scroll Only


HTML
<style>
.wiki-content .columnLayout .cell.aside {
width: 0%;
}</style>



Scroll pdf ignore


Custom_fix_page_content

Table of contents

Table of Contents
outlinetrue