Unable to execute the player example after a fresh install



  • Dear all,
    I've created a virtual machine with a fresh install of Ubuntu 14.04.5 LTS (Trusty Tahr), then I've installed Qt 5.8. My arch is x64.

    When I try to execute the /home/user/Qt/Examples/Qt-5.8/multimediawidgets/player example (simple audio/video player) I've got the following error:

    defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.mediaplayer"
    

    I've launched the application with the variable QT_DEBUG_PLUGINS=1 and seen that:

    Got keys from plugin meta data ("gstreamermediaplayer")
    QFactoryLoader::QFactoryLoader() checking directory path "/home/user/QtWorkspace/bin/mediaservice" ...
    Cannot load library /home/user/Qt/5.8/gcc_64/plugins/mediaservice/libgstmediaplayer.so: (/home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libqgsttools_p.so.1: undefined symbol: _gst_value_list_type)
    QLibraryPrivate::loadPlugin failed on "/home/user/Qt/5.8/gcc_64/plugins/mediaservice/libgstmediaplayer.so" : "Cannot load library /home/user/Qt/5.8/gcc_64/plugins/mediaservice/libgstmediaplayer.so: (/home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libqgsttools_p.so.1: undefined symbol: _gst_value_list_type)"
    defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.mediaplayer"
    

    What is the cause of the "libqgsttools_p.so.1: undefined symbol: _gst_value_list_type" error? Why this mismatch?

    Is it possible that am I missing some GStreamer libraries?

    Ubuntu 14.04.5 LTS (Trusty Tahr) comes with GStreamer 1.0 installed (1.2.4). Is it possible that QtMultimedia does not support it?

    Do I need to install GStreamer 0.1?

    How can I fix this problem and run the player example?

    Thanks in advance for your time

    Best regards,
    Fabio


  • Moderators

    @Grynium Yes, you're most probably missing GStreamer libraries.
    You can execute

    ldd libgstmediaplayer.so
    

    to find out what is missing.



  • It seems that all dependencies are satisfied:

    user@user-VirtualBox:~/Qt/5.8/gcc_64/lib$ ldd /home/user/Qt/5.8/gcc_64/plugins/mediaservice/libgstmediaplayer.so
    	linux-vdso.so.1 =>  (0x00007fffe09d1000)
    	libqgsttools_p.so.1 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libqgsttools_p.so.1 (0x00007f49fb0fd000)
    	libQt5MultimediaWidgets.so.5 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libQt5MultimediaWidgets.so.5 (0x00007f49faede000)
    	libQt5Multimedia.so.5 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libQt5Multimedia.so.5 (0x00007f49fabd4000)
    	libQt5Widgets.so.5 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libQt5Widgets.so.5 (0x00007f49fa3a3000)
    	libQt5Gui.so.5 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libQt5Gui.so.5 (0x00007f49f9c07000)
    	libQt5Network.so.5 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libQt5Network.so.5 (0x00007f49f9881000)
    	libQt5Core.so.5 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libQt5Core.so.5 (0x00007f49f9161000)
    	libGL.so.1 => /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1 (0x00007f49f8ee0000)
    	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f49f8cc1000)
    	libgstaudio-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstaudio-1.0.so.0 (0x00007f49f8a77000)
    	libgstvideo-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstvideo-1.0.so.0 (0x00007f49f8831000)
    	libgstpbutils-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstpbutils-1.0.so.0 (0x00007f49f860a000)
    	libgstapp-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstapp-1.0.so.0 (0x00007f49f83fd000)
    	libgstbase-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstbase-1.0.so.0 (0x00007f49f81a5000)
    	libgstreamer-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so.0 (0x00007f49f7ea0000)
    	libgobject-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007f49f7c4f000)
    	libpulse-mainloop-glib.so.0 => /usr/lib/x86_64-linux-gnu/libpulse-mainloop-glib.so.0 (0x00007f49f7a4a000)
    	libpulse.so.0 => /usr/lib/x86_64-linux-gnu/libpulse.so.0 (0x00007f49f7800000)
    	libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007f49f74f8000)
    	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f49f71f4000)
    	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f49f6eed000)
    	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f49f6cd7000)
    	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f49f6912000)
    	libasound.so.2 => /usr/lib/x86_64-linux-gnu/libasound.so.2 (0x00007f49f6621000)
    	libQt5OpenGL.so.5 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libQt5OpenGL.so.5 (0x00007f49f63ca000)
    	libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f49f61b0000)
    	libicui18n.so.56 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libicui18n.so.56 (0x00007f49f5d17000)
    	libicuuc.so.56 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libicuuc.so.56 (0x00007f49f595e000)
    	libicudata.so.56 => /home/user/Qt/5.8/gcc_64/plugins/mediaservice/../../lib/libicudata.so.56 (0x00007f49f3f7b000)
    	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f49f3d77000)
    	librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f49f3b6e000)
    	libgthread-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgthread-2.0.so.0 (0x00007f49f396c000)
    	/lib64/ld-linux-x86-64.so.2 (0x000055daf79ac000)
    	libexpat.so.1 => /lib/x86_64-linux-gnu/libexpat.so.1 (0x00007f49f3742000)
    	libxcb-dri3.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-dri3.so.0 (0x00007f49f353e000)
    	libxcb-present.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-present.so.0 (0x00007f49f333b000)
    	libxcb-sync.so.1 => /usr/lib/x86_64-linux-gnu/libxcb-sync.so.1 (0x00007f49f3135000)
    	libxshmfence.so.1 => /usr/lib/x86_64-linux-gnu/libxshmfence.so.1 (0x00007f49f2f32000)
    	libglapi.so.0 => /usr/lib/x86_64-linux-gnu/libglapi.so.0 (0x00007f49f2d04000)
    	libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007f49f2af2000)
    	libXdamage.so.1 => /usr/lib/x86_64-linux-gnu/libXdamage.so.1 (0x00007f49f28ee000)
    	libXfixes.so.3 => /usr/lib/x86_64-linux-gnu/libXfixes.so.3 (0x00007f49f26e8000)
    	libX11-xcb.so.1 => /usr/lib/x86_64-linux-gnu/libX11-xcb.so.1 (0x00007f49f24e6000)
    	libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007f49f21b0000)
    	libxcb-glx.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-glx.so.0 (0x00007f49f1f99000)
    	libxcb-dri2.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-dri2.so.0 (0x00007f49f1d94000)
    	libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f49f1b74000)
    	libXxf86vm.so.1 => /usr/lib/x86_64-linux-gnu/libXxf86vm.so.1 (0x00007f49f196e000)
    	libdrm.so.2 => /usr/lib/x86_64-linux-gnu/libdrm.so.2 (0x00007f49f1760000)
    	libgsttag-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgsttag-1.0.so.0 (0x00007f49f1527000)
    	liborc-0.4.so.0 => /usr/lib/x86_64-linux-gnu/liborc-0.4.so.0 (0x00007f49f12a5000)
    	libgmodule-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007f49f10a0000)
    	libffi.so.6 => /usr/lib/x86_64-linux-gnu/libffi.so.6 (0x00007f49f0e98000)
    	libpulsecommon-4.0.so => /usr/lib/x86_64-linux-gnu/pulseaudio/libpulsecommon-4.0.so (0x00007f49f0c30000)
    	libjson-c.so.2 => /lib/x86_64-linux-gnu/libjson-c.so.2 (0x00007f49f0a25000)
    	libdbus-1.so.3 => /lib/x86_64-linux-gnu/libdbus-1.so.3 (0x00007f49f07e0000)
    	libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007f49f05a1000)
    	libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007f49f039c000)
    	libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f49f0196000)
    	libwrap.so.0 => /lib/x86_64-linux-gnu/libwrap.so.0 (0x00007f49eff8b000)
    	libsndfile.so.1 => /usr/lib/x86_64-linux-gnu/libsndfile.so.1 (0x00007f49efd23000)
    	libasyncns.so.0 => /usr/lib/x86_64-linux-gnu/libasyncns.so.0 (0x00007f49efb1d000)
    	libnsl.so.1 => /lib/x86_64-linux-gnu/libnsl.so.1 (0x00007f49ef902000)
    	libFLAC.so.8 => /usr/lib/x86_64-linux-gnu/libFLAC.so.8 (0x00007f49ef6d1000)
    	libvorbisenc.so.2 => /usr/lib/x86_64-linux-gnu/libvorbisenc.so.2 (0x00007f49ef202000)
    	libvorbis.so.0 => /usr/lib/x86_64-linux-gnu/libvorbis.so.0 (0x00007f49eefd4000)
    	libogg.so.0 => /usr/lib/x86_64-linux-gnu/libogg.so.0 (0x00007f49eedcb000)
    	libresolv.so.2 => /lib/x86_64-linux-gnu/libresolv.so.2 (0x00007f49eebb0000)
    

  • Lifetime Qt Champion

    Hi,

    I wonder if you are hitting that bug.



  • Exactly the same problem!
    same os, same qt version, and the same error !



  • @Grynium did u solve the problem?



  • @rickywong2017 the same to me ,did u solve this problem?



  • @ed_u the sad thing is not, i've changed the qt version to Qt5.6.2 and this error simply just dont happen.



  • Solution for Qt 5.8.0 on Ubuntu 14.04

    This is basically the error:

    Cannot load library /home/massimo/projects/Qt5.8.0/5.8/gcc_64/plugins/mediaservice/libgstmediaplayer.so: (/home/massimo/projects/Qt5.8.0/5.8/gcc_64/plugins/mediaservice/../../lib/libqgsttools_p.so.1: undefined symbol: _gst_value_list_type)
    

    Which means the Qt Multimedia team didn't consider the gstreamer version shipping on Ubuntu 14.04 which is 1.2.3.
    To solve you need to update GST with a PPA. Seems 1.6.x is enough to make Qt happy.

    sudo add-apt-repository ppa:dan-witt/gstreamer
    sudo apt-get update
    sudo apt-get upgrade
    

    Footnote: 14.04 is a LTS version and Qt didn't care. This is horrible and bad decision making IMHO.


  • Lifetime Qt Champion

    @mcallegari79 If you want LTS everywhere then Qt 5.6 is the current LTS not 5.8.



  • @rickywong2017 Why i still got that error when running the example on 5.6.2 :((
    I am newbie. Sorry if my question is noob.
    Can anyone tell me how to launched the application with the variable QT_DEBUG_PLUGINS=1


  • Moderators

    @tamolo In the command line:

    $ QT_DEBUG_PLUGINS=1
    $ ./my_app
    

    Or in QtCreator set this variable in "Projects/Run/Run Environment/Add".



  • thank you so much



  • @Grynium @rickywong2017
    This is the way i fixed it.
    Step 1: use 'apt-cache search -n gstreamer' to get the list all of the gstreamer and libgstream lib
    Step 2: for each of lib in the list. Use 'apt-get install name-of-the-gstreamer-lib' to install it. After install almost the lib in the list my example run. ( i don't know which is the exactly lib i need to install. I just install all of them until my example run)
    Step 3: rebuild your example and run.

    I hope this help.


Log in to reply