After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 584399 - FFmpeg libraries are included in incorrect order when external FFmpeg is used
FFmpeg libraries are included in incorrect order when external FFmpeg is used
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-libav
git master
Other Windows
: Normal trivial
: 0.10.8
Assigned To: Wim Taymans
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-05-31 21:45 UTC by LRN
Modified: 2009-06-01 15:25 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Changes the library inclusion order (750 bytes, patch)
2009-05-31 21:46 UTC, LRN
committed Details | Review

Description LRN 2009-05-31 21:45:07 UTC
When external FFmpeg is used, configure.ac does:

  PKG_CHECK_MODULES(FFMPEG, libavutil libavcodec libavformat)
  PKG_CHECK_MODULES(POSTPROC, libavutil libavcodec libpostproc)
  PKG_CHECK_MODULES(SWSCALE, libavutil libswscale)

which implicitly adds proper libraries to the list of linker's arguments.
But when internal FFmpeg is used, all library dependences are specified explicitly:

  FFMPEG_LIBS="\$(top_builddir)/gst-libs/ext/ffmpeg/libavformat/libavformat.a \
               \$(top_builddir)/gst-libs/ext/ffmpeg/libavcodec/libavcodec.a \
               \$(top_builddir)/gst-libs/ext/ffmpeg/libavutil/libavutil.a"

  POSTPROC_LIBS="\$(top_builddir)/gst-libs/ext/ffmpeg/libpostproc/libpostproc.a \
  		 \$(top_builddir)/gst-libs/ext/ffmpeg/libavutil/libavutil.a"

  SWSCALE_LIBS="\$(top_builddir)/gst-libs/ext/ffmpeg/libswscale/libswscale.a \
                \$(top_builddir)/gst-libs/ext/ffmpeg/libavutil/libavutil.a"

The order (format->codec->util in the latter and util->codec->format in the former) is different and the difference causes gst-ffmpeg to spew link-time errors ("undefined reference to ...") when linking against external FFmpeg.
Comment 1 LRN 2009-05-31 21:46:01 UTC
Created attachment 135691 [details] [review]
Changes the library inclusion order
Comment 2 Wim Taymans 2009-06-01 15:25:58 UTC
commit 5917098edf51956ceefc65772be59e9e7c1e0fc5
Author: LRN <lrn1986 at gmail.com>
Date:   Mon Jun 1 17:24:53 2009 +0200

    ffmpeg: change library inclusion order
    
    Fixes #584399