This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Installing gst-plugins into Sitara SDK v7.0

I am trying to build and install gst-plugins-bad unto Sitara SDK v7.0.

The SDK had gstreamer-0.10 and gst-plugin-bad old versions preinstall into it.

Since I wanted to install on of the latest gst-plugins-bad (v1.4.0), I found from reading discussion forums that I needed latest gstreamer-1.x as gstreamer base to be able to install latest gst-plugins.

I went on and installed latest gstreamer (v1.4.0) unto this Sitara SDK v7. 

So now, I have both versions into my SDK: gstreamer-0.10 and gstreamer-1.4.0.

I tested the newly install gstreamer-1.4.0 (gst-launch-1.0) and it works well on my Sitara board.

Now I try to configure my environment to build and install gst-plugins-bad-1.4.0:

I followed instructions from section "Configure/Autotools" from "Sitara Linux SDK GCC Toolchain" TI web page (http://processors.wiki.ti.com/index.php/Sitara_Linux_SDK_GCC_Toolchain#Usage).

Unfortunately, when I run following command to configure my host system (from gst-plugin-bad-1.4.0 folder installed in my Ubuntu) , I am getting an un-logical error about gstreamer version mismatch!!!!!!

//////////////////////////////////////////////////////////////////////////////////////////////////////////

$ ./configure --host=i686 --disable-deinterlace2 --disable-x264  

.....

....

checking for glib-mkenums... glib-mkenums
checking for GIO... yes
checking for GST... no
configure: No package 'gstreamer-1.0' found
configure: error: no gstreamer-1.0 >= 1.4.0 (GStreamer) found

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

I already have gstreamer-1.4.0 installed in the SDK and it run fine on my Sitara target, so I do not understand the meaning of this error!!!!

Is TI ever came across this kind of issue when integrating gstreamer and its plugins into their Sitara SDKs?

  • Moving this to the Linux forum.

  • Hello,

    I haven't tried to compile gstreamer 1.0 for Sitara.

    Here is the dependence between the plugins.

    GStreamer-1.4.1 required GLib-2.40.0;

    gst-plugins-base-1.4.1 required GStreamer-1.4.1;

    gst-plugins-good-1.4.1 required gst-plugins-base-1.4.1;

    gst-plugins-bad-1.4.1 required gst-plugins-base-1.4.1;

    gst-plugins-ugly-1.4.1 required gst-plugins-base-1.4.1.

    PatEleph said:
    configure: No package 'gstreamer-1.0' found
    configure: error: no gstreamer-1.0 >= 1.4.0 (GStreamer) found

    Possible reasons for this error:

    1.You have an older versions installed on your system.

    2.You are not using dev version.

    3. Check the prefix that you are using, export paths in the make files etc.

    ./configure --host=arm-none-linux-gnueabi --build=i686-linux ...

    Best Regards,

    Margarita

  • Thank you Margarita for the leads you provided.

    I was able to install gstreamer-1.4.0 and was trying to build and install gst-plugins-bad-1.4.0.

    when I run "make" on gst-plugins-bad-1.4.0, I got an error that gst-plugins-base-1.4.0 was needed.

    I went on and got that package (gst-plugin-base-1.4.0) and now I am running into issue with configuring this package after I source the environment-setup script available under /ti-sdk-am335x-evm-07.00.00.00/linux-devkit/.

    Here is the problem description:

    I am trying to cross compile gst-plugins-1.4.0 package (issue is also happening with any newer versions of gst-plugins-base coming from http://gstreamer.freedesktop.org/src/gst-plugins-base/) .

    I am in TI SDK v 7.0 for AM335x linux environment.

    I first run:

    source <SDK INSTALL DIR>/linux-devkit/environment-setup

    Then I tried to configure the package for cross-compilation: $./configure --host=i686

    But for some reasons, after above configure command run, I got a auto-generated Makefile (under gst-plugins-base-1.4.0/) that has issues.

    On the line where GST_BASE_CFLAGS is defined in this Makefile, the path there, is DUPLICATED: I am getting the following:

    GST_BASE_CFLAGS = -pthread -I/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    obviously, this becomes a "path not found" error when I try to compile later the package!

    Same duplicated directory is also seen with following flags settings in all auto-generated Makefiles under the gst-plugins-1.4.0 package after I run the ./configure ... command:

    GST_BASE_CFLAGS = -pthread -I/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_BASE_LIBS = -L/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_CFLAGS = -pthread -I/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_CHECK_CFLAGS = -pthread -I/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_CHECK_LIBS = -L/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_CONTROLLER_CFLAGS = -pthread -I/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_CONTROLLER_LIBS = -L/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_CXXFLAGS = -pthread -I/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    GST_LIBS = -L/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

    With a little of debugging, I found that following line, for example, from the configure script (line #23838) is introducing the duplicated directoried lines, but I can't understand how to fix it; may be it is reading twice the environment PATH variable set from the /linux-devkit/environment-setup script :

    Here is the line #23838 from the configure script from gst-plugins-1.4.0 package:

    pkg_cv_GST_BASE_CFLAGS=$PKG_CONFIG --cflags "$module >= $minver" 2>/dev/null

    I found out after this line, I get the buggy setting for GST_BASE_CFLAGS in the generated Makefile: GST_BASE_CFLAGS = -pthread -I/<PKG_CONFIG_SYSROOT_DIR>/<PKG_CONFIG_SYSROOT_DIR>/usr/...

     There seems to be conflict between TI-SDK enviroment-setup script and the configure script of the gst-plugins-base package!!!!

     

    Any thoughts?

  • Hello,

    If you are trying to execute ./configure or ./configure --host=.... when you are in the current gstremer plugin directory it will fail with the

    configure: No package 'gstreamer-1.x' found
    configure: error: no gstreamer-1.x >= 1.x(GStreamer) found

    It will use autogen makefile.

    Could you try something like and let me know:

    gst_configure:
        . $(DVSDK_INSTALL_DIR)/linux-devkit/environment-setup; \
            cd $(GST_INSTALL_DIR)/; \
            ./configure --host=arm-none-linux-gnueabi

    gstomx: gstomx_configure
        . $(DVSDK_INSTALL_DIR)/linux-devkit/environment-setup; \
            make -C $(GST_INSTALL_DIR) $(GST_BUILD_VARS)

    gstomx_clean: gstomx_configure
        . $(DVSDK_INSTALL_DIR)/linux-devkit/environment-setup; \
            make -C $(GST_INSTALL_DIR) $(GST_BUILD_VARS) clean distclean

    gstomx_install:
        . $(DVSDK_INSTALL_DIR)/linux-devkit/environment-setup; \
            make -C $(GST_INSTALL_DIR) $(GST_BUILD_VARS) install prefix=$(EXEC_DIR)/usr

    Where :

    DVSDK_INSTALL_DIR path to the TI-SDK

    GST_INSTALL_DIR path to the GST directory

    Trace the make files.

    Best Regards,

    Margarita

  • Thank you Margarita,

    I finally was able to build the gst-plugins-bad and I have installed it to my TI-EVM AM335x board.

    From the targetNFS/usr/lib/gsteamer-1.0/ directory from my arget device, I can can see all the .so libs from the this new gst-plugins-1.4.0.

    But when i run gst-inspect-1.0, I there only 2 plugins, however I have more than 100 .so libs in targetNFS/usr/lib/gstreamer-1.0.

    How can I enable the installed plugins?

  • Hello,

    I would recommend you to move all the plugins to version 1.0 not only the base and the bad plugin.

    Could you post what you are seeing when you are executing gst-inspect command.

    Best Regards,

    Margarita

  • gst-inspect-1.0 is available under targetNFS/usr/bin/. This is what I see:

    root@am335x-evm:~# gst-inspect-1.0
    staticelements:  bin: Generic bin
    staticelements:  pipeline: Pipeline object

    Total count: 1 plugin, 2 features
    root@am335x-evm:~#

    When you say to try version 1.0, are you suggesting to use gst-plugins-base-1.0 and gst-plugins-1.0? I was using gst-plugins-base-1.4.0 and gst-plugins-base-1.4.0 which are the latest versions; I got them from http://gstreamer.freedesktop.org/src/

  • Hello,

    I meant to update the

    gst-plugins-good-1.4

    gst-plugins-ugly-1.4 etc,as well.

    Best Regards,

    Margarita

  • Hello,

    PatEleph said:

    root@am335x-evm:~# gst-inspect-1.0
    staticelements:  bin: Generic bin
    staticelements:  pipeline: Pipeline object

    Total count: 1 plugin, 2 features
    root@am335x-evm:~#

    In this case probably you will not see any gstreamer elements (like filesrc etc).

    You could try two things:

    --Run gst-inspect on a plugin .so directly (absolute path), to  check if it works at all. If it does, something is
    wrong with the plugin path or system path. Try to export the library path, plugin path.

    -- You could check the GST_DEBUG log to see where it is looking for plugins and/or what it is trying to do:

    GST_DEBUG=*:7 gst-inspect-0.10

    Best Regards,
    Margarita

  • Thank you Margarita.

    When I run gst-inspect with the absolute path, I do get the description of the plugin .so that I called.

    When I run the GST_DEBUG=.... I saw that the gst-inspect-1.0 tool is looking for the libs in the wrong place.

    That means that I have a PATH setting issue. I am working on it to get it fix. I will post an update once i resolve the issue.

     

  • Hello,

    Let me know the result for further help.

    Best Regards,

    Margarita

  • Sorry, I have a side question:

    Do you know if installing gstreamer.-1.0 in a linux envirenment, there is a minimum version of the linux version required?

    For example: Is gstreamer-1.0 (or latest version) would require at least Linux version 3.xx ...?

     

  • Hello,

    You could try to check in the http://gstreamer.freedesktop.org/ side for the requirements.

    Best Regards,

    Margarita

  • Hi,

    I was able to fix the path issue but now the plugin (opus) does not show up in the list of available plugins when I run gst-inspect-1.0

    gst-inspect-1.0 shows this newly built plugins is BLACKLISTED and with 0 features!!!:

    # gst-inspect-1.0 /path/to/libgstopus.so
    Plugin Details:
    Name libgstopus.so
    Description Plugin for blacklisted file
    Filename  /path/to//libgstopus.so
    Version 0.0.0
    License BLACKLIST
    Source module BLACKLIST
    Binary package BLACKLIST
    Origin URL BLACKLIST

    0 features:

    Any thoughts on this?

  • Hello,

    Could you try something before to run gst-inspect remove the old plugin cache,

    rm -rf /path / (remove the old plugin cache)
    export GST_PLUGIN_PATH=/usr/.../lib/gstreamer-1.X

    gst-inspect

    this shall rebuild the cache with the new components.

    Best Regards,

    Margarita

  • I could not find any .xml cache files.. or are you familiar with the directories or file names of these plugin cache files? where can I find and delete them?

    I did export the GST_PLUGIN_PATH as you recommended, and it also looks like I was missing libopus.so.0 library from /usr/lib/ directory. After I copied libopus.so.0 into /usr/lib/ , now by running gst-inspect-1.0 on libgstopus.so, I now get a correct description of that plugin:

    $ gst-inspect-1.0 <path-to-gst-plugins>/gstreamer-1.0/libgstopus.so

    ///////////////////////////////////////////////

    Name opus
    Description OPUS plugin library
    Filename <path-to-gst-plugins>/gstreamer-1.0/libgstopus.so
    Version 1.4.0
    License LGPL
    Source module gst-plugins-bad
    Source release date 2014-07-19
    Binary package GStreamer Bad Plug-ins source release
    Origin URL Unknown package origin

    opusenc: Opus audio encoder
    opusdec: Opus audio decoder
    opusparse: Opus audio parser
    rtpopusdepay: RTP Opus packet depayloader
    rtpopuspay: RTP Opus payloader

    5 features:
    +-- 5 elements
    //////////////////////////////////////////

    The problem now is that when I run just gst-inspect-1.0, these 5 desired features of opus (opusenc, opusdec, ...) are not showing up the list of available plugins. It looks like it is still in BLACKLIST!

    I then run :

    $ GST_DEBUG=*:7 GST_DEBUG_FILE=mydebug.log gst-inspect-1.0


    and looking into the debug file (mydebug.log) I still see the libgstopus describe as BLACKLIST by the GST_REGISTRY!!

    Here is a snippet og the log file

    ////////////////////////////

    GST_REGISTRY gstregistrychunks.c:828:_priv_gst_registry_chunks_load_plugin: read strings for name='libgstopus.so' 
    GST_REGISTRY gstregistrychunks.c:829:_priv_gst_registry_chunks_load_plugin: desc.description='Plugin for blacklisted file' 
    GST_REGISTRY gstregistrychunks.c:830:_priv_gst_registry_chunks_load_plugin: filename='<path-to-gst-plugins>/gstreamer-1.0/libgstopus.so'
    GST_REGISTRY gstregistrychunks.c:831:_priv_gst_registry_chunks_load_plugin: desc.version='0.0.0' 
    GST_REGISTRY gstregistrychunks.c:832:_priv_gst_registry_chunks_load_plugin: desc.license='BLACKLIST' 
    GST_REGISTRY gstregistrychunks.c:833:_priv_gst_registry_chunks_load_plugin: desc.source='BLACKLIST' 
    GST_REGISTRY gstregistrychunks.c:834:_priv_gst_registry_chunks_load_plugin: desc.package='BLACKLIST' 
    GST_REGISTRY gstregistrychunks.c:835:_priv_gst_registry_chunks_load_plugin: desc.origin='BLACKLIST' 
    GST_REGISTRY gstregistrychunks.c:836:_priv_gst_registry_chunks_load_plugin: desc.datetime= 
    GST_REGISTRY gstregistry.c:476:gst_registry_add_plugin:<registry0> adding plugin 0x39c08 for filename "<path-to-gst-plugins>/gstreamer-1.0/libgstopus.so"
    m GST_REFCOUNTING gstobject.c:306:gst_object_ref_sink:<plugin15> 0x39c08 ref_sink 1->2 
    GST_REGISTRY gstregistry.c:487:gst_registry_add_plugin:<registry0> emitting plugin-added for filename "<path-to-gst-plugins>/gstreamer-1.0/libgstopus.so"
    GST_REGISTRY gstregistrychunks.c:857:_priv_gst_registry_chunks_load_plugin: Added plugin 'libgstopus.so' plugin with 0 features from binary registry

    ////////////////////////////////////////////////////////////////////////////////

    So, the problem now is that the binary GST registry is not registering the plugin correctly with the few fixes that I did (set GST_PLUGIN_PATH, put libopus.so.0 in the /ust/lib/ directory)!!

    May be this is related to the cache cleaning that you recommended or  how could I get the binary registry (may be GST_REGISTRY) to parse this libgstopus plugin correctly?

  • GOOD NEWS! I finally found the cache registry in /home/root/.cache/gstreamer-1.0 on my targetNFS and the file was "registry.arm.bin"

    After I deleted this file and run gst-inspect-1.0, Bang! now opus features (opusenc, opusdec, opusparse, rtpopusdepay, rtpopuspay) show up in the list of plugins! :-)

    Thanks a LOT for your great support. really appreciated. I will now try to experiment the functionality of those features to make sure they work as expected. I Will close the thread afterwards.

  • For further testing, I need to install more gst-plugins packages (good, ugly).

    I want to come back on one of my first question I have asked in this thread regarding DUPLICATED PATH in the Makefiles of the gst-plugin package after I run its ./configure script.

    Last time, I have to hack it a bit to get it to work by re-editing all the auto-generated Makefiles (removing one of the duplicated PATH).

    I know you have said to source the environment before running the ./configure and that is was I was doing:

    Here is again the main 3 steps to reproduce the problem and I am sure you can easily replicate it on you side if you have the am335x TI SDKv7.0 installed.

    1. $ cd to ~/ti-sdk-am335x-evm-07.00.00.00/linux-devkit

    2. $ source environment-setup

    This sets up the SDK environment variables.

    Now the terminal command line looks like this:

    [linux-devkit]:~/ti-sdk-am335x-evm-07.00.00.00/linux-devkit>

    Then I change directory (cd)  to the gst-plugins-bad-1.4.0 directory I have and run the ./configure.. :

    3. [linux-devkit]:~/gst-plugins-bad-1.4.0> ./configure --host=arm-linux-gnueabihf --prefix=/usr

    After this command,  all the generated Makefiles in this directory and sub-directories of gst-plugins-bad-1.4.0 have a DUPLICATED PATH!!!!!!!:

    for example, this is what I could see in the main Makefile (gst-plugins-bad-1.4.0/Makefile)

    ......

    GST_BASE_CFLAGS = -pthread -I/<path to -sysroot-dir>/<path to -sysroot-dir>/usr/...

    ......

    • obviously, this becomes a "path not found" error when I try to compile later the package!

    I had to make up a script using linux "grep" and "sed" commands to hack (delete) the duplicate path from all 50+ Makefiles autogenerated  in the gst-plugin-bad-1.4.0 directory/sub-directories.

    I think, there is an issue with my default SDK environment variables after I source it with the "environment-setup" script available in the SDK!!

    Any idea on this?

  • Hello,

    I will check, unfortunately I can not reproduce it since I do not have am335x.

    Best Regards,

    Margarita

  • Hello,

    I would recommended you to check makefile.in and configure.ac in the main directories based on these files the makefile is generated. You could change this files. Notice that in the configure.ac file you have for example :

    AC_CONFIG_FILES([Makefile \
             omx/Makefile \
             util/Makefile \
             m4/Makefile]

    these are makefile.in which will be taken and based on them it will generate the makefiles in the their current directories. You could check also this http://www.gnu.org/software/autoconf/ about the autoconfig.

    Hope this helps.

    Best Regards,

    Margarita

  • I have checked the configure.ac and the Makefile.in files and cannot see anything suspiscious.

    You do not need an AM335x HW to reproduce the issue. Just need:

    1.Install unto a linux machine, the AM335x SDKv7.0 (download install bin from http://downloads.ti.com/sitara_linux/esd/AM335xSDK/latest/index_FDS.html)

    2. untar the gst-plugins-bad-1.4.0 (download from http://gstreamer.freedesktop.org/src/gst-plugins-bad/)

    then the 3 steps to reproduce the issue I mentioned before:

    • 1. $ cd to ~/ti-sdk-am335x-evm-07.00.00.00/linux-devkit

      2. $ source environment-setup

      This sets up the SDK environment variables.

      Now the terminal command line looks like this:

      [linux-devkit]:~/ti-sdk-am335x-evm-07.00.00.00/linux-devkit>

      Then change directory (cd)  to the gst-plugins-bad-1.4.0 directory you have and run the ./configure.. :

      3. [linux-devkit]:~/gst-plugins-bad-1.4.0> ./configure --host=arm-linux-gnueabihf --prefix=/usr

    OPEN THE MAIN Makefile (gst-plugins-bad-1.4.0/Makefile) and search for GST_BASE_CFLAGS and look at the path!

  • Hello,

    I will try to reproduce it soon.

    I will let you know.

    Best Regards,

    Margarita

  • Margarita,

    Any luck in reproducing this PATH issues in the gst-plugins Makefiles configured under TI am335x SDK?

  • Hello,

    I have not check it.

    You are able to integrate the new gstreamer plugins 1.4 right?

    Best Regards,

    Margarita

  • Yes, I finally got it to work with some hacks(I manually re-edited the Makefiles to fix the bug related to duplicate PATH that I mentionned in this discussion threads).

    I am looking for help to catch and understand the root cause of that bug so that the generated Makefiles don't carry such issue. The bug seems to be related with the "environment-setup" script in /ti-sdk-am335x-evm-07.00.00.00/linux-devkit/ in conflict with the "configure" script from the gst-plugins-bad package!

  • This is still a problem in the newest SDK, 01.00.00.03.