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 751838 - Compilation fails with ffmpeg h264_vda build
Compilation fails with ffmpeg h264_vda build
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-libav
git master
Other Mac OS
: Normal blocker
: 1.5.90
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-07-02 14:05 UTC by Heinrich Fink
Modified: 2015-08-16 13:39 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Disable ffmpeg's VDA h264 decoder (1.12 KB, patch)
2015-07-02 14:05 UTC, Heinrich Fink
committed Details | Review

Description Heinrich Fink 2015-07-02 14:05:02 UTC
After the switch to ffmpeg, building gst-libav fails on OSX with the following error: 

...
build	02-Jul-2015 13:31:39	libtool: link: clang  -o .libs/libgstlibav.so -bundle  .libs/libgstlibav_la-gstav.o .libs/libgstlibav_la-gstavprotocol.o .libs/libgstlibav_la-gstavcodecmap.o .libs/libgstlibav_la-gstavutils.o .libs/libgstlibav_la-gstavaudenc.o .libs/libgstlibav_la-gstavvidenc.o .libs/libgstlibav_la-gstavauddec.o .libs/libgstlibav_la-gstavviddec.o .libs/libgstlibav_la-gstavcfg.o .libs/libgstlibav_la-gstavdemux.o .libs/libgstlibav_la-gstavmux.o .libs/libgstlibav_la-gstavdeinterlace.o   -L/Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib ../../gst-libs/ext/libav/libavformat/libavformat.a ../../gst-libs/ext/libav/libavcodec/libavcodec.a ../../gst-libs/ext/libav/libswresample/libswresample.a ../../gst-libs/ext/libav/libavutil/libavutil.a /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgstpbutils-1.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgstvideo-1.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgstaudio-1.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgsttag-1.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/liborc-0.4.dylib -lpthread /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgstbase-1.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgstreamer-1.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgmodule-2.0.dylib -ldl /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libgobject-2.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libffi.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libglib-2.0.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libintl.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libiconv.dylib -lc /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libz.dylib /Users/Administrator/bamboo-agent-home/xml-data/build-dir/GST-GST-JOB1/cerbero-home/dist/darwin_universal/lib/libbz2.dylib  -g -Os -arch x86_64 -m64 -mmacosx-version-min=10.8 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -Wl,-read_only_relocs -Wl,suppress -Wl,-headerpad_max_install_names -arch x86_64 -m64 -Wl,-arch -Wl,x86_64 -mmacosx-version-min=10.8 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk   -Wl,-exported_symbols_list,.libs/libgstlibav-symbols.expsym
build	02-Jul-2015 13:31:39	ld: warning: -read_only_relocs cannot be used with x86_64
build	02-Jul-2015 13:31:39	Undefined symbols for architecture x86_64:
build	02-Jul-2015 13:31:39	  "_CVPixelBufferGetBaseAddress", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferGetBaseAddressOfPlane", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferGetBytesPerRow", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferGetBytesPerRowOfPlane", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferGetPlaneCount", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferIsPlanar", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferLockBaseAddress", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferRelease", referenced from:
build	02-Jul-2015 13:31:39	      _release_buffer in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferRetain", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_decode in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_CVPixelBufferUnlockBaseAddress", referenced from:
build	02-Jul-2015 13:31:39	      _release_buffer in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_ff_vda_create_decoder", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_init in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_ff_vda_destroy_decoder", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_init in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	      _vdadec_close in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	  "_kCFCoreFoundationVersionNumber", referenced from:
build	02-Jul-2015 13:31:39	      _vdadec_init in libavcodec.a(vda_h264_dec.o)
build	02-Jul-2015 13:31:39	ld: symbol(s) not found for architecture x86_64

... 

This comes from compiling (and then failing to link) ffmpeg's h264_vda which should have been disabled by passing --disable-hwaccels to ffmpeg in the first place. 

Simple solution is to explicitly disable using VDA (VideoDecoderAcceleration) in the ffmpeg config stage. Note that VDA is going to be deprecated in 10.11 anyway. See attached patch.
Comment 1 Heinrich Fink 2015-07-02 14:05:38 UTC
Created attachment 306619 [details] [review]
Disable ffmpeg's VDA h264 decoder
Comment 2 Sebastian Dröge (slomo) 2015-07-03 08:12:15 UTC
commit 0166671181fed8c984efd38a797ee8c36501a228
Author: Heinrich Fink <hfink@toolsonair.com>
Date:   Thu Jul 2 15:44:45 2015 +0200

    Fix OSX build: Explicitly disable VDA h264 decoder
    
    VideoDecodeAcceleration framework is deprecated in 10.11, and currently
    cuases linker errors when compiling on OSX. Oddly, --disable-hwaccels
    did not also disable h264_vda already.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=751838