DMAI GStreamer Plug-In Getting Started Guide

From Texas Instruments Wiki
Jump to: navigation, search

This section collects information from a variety of places to simplify obtaining, building, and running a gst-ti-dmai gstreamer pipeline. Information on the full documentation is provided, along with greatly simplified steps. You can access the existing detailed instructions contained in the README.TXT file. Overview

The major steps to go from nothing to hardware accelerated GStreamer running on your target hardware include:

  • Configuring host PC
  • Getting the target software
  • Installing target software
  • Building the libraries and tools
  • Transferring code to the target hardware
  • Running test pipelines
  • Creating your first GStreamer application
  • Resolving common problems

Common steps are described below, with each processor having its own wiki page. Please enhance the wiki as you are following these steps to make it easier for the next person.

Contents

Configuring host PC

The software for the target device is cross-compiled, meaning you run the compiler on a host computer (typically x86 based host processor) with the compiler generating code for the target hardware (ARM target processor). The host PC configuration steps install the necessary tools to allow you to retrieve the source code, build the target applications and libraries, and get the needed components on the target hardware so you can run hardware accelerated GStreamer.

Each Linux distribution has a unique way installing the packages needed to use the host computer for cross-compilation. If your Linux distribution isn't listed below, please add it.

*  RHEL4 host system
*  Ubuntu 9.04 host system


Cross-compile toolchain

Choose the appropriate toolchain based on your target processor:

Target processor Toolchain
DM355 CS 2009q1 ARM GNU/Linux for host iA32 GNU/Linux
DM365 CS 2009q1 ARM GNU/Linux for host iA32 GNU/Linux
DM6446 MV arm_v5t_le-
DM6467 MV arm_v5t_le-
DM6467T CS 2009q1 ARM GNU/Linux for host iA32 GNU/Linux
OMAP35xx CS 2008q1 ARM GNU/Linux for host iA32 GNU/Linux

MV toolchain installation

If your target hardware build requires the MV toolchain, install as follows:

chmod ugo+x mvl_5_0_0801921_demo_sys_setuplinux.bin 
chmod ugo+rwx /opt                                              # this might make some system administrators nervous
./mvl_5_0_0801921_demo_sys_setuplinux.bin --mode console --prefix /opt/mv_pro_5.0
cd /opt/mv_pro_5.0
sudo tar -xzf mvltools5_0_0801921_update.tar.gz                 # super user privileges needed for device files in the target file system


CS 2008q1 toolchain installation

Detailed instructions at GSG: OMAP35x DVEVM Software Setup#Installing_the_toolchain

mkdir -p $HOME/toolchain
cd $HOME/toolchain
tar -jxf /opt/images/arm-2008q1-126-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

CS 2009q1 toolchain installation

Detailed instructions at Installing CodeSourcery Toolchain

cd /opt
sudo tar -xjf /tmp/arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

DMAI GStreamer source code

Download the latest released gst-dmai source code. You need to unpack the gst-dmai source code tarball in the correct directory:

cd $HOME
tar -xzf /tmp/gst-ti-plugin-full-*.tar.gz

if you want to use the latest (not released) gst-dmai source code:

cd $HOME
svn checkout --username anonymous --password "" https://gstreamer.ti.com/svn/gstreamer_ti/trunk/gstreamer_ti gstreamer_ti

If you use the code from SVN, then you need to use the directory name $HOME/gstreamer_ti instead of $HOME/gst-ti-plugin-full-*.

MV toolchain pkg-config update

If you are using the MV toolchain, you need to update your pkg-config application.

cd $HOME/gst-ti-plugin-full-1.01.00/opensource_build/host_tools
tar -xzf pkgconfig-0.18.tar.gz
cd pkgconfig-0.18
./configure --prefix=/opt/mv_pro_5.0/montavista/pro  # the version in the toolchain is too old, so we replace it
make
sudo rm -f /opt/mv_pro_5.0/montavista/pro/bin/pkg-config
sudo make install


Host Directory Structure

To help you find your way around, here are the key directories and a description of what they contain.

What Version Where
MV toolchain 5.0 /opt/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le
CS 2008q1 toolchain 2008q1 $HOME/toolchain/arm-2008q1
CS 2009q1 toolchain 2009q1 $HOME/toolchain/arm-2009q1
LSP / PSP master kernel 2.00.00.140 /opt/mv_pro_5.0/montavista/pro/devkit/lsp/ti-davinci/linux-2.6.18_pro500
02.01.03.11 $HOME/workdir/opt/linux-02.01.03.11
3.10.00.19 $HOME/git
Platform kernel
(platform specific configuration)
working
copy
$HOME/workdir/lsp/ti-davinci/linux-2.6.18_pro500
DVSDK 2.00.00.22 $HOME/dvsdk_2_00_00_22
3.00.02.44 $HOME/dvsdk_3_00_02_44
3.10.00.19 $HOME/dvsdk/dvsdk_3_10_00_19
codec server dm6446 $HOME/dvsdk_2_00_00_22/dm6446_dvsdk_combos_2_05
dm6467 $HOME/dvsdk_2_00_00_22/dm6467_dvsdk_combos_2_05
dm6467T $HOME/dvsdk/dvsdk_3_10_00_19/cs2dm6467_1_00_00_10
omap3530 $HOME/dvsdk_3_00_02_44/cs1omap3530_1_00_01
codec set dm355 $HOME/dvsdk/dvsdk_3_10_00_19/dm355_codecs_03_10_00_02

dm365 $HOME/dvsdk/dvsdk_3_10_00_19/dm365_codecs_03_10_00_07

Master target file system /opt/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le/target
Platform target file system
(with DVSDK, DMAI, GStreamer installed)
working
copy
$HOME/workdir/filesys
gst-dmai 1.01.00 $HOME/gst-ti-plugin-full-1.01.00
1.02.00 $HOME/gst-ti-plugin-full-1.02.00
SVN trunk $HOME/gstreamer_ti

Obtaining the software

Software from TI website

Each target processor requires software that is unique for that hardware.

The toolchain, DVSDK, and related software is downloaded from the TI website. For the links in the tables below to work, you must first log into the TI website. In general, you can start at the current download page and browse around to find all the packages listed below.


Target processor specific DVSDK and related software

The target processor specific source code consists of several components and is packaged together into a DVSDK - Digital Video Software Development Kit. Each target processor may use a different DVSDK version. If you are already logged into the TI website, you can click on the DVSDK link in the table below to go to the appropriate DVSDK download link.

In addition, download the related software.

Target processor DVSDK LSP / PSP Target File System XDC Tools DSPBios C64 Tools C64 Codecs
DM355 3.10.00.19 3.10.00.19 3.10.00.19 Included with DVSDK Not required Not required Not required
DM365 3.10.00.19 3.10.00.19 3.10.00.19 Included with DVSDK Not required Not required Not required
DM6446 2.00.00.22 2.00.00.140 Included with PSP 3.10.05.61
5.33.03 6.0.21.1 DM6446 Codecs
MP3 decode codec
DM6467 2.00.00.22 2.00.00.140 Included with PSP 3.10.05.61 5.33.03 6.0.21.1 DM6467 Codecs
MP3 decode codec
DM6467T 3.10.00.19 3.10.00.19 3.10.00.19 Included with DVSDK Not required Not required 1.00.00.10
OMAP35xx 3.00.02.44 02.01.03.11 Included with PSP 3.15.01.59 5.33.06 6.0.16.1 1.00.01-44

Software installation

DM355 software installation (DVSDK 3.10.00.19)

These are simplified steps based on the instructions in DVSDK 3.10.00.19 release notes and other documentation mentioned therein.

Copy the downloaded toolchain, kernel, DVSDK and related packages for your target processor into the /tmp directory so that your machine has the following files:

/tmp/arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
/tmp/dvsdk_3_10_00_19_Setup.bin
/tmp/linux-davinci-staging.tar.gz
/tmp/linuxlibs-2009.11-armv5te.tar.gz
/tmp/arago-demo-image-dm355-evm.tar.gz
/tmp/gst-ti-plugin-full-1.02.00.tar.gz

Install all the needed tools and components:

DOWNLOAD_DIR=/tmp

# toolchain
cd /opt
sudo tar -xjf $DOWNLOAD_DIR/arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

# DVSDK
chmod ugo+x $DOWNLOAD_DIR/dvsdk_3_10_00_19_Setup.bin
echo -e 'y\n qy' | $DOWNLOAD_DIR/dvsdk_3_10_00_19_Setup.bin --mode console

# Linux kernel
cd $HOME/dvsdk
tar -xzf $DOWNLOAD_DIR/linux-davinci-staging.tar.gz

# linuxlibs
cd $HOME/dvsdk
tar -xzf $DOWNLOAD_DIR/linuxlibs-2009.11-armv5te.tar.gz

# GStreamer DMAI plug-in
cd $HOME
tar -xzf $DOWNLOAD_DIR/gst-ti-plugin-full-1.02.00.tar.gz

# target file system
mkdir -p $HOME/install/dm355_fs
cd $HOME/install/dm355_fs
sudo tar -xzf $DOWNLOAD_DIR/arago-demo-image-dm355-evm.tar.gz
sudo chown -R --reference=$HOME $HOME/install/dm355_fs

DM365 software installation (DVSDK 3.10.00.19)

These are simplified steps based on the instructions in DVSDK 3.10.00.19 release notes and other documentation mentioned therein.

Copy the downloaded toolchain, kernel, DVSDK and related packages for your target processor into the /tmp directory so that your machine has the following files:

/tmp/arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
/tmp/dvsdk_3_10_00_19_Setup.bin
/tmp/linux-davinci-staging.tar.gz
/tmp/linuxlibs-2009.11-armv5te.tar.gz
/tmp/arago-demo-image-dm365-evm.tar.gz
/tmp/gst-ti-plugin-full-1.02.00.tar.gz

Install all the needed tools and components:

DOWNLOAD_DIR=/tmp

# toolchain
cd /opt
sudo tar -xjf $DOWNLOAD_DIR/arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

# DVSDK
chmod ugo+x $DOWNLOAD_DIR/dvsdk_3_10_00_19_Setup.bin
echo -e 'y\n qy' | $DOWNLOAD_DIR/dvsdk_3_10_00_19_Setup.bin --mode console

# Linux kernel
cd $HOME/dvsdk
tar -xzf $DOWNLOAD_DIR/linux-davinci-staging.tar.gz

# linuxlibs
cd $HOME/dvsdk
tar -xzf $DOWNLOAD_DIR/linuxlibs-2009.11-armv5te.tar.gz

# GStreamer DMAI plug-in
cd $HOME
tar -xzf $DOWNLOAD_DIR/gst-ti-plugin-full-1.02.00.tar.gz

# target file system
mkdir -p $HOME/install/dm365_fs
cd $HOME/install/dm365_fs
sudo tar -xzf $DOWNLOAD_DIR/arago-demo-image-dm365-evm.tar.gz
sudo chown -R --reference=$HOME $HOME/install/dm365_fs

DM6446 software installation (DVSDK 2.00.00.22)

These are simplified steps based on the instructions in TMS320DM6446 DVEVM v2.0 Getting Started Guide found in $HOME/dvsdk_2_00_00_22/docs/sprue66f.pdf available after you install the DVSDK.

One you have copied the downloaded DVSDK and related packages for your target processor into the /tmp directory, you can install the software (use all default values and confirm with a Y as necessary):

cd /tmp
chmod ugo+x *.bin

# DVSDK
./dvsdk_setuplinux_2_00_00_22.bin --Y --mode console

# LSP
./mvl_5_0_0_demo_lsp_setuplinux_02_00_00_140.bin --mode console --prefix /opt/mv_pro_5.0
cd /opt/mv_pro_5.0
sudo tar -xzf DaVinciLSP_02_00_00_140.tar.gz
sudo chmod o+x /opt/mv_pro_5.0/montavista/common/* /opt/mv_pro_5.0/montavista/common/share/*
cd /tmp

# XDC tools
./xdctools_setuplinux_3_10_03.bin --mode console --prefix $HOME

# DSPBios
./bios_setuplinux_5_33_03.bin --mode console --prefix $HOME

# C64 Toolchain
./TI-C6x-CGT-v6.0.21.1.bin --mode console --prefix $HOME/cg6x_6_0_21

# DM6446 codecs
./dm6446_codecs_setuplinux_2_00_00_22.bin --mode console --prefix $HOME/dvsdk_2_00_00_22

# MP3 decode codec

# kernel working copy
mkdir -p $HOME/workdir/lsp/ti-davinci
cp -R /opt/mv_pro_5.0/montavista/pro/devkit/lsp/ti-davinci/* $HOME/workdir/lsp/ti-davinci

# target file system working copy
mkdir -p $HOME/workdir/filesys  $HOME/workdir/lsp/ti-davinci
sudo cp -a /opt/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le/target/* $HOME/workdir/filesys
sudo chown -R $USER $HOME/workdir/filesys/opt


DM6467 software installation (DVSDK 2.00.00.22)

One you have copied the downloaded DVSDK and related packages for your target processor into the /tmp directory, you can install the software (use all default values and confirm with a Y as necessary):

cd /tmp
chmod ugo+x *.bin

# DVSDK
./dvsdk_setuplinux_2_00_00_22.bin --Y --mode console

# LSP
./mvl_5_0_0_demo_lsp_setuplinux_02_00_00_140.bin --mode console -prefix /opt/mv_pro_5.0
cd /opt/mv_pro_5.0
sudo tar -xzf DaVinciLSP_02_00_00_140.tar.gz
sudo chmod o+x /opt/mv_pro_5.0/montavista/common/* /opt/mv_pro_5.0/montavista/common/share/*
cd /tmp

# XDC tools
./xdctools_setuplinux_3_10_03.bin --mode console -prefix $HOME

# DSPBios
./bios_setuplinux_5_33_03.bin --mode console --prefix $HOME

# C64 Toolchain
./TI-C6x-CGT-v6.0.21.1.bin --mode console --prefix $HOME/cg6x_6_0_21

# DM6467 codecs
./dm6467_codecs_setuplinux_2_00_00_22.bin --mode console --prefix $HOME/dvsdk_2_00_00_22

# kernel working copy
mkdir -p $HOME/workdir/lsp/ti-davinci
cp -R /opt/mv_pro_5.0/montavista/pro/devkit/lsp/ti-davinci/* $HOME/workdir/lsp/ti-davinci

# target file system working copy
mkdir -p $HOME/workdir/filesys  $HOME/workdir/lsp/ti-davinci
sudo cp -a /opt/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le/target/* $HOME/workdir/filesys
sudo chown -R $USER $HOME/workdir/filesys/opt

Tested on:


DM6467T software installation (DVSDK 3.10.00.19)

These are simplified steps based on the instructions in DVSDK 3.10.00.19 release notes and other documentation mentioned therein.

Copy the downloaded toolchain, kernel, DVSDK and related packages for your target processor into the /tmp directory so that your machine has the following files:

/tmp/arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
/tmp/dvsdk_3_10_00_19_Setup.bin
/tmp/cs2dm6467_1_00_00_10_Setup.bin
/tmp/linux-davinci-staging.tar.gz
/tmp/linuxlibs-2009.11-armv5te.tar.gz
/tmp/arago-demo-image-dm6467t-evm.tar.gz
/tmp/gst-ti-plugin-full-1.02.00.tar.gz

Install all the needed tools and components:

DOWNLOAD_DIR=/tmp

# toolchain
cd /opt
sudo tar -xjf $DOWNLOAD_DIR/arm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

# DVSDK
chmod ugo+x $DOWNLOAD_DIR/dvsdk_3_10_00_19_Setup.bin
echo -e 'y\n qy' | $DOWNLOAD_DIR/dvsdk_3_10_00_19_Setup.bin --mode console

# Codec Server
chmod ugo+x $DOWNLOAD_DIR/cs2dm6467_1_00_00_10_Setup.bin
echo -e 'y\n qy' | $DOWNLOAD_DIR/cs2dm6467_1_00_00_10_Setup.bin --mode console

# Linux kernel
cd $HOME/dvsdk
tar -xzf $DOWNLOAD_DIR/linux-davinci-staging.tar.gz

# linuxlibs
cd $HOME/dvsdk
tar -xzf $DOWNLOAD_DIR/linuxlibs-2009.11-armv5te.tar.gz

# GStreamer DMAI plug-in
cd $HOME
tar -xzf $DOWNLOAD_DIR/gst-ti-plugin-full-1.02.00.tar.gz

# target file system
mkdir -p $HOME/install/dm6467t_fs
cd $HOME/install/dm6467t_fs
sudo tar -xzf $DOWNLOAD_DIR/arago-demo-image-dm6467t-evm.tar.gz
sudo chown -R --reference=$HOME $HOME/install/dm6467t_fs

OMAP35xx software installation (DVSDK 3.00.02.44)

This are a summary of the steps listed in GSG: OMAP35x DVEVM Software Setup.

cd /tmp
chmod ugo+x *.bin

# DVSDK
./dvsdk_setuplinux_3_00_02_44.bin --mode console --prefix $HOME

# PSP
mkdir -p $HOME/workdir/opt
./OMAP35x-PSP-SDK-setuplinux-02.01.03.11.bin --mode console --prefix $HOME
cd $HOME/workdir/opt
tar -xzf $HOME/OMAP35x-PSP-SDK-02.01.03.11/src/kernel/linux-02.01.03.11.tar.gz 
tar -xzf $HOME/OMAP35x-PSP-SDK-02.01.03.11/src/u-boot/u-boot-02.01.03.11.tar.gz

# Target file system
mkdir -p $HOME/workdir/filesys
cd $HOME/workdir/filesys
sudo tar -xzf /tmp/nfs_dvsdk_3_00_02_44.tar.gz 
sudo chown -R $USER $HOME/workdir/filesys/opt

# XDC tools
cd /tmp
./xdctools_setuplinux_3_15_01_59.bin --mode console --prefix $HOME/dvsdk_3_00_02_44

# DSPBios
./bios_setuplinux_5_33_06.bin --mode console --prefix $HOME/dvsdk_3_00_02_44

# C64 Toolchain
./TI-C6x-CGT-v6.0.16.1.bin --mode console --prefix $HOME/dvsdk_3_00_02_44/cg6x_6.0.16

# OMAP3 codecs
./cs1omap3530_setuplinux_1_00_01-44.bin --mode console --prefix $HOME/dvsdk_3_00_02_44

# MP3 decode codec
# To be written

Building the libraries and tools

There is a detailed Getting Started Guide that is part of the DVSDK. The steps described below are simplifed version of the more complete steps listed in the guide. For the full DVSDK instructions, refer to the HTML files in the DVSDK directory and the docs directory inside the DVSDK directory.


Building DM355 kernel, DVSDK, and GStreamer software (DVSDK 3.10.00.19)

The target file system includes a pre-built DVSDK, so there is no need to build the DVSDK. There is also a pre-built kernel image, so the Linux kernel doesn't need to be built either. Instructions on how to build the DVSDK and kernel are included for completeness.

# Build kernel (optional, pre-built kernel is available for download)
cd $HOME/dvsdk/git
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- distclean
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- davinci_dm355_defconfig
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- prepare _all modules 
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- uImage

# build DVSDK (optional, target file system has DVSDK already installed)
cd $HOME/dvsdk/dvsdk_3_10_00_19
make TARGET_ROOT_DIR=$HOME/install/dm355_fs PLATFORM=dm355 clean 
make TARGET_ROOT_DIR=$HOME/install/dm355_fs PLATFORM=dm355 check cmem dmai install

# build gst-dmai plug-in
cd $HOME/gst-ti-plugin-full-1.02.00
make DVSDK_INSTALL_DIR=$HOME/dvsdk/dvsdk_3_10_00_19 TARGET_ROOT_DIR=$HOME/install/dm355_fs PLATFORM=dm355 all install


Building DM365 kernel, DVSDK, and GStreamer software (DVSDK 3.10.00.19)

The target file system includes a pre-built DVSDK, so there is no need to build the DVSDK. There is also a pre-built kernel image, so the Linux kernel doesn't need to be built either. Instructions on how to build the DVSDK and kernel are included for completeness.

# Build kernel (optional, pre-built kernel is available for download)
cd $HOME/dvsdk/git
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- distclean
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- davinci_dm365_defconfig
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- prepare _all modules 
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- uImage

# build DVSDK (optional, target file system has DVSDK already installed)
cd $HOME/dvsdk/dvsdk_3_10_00_19
make TARGET_ROOT_DIR=$HOME/install/dm365_fs PLATFORM=dm365 clean 
make TARGET_ROOT_DIR=$HOME/install/dm365_fs PLATFORM=dm365 check cmem dmai install

# build gst-dmai plug-in
cd $HOME/gst-ti-plugin-full-1.02.00
make DVSDK_INSTALL_DIR=$HOME/dvsdk/dvsdk_3_10_00_19 TARGET_ROOT_DIR=$HOME/install/dm365_fs PLATFORM=dm365 all install


Building DM6446 kernel, DVSDK, and GStreamer software (2.00.00.22)

export PATH="/opt/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le/bin:/opt/mv_pro_5.0/montavista/pro/bin:/opt/mv_pro_5.0/montavista/common/bin:$PATH"

# Build kernel
cd $HOME/workdir/lsp/ti-davinci/linux-2.6.18_pro500
make ARCH=arm CROSS_COMPILE=arm_v5t_le- distclean davinci_dm644x_defconfig 
make ARCH=arm CROSS_COMPILE=arm_v5t_le- prepare _all modules 

# build DVSDK (the package seems to have derived files, so make clean first)
cd $HOME/dvsdk_2_00_00_22
make DVSDK_INSTALL_DIR=$HOME/dvsdk_2_00_00_22 TARGET_ROOT_DIR=$HOME/workdir/filesys CROSS_COMPILER=MVL_5_0 \
     CODEGEN_INSTALL_DIR=$HOME/cg6x_6_0_21 CODEC_INSTALL_DIR=$HOME/dvsdk_2_00_00_22/dm6446_dvsdk_combos_2_05 \
     PLATFORM=dm6446 clean
make DVSDK_INSTALL_DIR=$HOME/dvsdk_2_00_00_22 TARGET_ROOT_DIR=$HOME/workdir/filesys CROSS_COMPILER=MVL_5_0 VERBOSE=1 \
     CODEGEN_INSTALL_DIR=$HOME/cg6x_6_0_21 CODEC_INSTALL_DIR=$HOME/dvsdk_2_00_00_22/dm6446_dvsdk_combos_2_05 \
     PLATFORM=dm6446 clean check cmem  dmai install

# build gst-dmai plug-in
cd $HOME/gst-ti-plugin-full-1.01.00
echo=echo make DVSDK_INSTALL_DIR=$HOME/dvsdk_2_00_00_22 TARGET_ROOT_DIR=$HOME/workdir/filesys CROSS_COMPILER=MVL_5_0 \
    CODEGEN_INSTALL_DIR=$HOME/cg6x_6_0_21 CODEC_INSTALL_DIR=$HOME/dvsdk_2_00_00_22/dm6446_dvsdk_combos_2_05 \
    VERBOSE=1 PLATFORM=dm6446 all install


Building DM6467 DVSDK (2.00.00.22)

export PATH="/opt/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le/bin:/opt/mv_pro_5.0/montavista/pro/bin:/opt/mv_pro_5.0/montavista/common/bin:$PATH"

# Build kernel
cd $HOME/workdir/lsp/ti-davinci/linux-2.6.18_pro500
make ARCH=arm CROSS_COMPILE=arm_v5t_le- distclean davinci_dm6467_defconfig 
make ARCH=arm CROSS_COMPILE=arm_v5t_le- prepare _all modules 

# build DVSDK (the package seems to have derived files, so make clean first)
cd $HOME/dvsdk_2_00_00_22
make DVSDK_INSTALL_DIR=$HOME/dvsdk_2_00_00_22 TARGET_ROOT_DIR=$HOME/workdir/filesys CROSS_COMPILER=MVL_5_0 PLATFORM=dm6467 \
    CODEGEN_INSTALL_DIR=$HOME/cg6x_6_0_21 CODEC_INSTALL_DIR=$HOME/dvsdk_2_00_00_22/dm6467_dvsdk_combos_2_05 \
    clean
make DVSDK_INSTALL_DIR=$HOME/dvsdk_2_00_00_22 TARGET_ROOT_DIR=$HOME/workdir/filesys CROSS_COMPILER=MVL_5_0 VERBOSE=1 PLATFORM=dm6467 \
    CODEGEN_INSTALL_DIR=$HOME/cg6x_6_0_21 CODEC_INSTALL_DIR=$HOME/dvsdk_2_00_00_22/dm6467_dvsdk_combos_2_05 \
    clean check cmem  dmai install

# need to use a newer version of pkg-config
pkg-config --version
cd $HOME/gst-ti-plugin-full-1.01.00/opensource_build/host_tools
tar -xzf pkgconfig-0.18.tar.gz
cd pkgconfig-0.18
./configure --prefix=/opt/mv_pro_5.0/montavista/pro  # the version in the toolchain is too old, so we replace it
make
sudo rm -f /opt/mv_pro_5.0/montavista/pro/bin/pkg-config
sudo make install

# build gst-dmai plug-in
cd $HOME/gst-ti-plugin-full-1.01.00
echo=echo make DVSDK_INSTALL_DIR=$HOME/dvsdk_2_00_00_22 TARGET_ROOT_DIR=$HOME/workdir/filesys CROSS_COMPILER=MVL_5_0 \
    CODEGEN_INSTALL_DIR=$HOME/cg6x_6_0_21 CODEC_INSTALL_DIR=$HOME/dvsdk_2_00_00_22/dm6467_dvsdk_combos_2_05 \
    VERBOSE=1 PLATFORM=dm6467 all install

Tested on:


Building DM6467T kernel, DVSDK, and GStreamer software (DVSDK 3.10.00.19)

The target file system includes a pre-built DVSDK, so there is no need to build the DVSDK. There is also a pre-built kernel image, so the Linux kernel doesn't need to be built either. Instructions on how to build the DVSDK and kernel are included for completeness.

# Build kernel (optional, pre-built kernel is available for download)
cd $HOME/dvsdk/git
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- distclean
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- davinci_dm646x_defconfig
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- prepare _all modules 
make -j 3 ARCH=arm CROSS_COMPILE=/opt/arm-2009q1/bin/arm-none-linux-gnueabi- uImage

# build DVSDK (optional, target file system has DVSDK already installed)
cd $HOME/dvsdk/dvsdk_3_10_00_19
make TARGET_ROOT_DIR=$HOME/install/dm6467t_fs PLATFORM=dm6467 clean 
make TARGET_ROOT_DIR=$HOME/install/dm6467t_fs PLATFORM=dm6467 check cmem dmai install

# build gst-dmai plug-in
cd $HOME/gst-ti-plugin-full-1.02.00
Edit the Makefile.common and set GST_TI_PLATFORM = dm6467t (defined at line 46)
make DVSDK_INSTALL_DIR=$HOME/dvsdk/dvsdk_3_10_00_19 TARGET_ROOT_DIR=$HOME/install/dm6467t_fs PLATFORM=dm6467 all install

Building OMAP35xx DVSDK (3.00.02.44)

This are a summary of the steps listed in GSG: OMAP35x DVEVM Software Setup.

export PATH="$HOME/toolchain/arm-2008q1/bin:$PATH"

# optional, build kernel
cd workdir/opt/linux-02.01.03.11
make CROSS_COMPILE=arm-none-linux-gnueabi- ARCH=arm distclean
make CROSS_COMPILE=arm-none-linux-gnueabi- ARCH=arm omap3_evm_defconfig
make CROSS_COMPILE=arm-none-linux-gnueabi- ARCH=arm prepare _all modules uImage

# optional, build u-boot
cd $HOME/workdir/opt/uboot-02.01.03.11
make CROSS_COMPILE=arm-none-linux-gnueabi- ARCH=arm distclean
make CROSS_COMPILE=arm-none-linux-gnueabi- ARCH=arm omap3_evm_config
make CROSS_COMPILE=arm-none-linux-gnueabi- ARCH=arm

# optional, build codec server
cd $HOME/dvsdk_3_00_02_44/cs1omap3530_1_00_01
make CSTOOL_DIR=$HOME/toolchain/arm-2008q1 LINUXKERNEL_INSTALL_DIR=$HOME/workdir/opt/linux-02.01.03.11 \
     UBOOT_INSTALL_DIR=$HOME/workdir/opt/uboot-02.01.03.11 \
     CROSS_COMPILER=arm-none-linux-gnueabi- PLATFORM=omap3530 VERBOSE=1

# optional, build DVSDK
cd $HOME/dvsdk_3_00_02_44
make CSTOOL_DIR=$HOME/toolchain/arm-2008q1 LINUXKERNEL_INSTALL_DIR=$HOME/workdir/opt/linux-02.01.03.11 \
     UBOOT_INSTALL_DIR=$HOME/workdir/opt/uboot-02.01.03.11 CROSS_COMPILER=arm-none-linux-gnueabi- PLATFORM=omap3530 check
make CSTOOL_DIR=$HOME/toolchain/arm-2008q1 LINUXKERNEL_INSTALL_DIR=$HOME/workdir/opt/linux-02.01.03.11 \
     UBOOT_INSTALL_DIR=$HOME/workdir/opt/uboot-02.01.03.11 CROSS_COMPILER=arm-none-linux-gnueabi- PLATFORM=omap3530 clean
make CSTOOL_DIR=$HOME/toolchain/arm-2008q1 LINUXKERNEL_INSTALL_DIR=$HOME/workdir/opt/linux-02.01.03.11 \
     UBOOT_INSTALL_DIR=$HOME/workdir/opt/uboot-02.01.03.11 CROSS_COMPILER=arm-none-linux-gnueabi- PLATFORM=omap3530 all install

# build zlib
cd $HOME/workdir/opt/zlib-1.2.3
./configure
make CC=arm-none-linux-gnueabi-gcc LDSHARED=arm-none-linux-gnueabi-gcc CPP="arm-none-linux-gnueabi-gcc -E" \
     AR="arm-none-linux-gnueabi-ar rc" RANLIB=arm-none-linux-gnueabi-ranlib 
sudo make install prefix=$HOME/workdir/filesys

# build gst-dmai plug-in
cd $HOME/gst-ti-plugin-full-1.01.00 
echo=echo make DVSDK_INSTALL_DIR=$HOME/dvsdk_3_00_02_44 TARGET_ROOT_DIR=$HOME/workdir/filesys \
     CROSS_COMPILER=arm-none-linux-gnueabi- LINUXKERNEL_INSTALL_DIR=$HOME/workdir/opt/linux-02.01.03.11 \
     CSTOOL_DIR=$HOME/toolchain/arm-2008q1 VERBOSE=1 PLATFORM=omap3530 all install

Running test pipelines

There are many Example GStreamer Pipelines for you to try. If you come up with some clever ones of your own, please add the pipelines to the wiki.

Creating your first GStreamer application

To be written

Resolving known problems

../libtool: line 763: X--tag=CC: command not found

The libtool on your host computer is causing the problem (using $(echo) when it is not defined). Either install an older libtool version (1.5.26) or define the echo environment variable.

export echo=echo


../libtool: eval: line 4174: syntax error near unexpected token `|

This error happens when generating symbol list for `libgstticodecplugin.la'.

This error may occur when building with releases older than 1.01. The problem was fixed in SVN trunk@275.

In the top level GStreamer TI Makefile.common file (e.g. Makefile.common in gstreamer_ti or gst-ti-plugin-full-1.00.02), change CC_CONFIGURE_OPTS from:

CC_CONFIGURE_OPTS        = --build=i686-linux --host=arm-linux \
                           --prefix=$(TARGET_GSTREAMER_DIR)

to

CC_CONFIGURE_OPTS        = --build=i686-linux --host=arm-linux \
                           --prefix=$(TARGET_GSTREAMER_DIR)    \
                           NM=$(MVTOOL_PREFIX)nm

v4l2src build error - V4L2_STD_525P_60 undefined

See V4L2_STD_525P_60 undefined error for details.

In the gstreamer_ti/opensource_build/Packages.make, add to the end of the following like as shown:

PACKAGE_plugins_good_CONFIGURE_OPTS      = $(USE_V4L2SRC_WORKAROUND) --disable-x

If the error persists, verify you have a trailing slash in the paths specified in the DSDK Rules.make file.

error: asm/arch/imp_resizer.h: No such file or directory

Something is amiss with your kernel. If you issued a make command like

make ... LINUXKERNEL_INSTALL_DIR= ...

then first check that the Linux kernel is at the specified location. For instance, if you have

make DVSDK_INSTALL_DIR=$HOME/dvsdk_2_10_01_18 TARGET_ROOT_DIR=$HOME/workdir/filesys CROSS_COMPILER=MVL_5_0 \
     LINUXKERNEL_INSTALL_DIR=$HOME/workdir/lsp/ti-davinci/linux-2.6.18_pro500 VERBOSE=1 PLATFORM=dm365 all install

then try

ls -ld $HOME/workdir/lsp/ti-davinci/linux-2.6.18_pro500

If you get an error, that means the kernel source is not where you think it is located.

If you don't get an error, then verify the symbolic link for the architecture directory was properly created.

ls -ld $HOME/workdir/lsp/ti-davinci/linux-2.6.18_pro500/include/asm/arch

If you get an error, that means you didn't build the kernel correctly.

"mkimage" command not found - U-Boot images will not be built

This means that you don't have the mkimage package installed at your host machine

 sudo apt-get install uboot-mkimage

and try building again

configure:error:c++ preprocessor "/lib/cpp" fails sanity check

This means that you don't have the build-essential package installed at your host machine

 sudo apt-get install build-essential

and try building again

/bin/sh: 1: not found

There are different variations of the error message displayed. What the error has in common is an unexpected characters in injected before a shell command.

The problem is caused by XDC not liking a period '.' in directory names. Rename the directory and then do a

 make clean

and try again.