[FFmpeg-devel] Slight x265 encoder build bug in OSX + workaround

David Favor david at davidfavor.com
Wed Apr 2 17:04:23 CEST 2014


There's a subtle library path problem building on OSX.

The library path for x265 is empty, where all other libraries
have their full path set. This causes a runtime error.

So...

David-Favor-iMac> which ffmpeg
/david-favor-tools/osx-10.9/bin/ffmpeg

David-Favor-iMac> ffmpeg -codecs | grep 26[45]
dyld: Library not loaded: libx265.13.dylib
   Referenced from: /david-favor-tools/osx-10.9/bin/ffmpeg
   Reason: image not found

David-Favor-iMac> otool -L /david-favor-tools/osx-10.9/bin/ffmpeg | grep x26[45]
	libx265.13.dylib (compatibility version 13.0.0, current version 0.8.0)
	/david-favor-tools/osx-10.9/lib/libx264.142.dylib (compatibility version 0.0.0, current version 0.0.0)

Notice full path set for libx264 (and all other libraries),
except libx265 which is empty.

Temp workaround is to set a fallback library path to location
of the libx265 library...

David-Favor-iMac> export DYLD_FALLBACK_LIBRARY_PATH=/david-favor-tools/osx-10.9/lib
David-Favor-iMac> /david-favor-tools/osx-10.9/bin/ffmpeg -codecs | grep x26[45]
ffmpeg version 2.2-2014-04-02-62040-gcecb6d6 Copyright (c) 2000-2014 the FFmpeg developers
   built on Apr  2 2014 09:38:51 with gcc 4.8.2 (MacPots gcc48 4.8.2_0)
   configuration: --prefix=/david-favor-tools/osx-10.9 --enable-pic --enable-gpl --disable-indev=qtkit --disable-debug --extra-cflags='-I/david-favor-tools/osx-10.9/include -I/opt/local/include 
-I/usr/local/include -I/usr/include' --extra-ldflags='-Wl,-rpath,/david-favor-tools/osx-10.9/lib -Wl,-rpath,/opt/local/lib -Wl,-rpath,/usr/local/lib -Wl,-rpath,/usr/lib 
-L/david-favor-tools/osx-10.9/lib -L/opt/local/lib -L/usr/local/lib -L/usr/lib' --enable-version3 --enable-shared --disable-static --enable-ffplay --enable-ffprobe --enable-ffserver 
--enable-runtime-cpudetect --enable-nonfree --enable-zlib --enable-bzlib --enable-openssl --enable-libmp3lame --enable-libfaac --enable-libfdk_aac --enable-libvpx --enable-libtheora --enable-libvorbis 
--enable-libxvid --enable-libopus --enable-libopenjpeg --enable-libx264 --enable-libx265 --enable-postproc --enable-frei0r --enable-libopencore-amrnb --enable-libfreetype --enable-libmodplug 
--enable-libass --enable-openssl
   libavutil      52. 71.100 / 52. 71.100
   libavcodec     55. 56.107 / 55. 56.107
   libavformat    55. 36.100 / 55. 36.100
   libavdevice    55. 11.100 / 55. 11.100
   libavfilter     4.  3.100 /  4.  3.100
   libswscale      2.  5.102 /  2.  5.102
   libswresample   0. 18.100 /  0. 18.100
   libpostproc    52.  3.100 / 52.  3.100
  DEV.LS h264                 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 (decoders: h264 h264_vda ) (encoders: libx264 libx264rgb )
  DEV.L. hevc                 H.265 / HEVC (High Efficiency Video Coding) (encoders: libx265 )


More information about the ffmpeg-devel mailing list