Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-103772

Linking qtbase/plugins/multimedia/libffmegmediaplugin.so fails due to libraries not being found

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Not Evaluated
    • Resolution: Duplicate
    • Affects Version/s: 6.4
    • Fix Version/s: None
    • Component/s: Build System, Multimedia
    • Labels:
      None
    • Environment:
      Archlinux, gcc (GCC) 12.1.0, GNU ld (GNU Binutils) 2.38, cmake version 3.23.1

      Description

      Trying to build the current dev branch from git (qt5.git 178334bd29a8b8167040bc3d6f2b5f6b1c954db2, qtbase 5d8f815e101da3ae9cd6a666cc097853f52b21da), configured via ../qt5/configure -confirm-license -opensource -icu -ssl -verbose -ccache -webengine-proprietary-codecs -developer-build -debug, I get:

      [30/12331] Linking CXX shared module qtbase/plugins/multimedia/libffmegmediaplugin.so
      FAILED: qtbase/plugins/multimedia/libffmegmediaplugin.so qtmultimedia/src/plugins/multimedia/ffmpeg/QFFmpegMediaPlugin.version /home/florian/proj/qt/dev6/build/qtmultimedia/src/plugins/multimedia/ffmpeg/QFFmpegMediaPlugin.version 
      cd /home/florian/proj/qt/dev6/qt5/qtmultimedia/src/plugins/multimedia/ffmpeg && /usr/bin/perl /home/florian/proj/qt/dev6/qt5/qtbase/mkspecs/features/data/unix/findclasslist.pl < /home/florian/proj/qt/dev6/build/qtmultimedia/src/plugins/multimedia/ffmpeg/QFFmpegMediaPlugin.version.in > /home/florian/proj/qt/dev6/build/qtmultimedia/src/plugins/multimedia/ffmpeg/QFFmpegMediaPlugin.version && cd /home/florian/proj/qt/dev6/build && /usr/lib/ccache/bin/c++ -fPIC -g  -Wl,--no-undefined -Wl,--version-script,/home/florian/proj/qt/dev6/build/qtmultimedia/src/plugins/multimedia/ffmpeg/QFFmpegMediaPlugin.version -Wl,--exclude-libs=libavformat -Wl,--exclude-libs=libavcodec -Wl,--exclude-libs=libswresample -Wl,--exclude-libs=libswscale -Wl,--exclude-libs=libavutil -Wl,--enable-new-dtags -shared  -o qtbase/plugins/multimedia/libffmegmediaplugin.so qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/QFFmpegMediaPlugin_autogen/mocs_compilation.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegaudiodecoder.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegaudioinput.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegclock.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegdecoder.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpeghwaccel.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegencoderoptions.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegmediametadata.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegmediaplayer.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegvideosink.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegmediaformatinfo.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegmediaintegration.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegvideobuffer.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegimagecapture.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegmediacapturesession.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegmediarecorder.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegencoder.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegthread.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegresampler.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpegvideoframeencoder.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qffmpeghwaccel_vaapi.cpp.o qtmultimedia/src/plugins/multimedia/ffmpeg/CMakeFiles/QFFmpegMediaPlugin.dir/qv4l2camera.cpp.o  -Wl,-rpath,"\$ORIGIN/../../lib:/home/florian/proj/qt/dev6/build/qtbase/lib:"  /usr/lib/libEGL.so  /usr/lib/libxkbcommon.so  qtbase/lib/libQt6Multimedia.so.6.4.0  qtbase/lib/libQt6Gui.so.6.4.0  /usr/lib/libGLX.so  /usr/lib/libOpenGL.so  qtbase/lib/libQt6Network.so.6.4.0  qtbase/lib/libQt6Core.so.6.4.0  -lavformat  -lxml2  -lbz2  -lmodplug  -lbluray  -lgmp  -lgnutls  -lsrt  -lssh  /usr/lib/libavformat.so  -lavcodec  -lvpx  -lwebpmux  -lwebp  -llzma  -ldav1d  -lopencore-amrwb  -lrsvg-2  -lgio-2  -lgdk_pixbuf-2  -lgobject-2  -lglib-2  -lcairo  -laom  -lgsm  -lmp3lame  -lopencore-amrnb  -lopenjp2  -lopus  -lrav1e  -lspeex  -lpthread  -ltheoraenc  -ltheoradec  -logg  -lvorbis  -lvorbisenc  -lwebp  -llzma  -ldav1d  -lopencore-amrwb  -lrsvg-2  -lgio-2  -lgdk_pixbuf-2  -lgobject-2  -lglib-2  -lcairo  -laom  -lgsm  -lmp3lame  -lopencore-amrnb  -lopenjp2  -lopus  -lrav1e  -lspeex  -lpthread  -ltheoraenc  -ltheoradec  -logg  -lvorbis  -lvorbisenc  -lz  -lx264  -lx265  -lxvidcore  /usr/lib/libavcodec.so  -lswresample  -lsoxr  /usr/lib/libswresample.so  -lswscale  /usr/lib/libswscale.so  -lavutil  -lva-drm  -lva-x11  -lva  -lvdpau  -lm  -ldrm  -lmfx  -lstdc  /usr/lib/libavutil.so  /usr/lib/libva-drm.so  /usr/lib/libva.so  -Wl,-rpath-link,/home/florian/proj/qt/dev6/build/qtbase/lib && :
      /usr/bin/ld: cannot find -lgio-2: No such file or directory
      /usr/bin/ld: cannot find -lgdk_pixbuf-2: No such file or directory
      /usr/bin/ld: cannot find -lgobject-2: No such file or directory
      /usr/bin/ld: cannot find -lglib-2: No such file or directory
      /usr/bin/ld: cannot find -lgio-2: No such file or directory
      /usr/bin/ld: cannot find -lgdk_pixbuf-2: No such file or directory
      /usr/bin/ld: cannot find -lgobject-2: No such file or directory
      /usr/bin/ld: cannot find -lglib-2: No such file or directory
      /usr/bin/ld: cannot find -lstdc: No such file or directory
      collect2: error: ld returned 1 exit status
      

      However, those libraries are present on my system:

      $ pacman -Ql glib2 | grep '\.so$'  
      glib2 /usr/lib/libgio-2.0.so
      glib2 /usr/lib/libglib-2.0.so
      glib2 /usr/lib/libgmodule-2.0.so
      glib2 /usr/lib/libgobject-2.0.so
      glib2 /usr/lib/libgthread-2.0.so
      
      $ pacman -Ql gdk-pixbuf2 | grep '\.so$'
      gdk-pixbuf2 /usr/lib/libgdk_pixbuf-2.0.so
      

      Not sure what the issue with -lstdc is, but for the GTK ones, it looks like the correct invocation would be e.g. -lglib-2.0 rather than just -lglib-2?

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            qtbuildsystem Qt Build System Team
            Reporter:
            the compiler Florian Bruhin
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes