How to Create Yocto Projects - Compile RidgeRun Projects

From RidgeRun Developer Wiki






Compile RidgeRun Products

RidgeRun provides to their customer a great catalog of products for different purposes. One of our main areas of expertise is the development of GStreamer solutions. Meta-RidgeRun is a public meta-layer where RidgeRun publishes the recipes to incorporate our products into a Yocto system. In this section we will learn how to add products such as: GstDemon, gst-interpipes and gst-perf to the project we have been working on.

Follow the next steps to create a new meta-layer into your yocto project.

  1. Lets clone meta-ridgerun at your prefered location on your local machine.
    git clone https://github.com/RidgeRun/meta-ridgerun.git
    cd meta-ridgerun
  2. Create a variable REPO_DIR pointing to meta-ridgerun.
    REPO_DIR=$(pwd)
  3. Now, if you have followed the steps to Create a Basic Project you already may have a Yocto Project into your computer. Go to the location where you have the project and create the following variable pointing to the project.
    YOCTO_DIR=$(pwd)

    If you don't, please go to Setting Environment and follow those steps before to continue here.

  4. To initialize the environment will depend on the yocto used. For example, on this project we could do it with the following script.
    source $YOCTO_DIR/oe-init-build-env
  5. Create a source directory, here we will store the recipes from meta-ridgerun layer.
    mkdir $YOCTO_DIR/sources
    cd sources
  6. Create your new meta-layer where you want to add the RidgeRun Products.
    bitbake-layers create-layer meta-rrproducts
    </syntaxhighlight
    
    <li> Add the new meta-layer to the environment being build with the following command
    
    === Gst-Perf ===
    
    A GStreamer element to measure framerate, bitrate and CPU usage. If you want to know more information about this element visit [https://github.com/RidgeRun/gst-perf Gst-Perf]. 
    
    These are the steps to add the recipe:
    
    <ol>
    <li> Copy the recipe from the repo with the following command
    <syntaxhighlight line lang=bash>
    cd $YOCTO_DIR/sources/meta-rrproducts/recipes-rr
    cp $REPO_DIR/recipes-multimedia/gstreamer/gst-perf_1.0.bb ./
  7. Compile the recipe
    cd $YOCTO_DIR
    bitbake gst-perf
  8. Add the recipe to the image.
    cd $YOCTO_DIR/build/conf

    With your favorite text editor open local.conf, and add the following line at the end of the file.

    IMAGE_INSTALL:append = " gst-perf"

GstD

A GStreamer element framework for controlling audio and video streaming using an InterProcess Communication protocol. For more information visit GstDemon

These are the steps to add the recipe:

  1. Copy the recipe from the repo with the following command
    cd $YOCTO_DIR/sources/meta-rrproducts/recipes-rr
    cp $REPO_DIR/recipes-multimedia/gstreamer/gstd_0.15.0.bb ./
    cp -r $REPO_DIR/recipes-multimedia/gstreamer/gstd/ ./
  2. Compile the recipe
    cd $YOCTO_DIR
    bitbake gstd
  3. Add the recipe to the image.
    cd $YOCTO_DIR/build/conf

    With your favorite text editor open local.conf, and add the following line at the end of the file.

    IMAGE_INSTALL:append = " gstd"

Gst-Interpipes

GstInterpipe is a RidgeRun GStreamer plug-in that allows pipeline buffers and events to flow between two or more independent pipelines. For more information visit [[1]]

This are the steps to add the recipe:

  1. Copy the recipe from the repo with the following command
    cd $YOCTO_DIR/sources/meta-rrproducts/recipes-rr
    cp $REPO_DIR/recipes-multimedia/gstreamer/gst-interpipes_v1.1.8.bb ./
  2. Compile the recipe
    cd $YOCTO_DIR
    bitbake gst-interpipes
  3. Add the recipe to the image.
    $YOCTO_DIR/build/conf

    With your favorite text editor open local.conf, and add the following line at the end of the file.

    IMAGE_INSTALL:append = " gst-interpipes"