Giter VIP home page Giter VIP logo

rust-ffmpeg-sys's Introduction

Rust FFI bindings for ffmpeg

Low-level bindings for ffmpeg autogenerated with bindgen. This crate supports cross-compilation automatically.

For higher-level library, see ffmpeg crate.

Building

By default, the crate will search for ffmpeg v4 installed on the system.

This crate can also download, build and statically link its own copy of ffmpeg if you enable build feature:

[dependencies]
ffmpeg-sys = { version = "4", features = ["build"] }

See Cargo features to control which codecs are included.

rust-ffmpeg-sys's People

Contributors

0xd34d10cc avatar ajsyp avatar andidog avatar attackgoat avatar bacek avatar ccbrown avatar chrox avatar ebarnard avatar ereichert avatar fengalin avatar geovex avatar hatzel avatar inrustwetrust avatar kornelski avatar kryptan avatar ldm0 avatar lummax avatar marcantoine-arnaud avatar meh avatar nutigoodpipes avatar panicbit avatar pkubaj avatar retrry avatar semicoleon avatar sethdusek avatar stephaneyfx avatar thedataking avatar tilpner avatar wictory avatar zmwangx avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rust-ffmpeg-sys's Issues

Cannot perform bitwise operations on bitflag-like enums

av_buffersrc_add_frame_flags takes a bitflag as the final argument, but the enum which is generated that represents those flags does not have bitwise operations implemented for it.

I've played with bindgen options for the enum, but haven't been able to get a result better than mapping them as constants.

Incorrect struct fields in AVFormatContext

In the update from ffmpeg 2.8 to 3.0, the AVFormatContext has changed very slightly. This change is subtle enough to allow for the FFI version of this struct to not fail completely, but enough to screw up the alignment of about half of the fields and invalidate them(I found this out trying to use the rust-ffmpeg examples and having them segfault).

In order to update to 3.0 properly, the open_cb field should be removed and replaced with io_open, and io_close, the bit_rate field should be changed to an in64_t, and a protocol_whitelist field should be added in. To update to 3.1 in addition to the previous changes, a protocol_blacklist field should be added. For reference, here is the ffmpeg documentation.

Can not build rust-ffmpeg-sys both on Fedora and Ubuntu 16.04

Hi

I've came here originally because of rust-ffmpeg build failure, but it seems that there is an issue related to how bindgen tries to compile sys bindings. Problem persists both with native ffmpeg and when "build" feature is enabled (i.e. downloaded lib).

In a nutshell, here is an output:```
OPT_LEVEL = Some("0")
TARGET = Some("x86_64-unknown-linux-gnu")
HOST = Some("x86_64-unknown-linux-gnu")
TARGET = Some("x86_64-unknown-linux-gnu")
TARGET = Some("x86_64-unknown-linux-gnu")
HOST = Some("x86_64-unknown-linux-gnu")
CC_x86_64-unknown-linux-gnu = None
CC_x86_64_unknown_linux_gnu = None
HOST_CC = None
CC = None
HOST = Some("x86_64-unknown-linux-gnu")
TARGET = Some("x86_64-unknown-linux-gnu")
HOST = Some("x86_64-unknown-linux-gnu")
CFLAGS_x86_64-unknown-linux-gnu = None
CFLAGS_x86_64_unknown_linux_gnu = None
HOST_CFLAGS = None
CFLAGS = None
DEBUG = Some("true")

/usr/include/limits.h:124:16: fatal error: 'limits.h' file not found
/usr/include/limits.h:124:16: fatal error: 'limits.h' file not found, err: true
thread 'main' panicked at 'Unable to generate bindings: ()', libcore/result.rs:945:5
note: Run with RUST_BACKTRACE=1 for a backtrace.


I use pretty much default linux installations with ffmpeg devel packages installed as well as other devel stuff from libc, libstdc++ and so on. I'm pretty sure this is somehow related to one or another missing header and/or compiler options, but error output is pretty cryptic.

Attached full outputs for cloned and native ffmpeg builds.

Any advice on how to debug this?

[build_cloned_ffmpeg.txt](https://github.com/meh/rust-ffmpeg-sys/files/2000880/build_cloned_ffmpeg.txt)
[build_native_ffmpeg.txt](https://github.com/meh/rust-ffmpeg-sys/files/2000881/build_native_ffmpeg.txt)

AVRounding can't be a rustified enum

The crate builds all enums as Rust enums (.rustified_enum("*")), but AVRounding is expected to be OR-ed together like AV_ROUND_NEAR_INF|AV_ROUND_PASS_MINMAX, which is not allowed (and UB if you tried anyway).

It could use the bitflags crate instead.

Build fails: thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: MSVC', src\libcore\result.rs:906:4

I just added ffmpeg-sys = "3.4.0" to my Cargo.toml and rebuilt.

I'm new to Rust, so I might be missing something obvious.

   Compiling ffmpeg-sys v3.4.0
error: failed to run custom build command for `ffmpeg-sys v3.4.0`
process didn't exit successfully: `C:\dev-projects\rust-test\ffmpegtest\target\debug\build\ffmpeg-sys-9ea514c47ef9da6b\build-script-build` (exit code: 101)
--- stderr
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: MSVC', src\libcore\result.rs:906:4
stack backtrace:
   0:        0x1405bb681 - std::sys_common::backtrace::_print
                               at C:\projects\rust\src\libstd\sys_common\backtrace.rs:92
   1:        0x1405c692c - std::panicking::default_hook::{{closure}}
                               at C:\projects\rust\src\libstd\panicking.rs:380
   2:        0x1405c6615 - std::panicking::default_hook
                               at C:\projects\rust\src\libstd\panicking.rs:397
   3:        0x1405c6f05 - std::panicking::rust_panic_with_hook
                               at C:\projects\rust\src\libstd\panicking.rs:577
   4:        0x1405c6d98 - std::panicking::begin_panic<alloc::string::String>
                               at C:\projects\rust\src\libstd\panicking.rs:538
   5:        0x1405c6c71 - std::panicking::begin_panic_fmt
                               at C:\projects\rust\src\libstd\panicking.rs:522
   6:        0x1405c6bdf - std::panicking::rust_begin_panic
                               at C:\projects\rust\src\libstd\panicking.rs:498
   7:        0x1405d056e - core::panicking::panic_fmt
                               at C:\projects\rust\src\libcore\panicking.rs:71
   8:        0x13fc78ea4 - core::result::unwrap_failed<pkg_config::Error>
                               at C:\projects\rust\src\libcore\macros.rs:23
   9:        0x13fc77842 - core::result::Result<pkg_config::Library, pkg_config::Error>::unwrap<pkg_config::Library,pkg_config::Error>
                               at C:\projects\rust\src\libcore\result.rs:772
  10:        0x13fc514b5 - build_script_build::main
                               at c:\dev\rust\cargo\registry\src\github.com-1ecc6299db9ec823\ffmpeg-sys-3.4.0\build.rs:517
  11:        0x1405c8281 - panic_unwind::__rust_maybe_catch_panic
                               at C:\projects\rust\src\libpanic_unwind\lib.rs:99
  12:        0x1405c7721 - std::rt::lang_start
                               at C:\projects\rust\src\libstd\rt.rs:52
  13:        0x13fc58866 - main
  14:        0x1405d7d28 - __scrt_common_main_seh
                               at f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:253
  15:         0x775b59cc - BaseThreadInitThunk

I just want to communicate with @Meh

Hey there,

I recently had to deal with one of the idiots that you'd dealt with before (here: http://archive.is/5Xwzl ) who claimed that "master/slave" terminology for software was "actively discouraging" people from contributing.

Coincidentally, all 4 of them, white guys.

But anyway, I just want to say "nice job" and well handled and glad I'm not alone. The vocal-ness of the "special" community can make it a scary thing to risk tripping up.

I'll delete this issue, just drop me a comment saying to do so. Sorry for the odd way of communicating, I like SVN and monotonic revision numbers, never used github.

Bye

Build fails on Linux with ffmpeg compiled from source

I'm trying to build this crate on Ubuntu (running via Linux Subsystem for Windows). Steps:

  1. I have compiled ffmpeg from source as by these instructions.
  2. I have setup the PKG_CONFIG_PATH-env variable to pickug the compiled ffmpeg libraries from my home-directory.
  3. I have installed both linux-libc-dev and linux-headers-generic to get limits.h

Below is the output of cargo build with backtrace:

lukas@LAPTOP-Lukas:/mnt/c/Users/Lukas/dev/project$ RUST_BACKTRACE=1 cargo build
   Compiling ffmpeg-sys v3.4.1
error: failed to run custom build command for `ffmpeg-sys v3.4.1`

Caused by:
  process didn't exit successfully: `/mnt/c/Users/Lukas/dev/project/target/debug/build/ffmpeg-sys-e8b70330e8b9319e/build-script-build` (exit code: 101)
--- stdout
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=avformat
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=avcodec
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=fdk-aac
cargo:rustc-link-lib=m
cargo:rustc-link-lib=mp3lame
cargo:rustc-link-lib=m
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=vorbisenc
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=va
cargo:rustc-link-lib=swresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=avfilter
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ass
cargo:rustc-link-lib=m
cargo:rustc-link-lib=harfbuzz
cargo:rustc-link-lib=m
cargo:rustc-link-lib=glib-2.0
cargo:rustc-link-lib=pcre
cargo:rustc-link-lib=graphite2
cargo:rustc-link-lib=fontconfig
cargo:rustc-link-lib=expat
cargo:rustc-link-lib=freetype
cargo:rustc-link-lib=expat
cargo:rustc-link-lib=fribidi
cargo:rustc-link-lib=freetype
cargo:rustc-link-lib=png16
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=va
cargo:rustc-link-lib=freetype
cargo:rustc-link-lib=png16
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=swscale
cargo:rustc-link-lib=m
cargo:rustc-link-lib=postproc
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avformat
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=avcodec
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=fdk-aac
cargo:rustc-link-lib=m
cargo:rustc-link-lib=mp3lame
cargo:rustc-link-lib=m
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=vorbisenc
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=va
cargo:rustc-link-lib=swresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=avdevice
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avfilter
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ass
cargo:rustc-link-lib=m
cargo:rustc-link-lib=harfbuzz
cargo:rustc-link-lib=m
cargo:rustc-link-lib=glib-2.0
cargo:rustc-link-lib=pcre
cargo:rustc-link-lib=graphite2
cargo:rustc-link-lib=fontconfig
cargo:rustc-link-lib=expat
cargo:rustc-link-lib=freetype
cargo:rustc-link-lib=expat
cargo:rustc-link-lib=fribidi
cargo:rustc-link-lib=freetype
cargo:rustc-link-lib=png16
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=va
cargo:rustc-link-lib=freetype
cargo:rustc-link-lib=png16
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=swscale
cargo:rustc-link-lib=m
cargo:rustc-link-lib=postproc
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avformat
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=avcodec
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=fdk-aac
cargo:rustc-link-lib=m
cargo:rustc-link-lib=mp3lame
cargo:rustc-link-lib=m
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=vorbisenc
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=va
cargo:rustc-link-lib=swresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=avresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=swscale
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=swresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
cargo:rustc-link-search=native=/home/lukas/ffmpeg_build/lib
cargo:rustc-link-lib=avcodec
cargo:rustc-link-lib=m
cargo:rustc-link-lib=z
cargo:rustc-link-lib=fdk-aac
cargo:rustc-link-lib=m
cargo:rustc-link-lib=mp3lame
cargo:rustc-link-lib=m
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=vorbisenc
cargo:rustc-link-lib=vorbis
cargo:rustc-link-lib=m
cargo:rustc-link-lib=ogg
cargo:rustc-link-lib=va
cargo:rustc-link-lib=swresample
cargo:rustc-link-lib=m
cargo:rustc-link-lib=avutil
cargo:rustc-link-lib=va-drm
cargo:rustc-link-lib=va
cargo:rustc-link-lib=m
cargo:rustc-link-lib=va
OPT_LEVEL = Some("0")
TARGET = Some("x86_64-unknown-linux-gnu")
HOST = Some("x86_64-unknown-linux-gnu")
CC_x86_64-unknown-linux-gnu = None
CC_x86_64_unknown_linux_gnu = None
HOST_CC = None
CC = None
CFLAGS_x86_64-unknown-linux-gnu = None
CFLAGS_x86_64_unknown_linux_gnu = None
HOST_CFLAGS = None
CFLAGS = None
CRATE_CC_NO_DEFAULTS = None
DEBUG = Some("true")
CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2")
stdout=[FF_API_OLD_AVOPTIONS]00
[FF_API_PIX_FMT]00
[FF_API_CONTEXT_SIZE]00
[FF_API_PIX_FMT_DESC]00
[FF_API_AV_REVERSE]00
[FF_API_AUDIOCONVERT]00
[FF_API_CPU_FLAG_MMX2]00
[FF_API_LLS_PRIVATE]00
[FF_API_AVFRAME_LAVC]00
[FF_API_VDPAU]00
[FF_API_GET_CHANNEL_LAYOUT_COMPAT]00
[FF_API_XVMC]01
[FF_API_OPT_TYPE_METADATA]00
[FF_API_DLOG]00
[FF_API_HMAC]00
[FF_API_VAAPI]11
[FF_API_PKT_PTS]11
[FF_API_ERROR_FRAME]11
[FF_API_FRAME_QP]11
[FF_API_VIMA_DECODER]00
[FF_API_REQUEST_CHANNELS]00
[FF_API_OLD_DECODE_AUDIO]00
[FF_API_OLD_ENCODE_AUDIO]00
[FF_API_OLD_ENCODE_VIDEO]00
[FF_API_CODEC_ID]00
[FF_API_AUDIO_CONVERT]00
[FF_API_AVCODEC_RESAMPLE]00
[FF_API_DEINTERLACE]00
[FF_API_DESTRUCT_PACKET]00
[FF_API_GET_BUFFER]00
[FF_API_MISSING_SAMPLE]00
[FF_API_LOWRES]11
[FF_API_CAP_VDPAU]00
[FF_API_BUFS_VDPAU]00
[FF_API_VOXWARE]00
[FF_API_SET_DIMENSIONS]00
[FF_API_DEBUG_MV]01
[FF_API_AC_VLC]00
[FF_API_OLD_MSMPEG4]00
[FF_API_ASPECT_EXTENDED]00
[FF_API_THREAD_OPAQUE]00
[FF_API_CODEC_PKT]00
[FF_API_ARCH_ALPHA]00
[FF_API_XVMC]01
[FF_API_ERROR_RATE]00
[FF_API_QSCALE_TYPE]00
[FF_API_MB_TYPE]00
[FF_API_MAX_BFRAMES]00
[FF_API_NEG_LINESIZES]00
[FF_API_EMU_EDGE]00
[FF_API_ARCH_SH4]00
[FF_API_ARCH_SPARC]00
[FF_API_UNUSED_MEMBERS]00
[FF_API_IDCT_XVIDMMX]00
[FF_API_INPUT_PRESERVED]00
[FF_API_NORMALIZE_AQP]00
[FF_API_GMC]00
[FF_API_MV0]00
[FF_API_CODEC_NAME]00
[FF_API_AFD]00
[FF_API_VISMV]00
[FF_API_DV_FRAME_PROFILE]00
[FF_API_AUDIOENC_DELAY]00
[FF_API_VAAPI_CONTEXT]00
[FF_API_AVCTX_TIMEBASE]11
[FF_API_MPV_OPT]00
[FF_API_STREAM_CODEC_TAG]00
[FF_API_QUANT_BIAS]00
[FF_API_RC_STRATEGY]00
[FF_API_CODED_FRAME]11
[FF_API_MOTION_EST]00
[FF_API_WITHOUT_PREFIX]00
[FF_API_CONVERGENCE_DURATION]11
[FF_API_PRIVATE_OPT]11
[FF_API_CODER_TYPE]11
[FF_API_RTP_CALLBACK]11
[FF_API_STAT_BITS]11
[FF_API_VBV_DELAY]11
[FF_API_SIDEDATA_ONLY_PKT]11
[FF_API_AVPICTURE]11
[FF_API_LAVF_BITEXACT]00
[FF_API_LAVF_FRAC]00
[FF_API_URL_FEOF]00
[FF_API_PROBESIZE_32]00
[FF_API_LAVF_AVCTX]11
[FF_API_OLD_OPEN_CALLBACKS]11
[avcodec_version_greater_than_56_0]1
[avcodec_version_greater_than_56_1]1
[avcodec_version_greater_than_56_2]1
[avcodec_version_greater_than_56_3]1
[avcodec_version_greater_than_56_4]1
[avcodec_version_greater_than_56_5]1
[avcodec_version_greater_than_56_6]1
[avcodec_version_greater_than_56_7]1
[avcodec_version_greater_than_56_8]1
[avcodec_version_greater_than_56_9]1
[avcodec_version_greater_than_56_10]1
[avcodec_version_greater_than_56_11]1
[avcodec_version_greater_than_56_12]1
[avcodec_version_greater_than_56_13]1
[avcodec_version_greater_than_56_14]1
[avcodec_version_greater_than_56_15]1
[avcodec_version_greater_than_56_16]1
[avcodec_version_greater_than_56_17]1
[avcodec_version_greater_than_56_18]1
[avcodec_version_greater_than_56_19]1
[avcodec_version_greater_than_56_20]1
[avcodec_version_greater_than_56_21]1
[avcodec_version_greater_than_56_22]1
[avcodec_version_greater_than_56_23]1
[avcodec_version_greater_than_56_24]1
[avcodec_version_greater_than_56_25]1
[avcodec_version_greater_than_56_26]1
[avcodec_version_greater_than_56_27]1
[avcodec_version_greater_than_56_28]1
[avcodec_version_greater_than_56_29]1
[avcodec_version_greater_than_56_30]1
[avcodec_version_greater_than_56_31]1
[avcodec_version_greater_than_56_32]1
[avcodec_version_greater_than_56_33]1
[avcodec_version_greater_than_56_34]1
[avcodec_version_greater_than_56_35]1
[avcodec_version_greater_than_56_36]1
[avcodec_version_greater_than_56_37]1
[avcodec_version_greater_than_56_38]1
[avcodec_version_greater_than_56_39]1
[avcodec_version_greater_than_56_40]1
[avcodec_version_greater_than_56_41]1
[avcodec_version_greater_than_56_42]1
[avcodec_version_greater_than_56_43]1
[avcodec_version_greater_than_56_44]1
[avcodec_version_greater_than_56_45]1
[avcodec_version_greater_than_56_46]1
[avcodec_version_greater_than_56_47]1
[avcodec_version_greater_than_56_48]1
[avcodec_version_greater_than_56_49]1
[avcodec_version_greater_than_56_50]1
[avcodec_version_greater_than_56_51]1
[avcodec_version_greater_than_56_52]1
[avcodec_version_greater_than_56_53]1
[avcodec_version_greater_than_56_54]1
[avcodec_version_greater_than_56_55]1
[avcodec_version_greater_than_56_56]1
[avcodec_version_greater_than_56_57]1
[avcodec_version_greater_than_56_58]1
[avcodec_version_greater_than_56_59]1
[avcodec_version_greater_than_56_60]1
[avcodec_version_greater_than_56_61]1
[avcodec_version_greater_than_56_62]1
[avcodec_version_greater_than_56_63]1
[avcodec_version_greater_than_56_64]1
[avcodec_version_greater_than_56_65]1
[avcodec_version_greater_than_56_66]1
[avcodec_version_greater_than_56_67]1
[avcodec_version_greater_than_56_68]1
[avcodec_version_greater_than_56_69]1
[avcodec_version_greater_than_56_70]1
[avcodec_version_greater_than_56_71]1
[avcodec_version_greater_than_56_72]1
[avcodec_version_greater_than_56_73]1
[avcodec_version_greater_than_56_74]1
[avcodec_version_greater_than_56_75]1
[avcodec_version_greater_than_56_76]1
[avcodec_version_greater_than_56_77]1
[avcodec_version_greater_than_56_78]1
[avcodec_version_greater_than_56_79]1
[avcodec_version_greater_than_57_0]1
[avcodec_version_greater_than_57_1]1
[avcodec_version_greater_than_57_2]1
[avcodec_version_greater_than_57_3]1
[avcodec_version_greater_than_57_4]1
[avcodec_version_greater_than_57_5]1
[avcodec_version_greater_than_57_6]1
[avcodec_version_greater_than_57_7]1
[avcodec_version_greater_than_57_8]1
[avcodec_version_greater_than_57_9]1
[avcodec_version_greater_than_57_10]1
[avcodec_version_greater_than_57_11]1
[avcodec_version_greater_than_57_12]1
[avcodec_version_greater_than_57_13]1
[avcodec_version_greater_than_57_14]1
[avcodec_version_greater_than_57_15]1
[avcodec_version_greater_than_57_16]1
[avcodec_version_greater_than_57_17]1
[avcodec_version_greater_than_57_18]1
[avcodec_version_greater_than_57_19]1
[avcodec_version_greater_than_57_20]1
[avcodec_version_greater_than_57_21]1
[avcodec_version_greater_than_57_22]1
[avcodec_version_greater_than_57_23]1
[avcodec_version_greater_than_57_24]1
[avcodec_version_greater_than_57_25]1
[avcodec_version_greater_than_57_26]1
[avcodec_version_greater_than_57_27]1
[avcodec_version_greater_than_57_28]1
[avcodec_version_greater_than_57_29]1
[avcodec_version_greater_than_57_30]1
[avcodec_version_greater_than_57_31]1
[avcodec_version_greater_than_57_32]1
[avcodec_version_greater_than_57_33]1
[avcodec_version_greater_than_57_34]1
[avcodec_version_greater_than_57_35]1
[avcodec_version_greater_than_57_36]1
[avcodec_version_greater_than_57_37]1
[avcodec_version_greater_than_57_38]1
[avcodec_version_greater_than_57_39]1
[avcodec_version_greater_than_57_40]1
[avcodec_version_greater_than_57_41]1
[avcodec_version_greater_than_57_42]1
[avcodec_version_greater_than_57_43]1
[avcodec_version_greater_than_57_44]1
[avcodec_version_greater_than_57_45]1
[avcodec_version_greater_than_57_46]1
[avcodec_version_greater_than_57_47]1
[avcodec_version_greater_than_57_48]1
[avcodec_version_greater_than_57_49]1
[avcodec_version_greater_than_57_50]1
[avcodec_version_greater_than_57_51]1
[avcodec_version_greater_than_57_52]1
[avcodec_version_greater_than_57_53]1
[avcodec_version_greater_than_57_54]1
[avcodec_version_greater_than_57_55]1
[avcodec_version_greater_than_57_56]1
[avcodec_version_greater_than_57_57]1
[avcodec_version_greater_than_57_58]1
[avcodec_version_greater_than_57_59]1
[avcodec_version_greater_than_57_60]1
[avcodec_version_greater_than_57_61]1
[avcodec_version_greater_than_57_62]1
[avcodec_version_greater_than_57_63]1
[avcodec_version_greater_than_57_64]1
[avcodec_version_greater_than_57_65]1
[avcodec_version_greater_than_57_66]1
[avcodec_version_greater_than_57_67]1
[avcodec_version_greater_than_57_68]1
[avcodec_version_greater_than_57_69]1
[avcodec_version_greater_than_57_70]1
[avcodec_version_greater_than_57_71]1
[avcodec_version_greater_than_57_72]1
[avcodec_version_greater_than_57_73]1
[avcodec_version_greater_than_57_74]1
[avcodec_version_greater_than_57_75]1
[avcodec_version_greater_than_57_76]1
[avcodec_version_greater_than_57_77]1
[avcodec_version_greater_than_57_78]1
[avcodec_version_greater_than_57_79]1
[avcodec_version_greater_than_58_0]1
[avcodec_version_greater_than_58_1]1
[avcodec_version_greater_than_58_2]1
[avcodec_version_greater_than_58_3]1
[avcodec_version_greater_than_58_4]1
[avcodec_version_greater_than_58_5]1
[avcodec_version_greater_than_58_6]1
[avcodec_version_greater_than_58_7]1
[avcodec_version_greater_than_58_8]1
[avcodec_version_greater_than_58_9]1
[avcodec_version_greater_than_58_10]1
[avcodec_version_greater_than_58_11]1
[avcodec_version_greater_than_58_12]1
[avcodec_version_greater_than_58_13]1
[avcodec_version_greater_than_58_14]1
[avcodec_version_greater_than_58_15]1
[avcodec_version_greater_than_58_16]1
[avcodec_version_greater_than_58_17]1
[avcodec_version_greater_than_58_18]1
[avcodec_version_greater_than_58_19]1
[avcodec_version_greater_than_58_20]1
[avcodec_version_greater_than_58_21]1
[avcodec_version_greater_than_58_22]1
[avcodec_version_greater_than_58_23]1
[avcodec_version_greater_than_58_24]1
[avcodec_version_greater_than_58_25]1
[avcodec_version_greater_than_58_26]1
[avcodec_version_greater_than_58_27]1
[avcodec_version_greater_than_58_28]1
[avcodec_version_greater_than_58_29]1
[avcodec_version_greater_than_58_30]1
[avcodec_version_greater_than_58_31]1
[avcodec_version_greater_than_58_32]1
[avcodec_version_greater_than_58_33]1
[avcodec_version_greater_than_58_34]1
[avcodec_version_greater_than_58_35]1
[avcodec_version_greater_than_58_36]1
[avcodec_version_greater_than_58_37]1
[avcodec_version_greater_than_58_38]1
[avcodec_version_greater_than_58_39]1
[avcodec_version_greater_than_58_40]1
[avcodec_version_greater_than_58_41]1
[avcodec_version_greater_than_58_42]1
[avcodec_version_greater_than_58_43]1
[avcodec_version_greater_than_58_44]1
[avcodec_version_greater_than_58_45]1
[avcodec_version_greater_than_58_46]1
[avcodec_version_greater_than_58_47]1
[avcodec_version_greater_than_58_48]1
[avcodec_version_greater_than_58_49]1
[avcodec_version_greater_than_58_50]1
[avcodec_version_greater_than_58_51]1
[avcodec_version_greater_than_58_52]1
[avcodec_version_greater_than_58_53]1
[avcodec_version_greater_than_58_54]1
[avcodec_version_greater_than_58_55]0
[avcodec_version_greater_than_58_56]0
[avcodec_version_greater_than_58_57]0
[avcodec_version_greater_than_58_58]0
[avcodec_version_greater_than_58_59]0
[avcodec_version_greater_than_58_60]0
[avcodec_version_greater_than_58_61]0
[avcodec_version_greater_than_58_62]0
[avcodec_version_greater_than_58_63]0
[avcodec_version_greater_than_58_64]0
[avcodec_version_greater_than_58_65]0
[avcodec_version_greater_than_58_66]0
[avcodec_version_greater_than_58_67]0
[avcodec_version_greater_than_58_68]0
[avcodec_version_greater_than_58_69]0
[avcodec_version_greater_than_58_70]0
[avcodec_version_greater_than_58_71]0
[avcodec_version_greater_than_58_72]0
[avcodec_version_greater_than_58_73]0
[avcodec_version_greater_than_58_74]0
[avcodec_version_greater_than_58_75]0
[avcodec_version_greater_than_58_76]0
[avcodec_version_greater_than_58_77]0
[avcodec_version_greater_than_58_78]0
[avcodec_version_greater_than_58_79]0
[avcodec_version_greater_than_59_0]0
[avcodec_version_greater_than_59_1]0
[avcodec_version_greater_than_59_2]0
[avcodec_version_greater_than_59_3]0
[avcodec_version_greater_than_59_4]0
[avcodec_version_greater_than_59_5]0
[avcodec_version_greater_than_59_6]0
[avcodec_version_greater_than_59_7]0
[avcodec_version_greater_than_59_8]0
[avcodec_version_greater_than_59_9]0
[avcodec_version_greater_than_59_10]0
[avcodec_version_greater_than_59_11]0
[avcodec_version_greater_than_59_12]0
[avcodec_version_greater_than_59_13]0
[avcodec_version_greater_than_59_14]0
[avcodec_version_greater_than_59_15]0
[avcodec_version_greater_than_59_16]0
[avcodec_version_greater_than_59_17]0
[avcodec_version_greater_than_59_18]0
[avcodec_version_greater_than_59_19]0
[avcodec_version_greater_than_59_20]0
[avcodec_version_greater_than_59_21]0
[avcodec_version_greater_than_59_22]0
[avcodec_version_greater_than_59_23]0
[avcodec_version_greater_than_59_24]0
[avcodec_version_greater_than_59_25]0
[avcodec_version_greater_than_59_26]0
[avcodec_version_greater_than_59_27]0
[avcodec_version_greater_than_59_28]0
[avcodec_version_greater_than_59_29]0
[avcodec_version_greater_than_59_30]0
[avcodec_version_greater_than_59_31]0
[avcodec_version_greater_than_59_32]0
[avcodec_version_greater_than_59_33]0
[avcodec_version_greater_than_59_34]0
[avcodec_version_greater_than_59_35]0
[avcodec_version_greater_than_59_36]0
[avcodec_version_greater_than_59_37]0
[avcodec_version_greater_than_59_38]0
[avcodec_version_greater_than_59_39]0
[avcodec_version_greater_than_59_40]0
[avcodec_version_greater_than_59_41]0
[avcodec_version_greater_than_59_42]0
[avcodec_version_greater_than_59_43]0
[avcodec_version_greater_than_59_44]0
[avcodec_version_greater_than_59_45]0
[avcodec_version_greater_than_59_46]0
[avcodec_version_greater_than_59_47]0
[avcodec_version_greater_than_59_48]0
[avcodec_version_greater_than_59_49]0
[avcodec_version_greater_than_59_50]0
[avcodec_version_greater_than_59_51]0
[avcodec_version_greater_than_59_52]0
[avcodec_version_greater_than_59_53]0
[avcodec_version_greater_than_59_54]0
[avcodec_version_greater_than_59_55]0
[avcodec_version_greater_than_59_56]0
[avcodec_version_greater_than_59_57]0
[avcodec_version_greater_than_59_58]0
[avcodec_version_greater_than_59_59]0
[avcodec_version_greater_than_59_60]0
[avcodec_version_greater_than_59_61]0
[avcodec_version_greater_than_59_62]0
[avcodec_version_greater_than_59_63]0
[avcodec_version_greater_than_59_64]0
[avcodec_version_greater_than_59_65]0
[avcodec_version_greater_than_59_66]0
[avcodec_version_greater_than_59_67]0
[avcodec_version_greater_than_59_68]0
[avcodec_version_greater_than_59_69]0
[avcodec_version_greater_than_59_70]0
[avcodec_version_greater_than_59_71]0
[avcodec_version_greater_than_59_72]0
[avcodec_version_greater_than_59_73]0
[avcodec_version_greater_than_59_74]0
[avcodec_version_greater_than_59_75]0
[avcodec_version_greater_than_59_76]0
[avcodec_version_greater_than_59_77]0
[avcodec_version_greater_than_59_78]0
[avcodec_version_greater_than_59_79]0

cargo:rustc-cfg=feature="ff_api_xvmc_is_defined"
cargo:ff_api_xvmc_is_defined=true
cargo:rustc-cfg=feature="ff_api_vaapi"
cargo:ff_api_vaapi=true
cargo:rustc-cfg=feature="ff_api_vaapi_is_defined"
cargo:ff_api_vaapi_is_defined=true
cargo:rustc-cfg=feature="ff_api_pkt_pts"
cargo:ff_api_pkt_pts=true
cargo:rustc-cfg=feature="ff_api_pkt_pts_is_defined"
cargo:ff_api_pkt_pts_is_defined=true
cargo:rustc-cfg=feature="ff_api_error_frame"
cargo:ff_api_error_frame=true
cargo:rustc-cfg=feature="ff_api_error_frame_is_defined"
cargo:ff_api_error_frame_is_defined=true
cargo:rustc-cfg=feature="ff_api_frame_qp"
cargo:ff_api_frame_qp=true
cargo:rustc-cfg=feature="ff_api_frame_qp_is_defined"
cargo:ff_api_frame_qp_is_defined=true
cargo:rustc-cfg=feature="ff_api_lowres"
cargo:ff_api_lowres=true
cargo:rustc-cfg=feature="ff_api_lowres_is_defined"
cargo:ff_api_lowres_is_defined=true
cargo:rustc-cfg=feature="ff_api_debug_mv_is_defined"
cargo:ff_api_debug_mv_is_defined=true
cargo:rustc-cfg=feature="ff_api_xvmc_is_defined"
cargo:ff_api_xvmc_is_defined=true
cargo:rustc-cfg=feature="ff_api_avctx_timebase"
cargo:ff_api_avctx_timebase=true
cargo:rustc-cfg=feature="ff_api_avctx_timebase_is_defined"
cargo:ff_api_avctx_timebase_is_defined=true
cargo:rustc-cfg=feature="ff_api_coded_frame"
cargo:ff_api_coded_frame=true
cargo:rustc-cfg=feature="ff_api_coded_frame_is_defined"
cargo:ff_api_coded_frame_is_defined=true
cargo:rustc-cfg=feature="ff_api_convergence_duration"
cargo:ff_api_convergence_duration=true
cargo:rustc-cfg=feature="ff_api_convergence_duration_is_defined"
cargo:ff_api_convergence_duration_is_defined=true
cargo:rustc-cfg=feature="ff_api_private_opt"
cargo:ff_api_private_opt=true
cargo:rustc-cfg=feature="ff_api_private_opt_is_defined"
cargo:ff_api_private_opt_is_defined=true
cargo:rustc-cfg=feature="ff_api_coder_type"
cargo:ff_api_coder_type=true
cargo:rustc-cfg=feature="ff_api_coder_type_is_defined"
cargo:ff_api_coder_type_is_defined=true
cargo:rustc-cfg=feature="ff_api_rtp_callback"
cargo:ff_api_rtp_callback=true
cargo:rustc-cfg=feature="ff_api_rtp_callback_is_defined"
cargo:ff_api_rtp_callback_is_defined=true
cargo:rustc-cfg=feature="ff_api_stat_bits"
cargo:ff_api_stat_bits=true
cargo:rustc-cfg=feature="ff_api_stat_bits_is_defined"
cargo:ff_api_stat_bits_is_defined=true
cargo:rustc-cfg=feature="ff_api_vbv_delay"
cargo:ff_api_vbv_delay=true
cargo:rustc-cfg=feature="ff_api_vbv_delay_is_defined"
cargo:ff_api_vbv_delay_is_defined=true
cargo:rustc-cfg=feature="ff_api_sidedata_only_pkt"
cargo:ff_api_sidedata_only_pkt=true
cargo:rustc-cfg=feature="ff_api_sidedata_only_pkt_is_defined"
cargo:ff_api_sidedata_only_pkt_is_defined=true
cargo:rustc-cfg=feature="ff_api_avpicture"
cargo:ff_api_avpicture=true
cargo:rustc-cfg=feature="ff_api_avpicture_is_defined"
cargo:ff_api_avpicture_is_defined=true
cargo:rustc-cfg=feature="ff_api_lavf_avctx"
cargo:ff_api_lavf_avctx=true
cargo:rustc-cfg=feature="ff_api_lavf_avctx_is_defined"
cargo:ff_api_lavf_avctx_is_defined=true
cargo:rustc-cfg=feature="ff_api_old_open_callbacks"
cargo:ff_api_old_open_callbacks=true
cargo:rustc-cfg=feature="ff_api_old_open_callbacks_is_defined"
cargo:ff_api_old_open_callbacks_is_defined=true
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_0"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_1"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_2"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_3"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_4"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_5"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_6"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_7"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_8"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_9"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_10"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_11"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_12"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_13"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_14"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_15"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_16"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_17"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_18"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_19"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_20"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_21"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_22"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_23"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_24"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_25"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_26"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_27"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_28"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_29"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_30"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_31"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_32"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_33"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_34"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_35"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_36"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_37"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_38"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_39"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_40"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_41"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_42"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_43"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_44"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_45"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_46"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_47"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_48"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_49"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_50"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_51"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_52"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_53"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_54"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_55"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_56"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_57"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_58"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_59"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_60"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_61"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_62"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_63"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_64"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_65"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_66"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_67"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_68"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_69"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_70"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_71"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_72"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_73"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_74"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_75"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_76"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_77"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_78"
cargo:rustc-cfg=feature="avcodec_version_greater_than_56_79"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_0"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_1"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_2"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_3"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_4"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_5"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_6"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_7"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_8"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_9"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_10"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_11"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_12"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_13"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_14"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_15"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_16"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_17"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_18"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_19"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_20"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_21"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_22"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_23"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_24"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_25"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_26"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_27"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_28"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_29"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_30"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_31"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_32"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_33"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_34"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_35"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_36"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_37"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_38"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_39"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_40"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_41"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_42"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_43"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_44"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_45"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_46"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_47"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_48"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_49"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_50"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_51"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_52"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_53"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_54"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_55"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_56"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_57"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_58"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_59"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_60"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_61"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_62"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_63"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_64"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_65"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_66"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_67"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_68"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_69"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_70"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_71"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_72"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_73"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_74"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_75"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_76"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_77"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_78"
cargo:rustc-cfg=feature="avcodec_version_greater_than_57_79"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_0"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_1"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_2"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_3"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_4"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_5"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_6"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_7"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_8"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_9"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_10"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_11"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_12"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_13"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_14"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_15"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_16"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_17"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_18"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_19"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_20"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_21"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_22"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_23"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_24"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_25"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_26"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_27"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_28"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_29"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_30"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_31"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_32"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_33"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_34"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_35"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_36"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_37"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_38"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_39"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_40"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_41"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_42"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_43"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_44"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_45"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_46"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_47"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_48"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_49"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_50"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_51"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_52"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_53"
cargo:rustc-cfg=feature="avcodec_version_greater_than_58_54"
OPT_LEVEL = Some("0")
TARGET = Some("x86_64-unknown-linux-gnu")
HOST = Some("x86_64-unknown-linux-gnu")
CC_x86_64-unknown-linux-gnu = None
CC_x86_64_unknown_linux_gnu = None
HOST_CC = None
CC = None
CFLAGS_x86_64-unknown-linux-gnu = None
CFLAGS_x86_64_unknown_linux_gnu = None
HOST_CFLAGS = None
CFLAGS = None
CRATE_CC_NO_DEFAULTS = None
DEBUG = Some("true")
CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2")

--- stderr
check.c:311:0: warning: "FF_API_XVMC_is_defined" redefined
             #define FF_API_XVMC_is_defined 1

check.c:84:0: note: this is the location of the previous definition
             #define FF_API_XVMC_is_defined 0

/usr/include/limits.h:124:16: fatal error: 'limits.h' file not found
/usr/include/limits.h:124:16: fatal error: 'limits.h' file not found, err: true
thread 'main' panicked at 'Unable to generate bindings: ()', src/libcore/result.rs:999:5
stack backtrace:
   0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
             at src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:39
   1: std::sys_common::backtrace::_print
             at src/libstd/sys_common/backtrace.rs:71
   2: std::panicking::default_hook::{{closure}}
             at src/libstd/sys_common/backtrace.rs:59
             at src/libstd/panicking.rs:197
   3: std::panicking::default_hook
             at src/libstd/panicking.rs:211
   4: std::panicking::rust_panic_with_hook
             at src/libstd/panicking.rs:474
   5: std::panicking::continue_panic_fmt
             at src/libstd/panicking.rs:381
   6: rust_begin_unwind
             at src/libstd/panicking.rs:308
   7: core::panicking::panic_fmt
             at src/libcore/panicking.rs:85
   8: core::result::unwrap_failed
             at /rustc/a53f9df32fbb0b5f4382caaad8f1a46f36ea887c/src/libcore/macros.rs:18
   9: core::result::Result<T,E>::expect
             at /rustc/a53f9df32fbb0b5f4382caaad8f1a46f36ea887c/src/libcore/result.rs:827
  10: build_script_build::main
             at ./build.rs:1021
  11: std::rt::lang_start::{{closure}}
             at /rustc/a53f9df32fbb0b5f4382caaad8f1a46f36ea887c/src/libstd/rt.rs:64
  12: std::panicking::try::do_call
             at src/libstd/rt.rs:49
             at src/libstd/panicking.rs:293
  13: __rust_maybe_catch_panic
             at src/libpanic_unwind/lib.rs:85
  14: std::rt::lang_start_internal
             at src/libstd/panicking.rs:272
             at src/libstd/panic.rs:394
             at src/libstd/rt.rs:48
  15: std::rt::lang_start
             at /rustc/a53f9df32fbb0b5f4382caaad8f1a46f36ea887c/src/libstd/rt.rs:64
  16: main
  17: __libc_start_main
  18: _start

Incorrect data structure fields on Ubuntu 14.04 with AVStream?

I'm not sure if there's anything you can do about this one, but I thought I would mention it. If you really want to reproduce this locally, I'm happy to provide source code and step-by-step repro instructions. But mostly I'm just sharing this because:

  1. Misery loves company, and
  2. This might raise interesting questions about how to handle #[repr(C)] struct definitions in the FFI.

I began by adding a metadata method to Stream:

    pub fn metadata(&self) -> Option<DictionaryRef> {
        unsafe {
            let metadata = (*self.as_ptr()).metadata;
            if metadata != ptr::null_mut() {
                Some(DictionaryRef::wrap((*self.as_ptr()).metadata))
            } else {
                None
            }
        }
    }

But when I tried to iterate over stream metadata, my program crashed. So I decided it was time to try out the rr debugger, which records execution traces, and which provides support for stepping backwards in GDB. So I downloaded it, and captured a recording of the crash:

rr record target/debug/substudy tracks a.mkv

Executing up to the crash and then rewinding back out of av_dict_get revealed some funny business:

TITLE: AVATAR_AIRBENDER_BK1VOL1
Stream #0

Program received signal SIGSEGV, Segmentation fault.
0x00007fc97262131f in av_dict_get ()
   from /usr/lib/x86_64-linux-gnu/libavutil.so.52
(rr) reverse-finish 
Run back to call of #0  0x00007fc97262131f in av_dict_get ()
   from /usr/lib/x86_64-linux-gnu/libavutil.so.52

Program received signal SIGSEGV, Segmentation fault.
0x00007fc97262131f in av_dict_get ()
   from /usr/lib/x86_64-linux-gnu/libavutil.so.52
(rr) bt
#0  0x00007fc97262131f in av_dict_get ()
   from /usr/lib/x86_64-linux-gnu/libavutil.so.52
#1  0x00007fc9734ccdb0 in ffmpeg::util::dictionary::iter::Iter<'a>.Iterator::next (self=0x7fff4adc1eb0) at rust-ffmpeg/src/util/dictionary/iter.rs:32
...
(rr) reverse-next
Single stepping until exit from function av_dict_get,
which has no line number information.
ffmpeg::util::dictionary::iter::Iter<'a>.Iterator::next (self=0x7fff4adc1eb0)
    at rust-ffmpeg/src/util/dictionary/iter.rs:32
32              let entry = av_dict_get(self.ptr, empty.as_ptr(), self.cur, AV_DICT_IGNORE_SUFFIX);
(rr) p self.ptr
$1 = (enum c_void *) 0xfb000000df

Wait, what? self.ptr is 0xfb000000df? How did I get a metadata dictionary pointer that looked like 0xfb000000df? That can't be right.

So I set a hardware watchpoint on the bogus pointer, and run backwards until I see that pointer being set:

(rr) watch -l self.ptr
Hardware watchpoint 1: -location self.ptr
(rr) reverse-continue 
Continuing.
Hardware watchpoint 1: -location self.ptr

Repeating this process several times eventually brings me to:

$9 = (enum c_void *) 0xfb000000df
(rr) watch -l self.context.ptr.streams[0].metadata
Hardware watchpoint 3: -location self.context.ptr.streams[0].metadata
(rr) rc
Continuing.
Hardware watchpoint 3: -location self.context.ptr.streams[0].metadata

Old value = (enum c_void *) 0xfb000000df
New value = (enum c_void *) 0x1000000df
0x00007fc97262aef6 in av_reduce ()
   from /usr/lib/x86_64-linux-gnu/libavutil.so.52
(rr) bt
#0  0x00007fc97262aef6 in av_reduce ()
   from /usr/lib/x86_64-linux-gnu/libavutil.so.52
#1  0x00007fc9713e3baa in ?? ()
   from /usr/lib/x86_64-linux-gnu/libavformat.so.54
#2  0x00007fc97146084d in avformat_open_input ()
   from /usr/lib/x86_64-linux-gnu/libavformat.so.54
#3  0x00007fc9733a8c80 in substudy::format::input<std::path::PathBuf> (
    path=0x7fff4adc2348) at rust-ffmpeg/src/format/mod.rs:154

So the bogus pointer in self.context.ptr.streams[0].metadata is being created by av_reduce inside of avformat_open_input. But wait, av_reduce performs calculations with rational numbers. That shouldn't have anything to do with metadata. But let's take a look at AVStream again:

    pub sample_aspect_ratio: AVRational,
    pub metadata: *mut AVDictionary,
    pub avg_frame_rate: AVRational,

Yup. metadata is right between two rational fields. Time to compare the Rust structure:

#[repr(C)]
pub struct AVStream {
    pub index: c_int,
    pub id: c_int,
    pub codec: *mut AVCodecContext,
    pub priv_data: *mut c_void,
    pub pts: AVFrac, // XXX: #if FF_API_LAVF_FRAC
    pub time_base: AVRational,
    pub start_time: int64_t,
    pub duration: int64_t,
    pub nb_frames: int64_t,
    pub disposition: c_int,
    pub discard: AVDiscard,
    pub sample_aspect_ratio: AVRational,
    pub metadata: *mut AVDictionary,
    pub avg_frame_rate: AVRational,
    pub attached_pic: AVPacket,

To the C version on my local system:

typedef struct AVStream {
    int index;    /**< stream index in AVFormatContext */
    int id;
    AVCodecContext *codec;
#if FF_API_R_FRAME_RATE
    AVRational r_frame_rate;
#endif
    void *priv_data;
    struct AVFrac pts;
    AVRational time_base;
    int64_t start_time;
    int64_t duration;
    int64_t nb_frames;                 ///< number of frames in this stream if known or 0
    int disposition; /**< AV_DISPOSITION_* bit field */
    enum AVDiscard discard; ///< Selects which packets can be discarded at will and do not need to be demuxed.
    AVRational sample_aspect_ratio;
    AVDictionary *metadata;
    AVRational avg_frame_rate;
    AVPacket attached_pic;

Oooh, what's this FF_API_R_FRAME_RATE thing? Let's grep a bit:

#define FF_API_R_FRAME_RATE            (LIBAVFORMAT_VERSION_MAJOR < 55)
#define LIBAVFORMAT_VERSION_MAJOR 54
/**
 * FF_API_* defines may be placed below to indicate public API that will be
 * dropped at a future version bump. The defines themselves are not part of
 * the public API and may change, break or disappear at any time.
 */

Bingo. So now we know that ffmpeg-sys requires at least LIBAVFORMAT_VERSION_MAJOR 55 to work, but Ubuntu 14.04 only ships 54. And with 54, ffmpeg-sys will look for the metadata field where libavformat has actually stored avg_frame_rate. Which explains why backwards tracing with hardware breakpoints thinks that our metadata pointer was created by av_reduce.

pounds head on desk

I don't have any good answers here.

Build failure of the new bindgen-based bindings

Arch Linux x64, ffmpeg 1:3.3.2-1, 9d63d3b

cargo build gives me:

thread 'main' panicked at 'TranslationUnit::parse failed', /checkout/src/libcore/option.rs:785
stack backtrace:
   0: std::sys::imp::backtrace::tracing::imp::unwind_backtrace
             at /checkout/src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::_print
             at /checkout/src/libstd/sys_common/backtrace.rs:71
   2: std::panicking::default_hook::{{closure}}
             at /checkout/src/libstd/sys_common/backtrace.rs:60
             at /checkout/src/libstd/panicking.rs:355
   3: std::panicking::default_hook
             at /checkout/src/libstd/panicking.rs:371
   4: std::panicking::rust_panic_with_hook
             at /checkout/src/libstd/panicking.rs:549
   5: std::panicking::begin_panic
             at /checkout/src/libstd/panicking.rs:511
   6: std::panicking::begin_panic_fmt
             at /checkout/src/libstd/panicking.rs:495
   7: rust_begin_unwind
             at /checkout/src/libstd/panicking.rs:471
   8: core::panicking::panic_fmt
             at /checkout/src/libcore/panicking.rs:69
   9: core::option::expect_failed
             at /checkout/src/libcore/option.rs:785
  10: <core::option::Option<T>>::expect
             at /checkout/src/libcore/option.rs:293
  11: bindgen::ir::context::BindgenContext::new
             at /home/yalter/.cargo/registry/src/github.com-1ecc6299db9ec823/bindgen-0.26.2/src/ir/context.rs:231
  12: bindgen::Bindings::generate
             at /home/yalter/.cargo/registry/src/github.com-1ecc6299db9ec823/bindgen-0.26.2/src/lib.rs:1095
  13: bindgen::Builder::generate
             at /home/yalter/.cargo/registry/src/github.com-1ecc6299db9ec823/bindgen-0.26.2/src/lib.rs:798
  14: build_script_build::main
             at ./build.rs:860
  15: std::panicking::try::do_call
             at /checkout/src/libstd/panicking.rs:454
  16: __rust_maybe_catch_panic
             at /checkout/src/libpanic_unwind/lib.rs:98
  17: std::rt::lang_start
             at /checkout/src/libstd/panicking.rs:433
             at /checkout/src/libstd/panic.rs:361
             at /checkout/src/libstd/rt.rs:57
  18: main
  19: __libc_start_main
  20: _start

Doesn't compile without `avcodec`

Looks like it wants to perform some sort of version check.

> RUST_BACKTRACE=1 cargo build --no-default-features
   Compiling ffmpeg-sys v4.3.3 (/home/wastl/rust-ffmpeg-sys)
error: failed to run custom build command for `ffmpeg-sys v4.3.3 (/home/wastl/rust-ffmpeg-sys)`

Caused by:
  process didn't exit successfully: `/home/wastl/rust-ffmpeg-sys/target/debug/build/ffmpeg-sys-9303192e62d3579d/build-script-build` (exit status: 101)
  --- stdout
  cargo:rerun-if-env-changed=LIBAVUTIL_NO_PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=SYSROOT
  cargo:rerun-if-env-changed=PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:rustc-link-search=native=/usr/lib/x86_64-linux-gnu
  cargo:rustc-link-lib=avutil
  cargo:rerun-if-env-changed=LIBAVCODEC_NO_PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=SYSROOT
  cargo:rerun-if-env-changed=PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
  cargo:rustc-link-search=native=/usr/lib/x86_64-linux-gnu
  cargo:rustc-link-lib=avcodec
  OPT_LEVEL = Some("0")
  HOST = Some("x86_64-unknown-linux-gnu")
  CC_x86_64-unknown-linux-gnu = None
  CC_x86_64_unknown_linux_gnu = None
  HOST_CC = None
  CC = None
  CFLAGS_x86_64-unknown-linux-gnu = None
  CFLAGS_x86_64_unknown_linux_gnu = None
  HOST_CFLAGS = None
  CFLAGS = None
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some("true")
  CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2")

  --- stderr
  Using stack size: Ok(3145728)
  check.c: In function ‘main’:
  check.c:198:63: error: ‘LIBAVCODEC_VERSION_MAJOR’ undeclared (first use in this function); did you mean ‘LIBAVUTIL_VERSION_MAJOR’?
    198 |             printf("[avcodec_version_greater_than_56_0]%d\n", LIBAVCODEC_VERSION_MAJOR > 56 || (LIBAVCODEC_VERSION_MAJOR == 56 && LIBAVCODEC_VERSION_MINOR > 0));
        |                                                               ^~~~~~~~~~~~~~~~~~~~~~~~
        |                                                               LIBAVUTIL_VERSION_MAJOR
  check.c:198:63: note: each undeclared identifier is reported only once for each function it appears in
  check.c:198:131: error: ‘LIBAVCODEC_VERSION_MINOR’ undeclared (first use in this function); did you mean ‘LIBAVUTIL_VERSION_MINOR’?
    198 |             printf("[avcodec_version_greater_than_56_0]%d\n", LIBAVCODEC_VERSION_MAJOR > 56 || (LIBAVCODEC_VERSION_MAJOR == 56 && LIBAVCODEC_VERSION_MINOR > 0));
        |                                                                                                                                   ^~~~~~~~~~~~~~~~~~~~~~~~
        |                                                                                                                                   LIBAVUTIL_VERSION_MINOR
  thread 'ffmpg-sys-build' panicked at 'Compile failed', build.rs:488:9
  stack backtrace:
     0: std::panicking::begin_panic
               at /rustc/a178d0322ce20e33eac124758e837cbd80a6f633/library/std/src/panicking.rs:541:12
     1: build_script_build::check_features
               at ./build.rs:488:9
     2: build_script_build::thread_main
               at ./build.rs:765:5
     3: core::ops::function::FnOnce::call_once
               at /rustc/a178d0322ce20e33eac124758e837cbd80a6f633/library/core/src/ops/function.rs:227:5
  note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
  thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Any { .. }', build.rs:629:10
  stack backtrace:
     0: rust_begin_unwind
               at /rustc/a178d0322ce20e33eac124758e837cbd80a6f633/library/std/src/panicking.rs:515:5
     1: core::panicking::panic_fmt
               at /rustc/a178d0322ce20e33eac124758e837cbd80a6f633/library/core/src/panicking.rs:92:14
     2: core::result::unwrap_failed
               at /rustc/a178d0322ce20e33eac124758e837cbd80a6f633/library/core/src/result.rs:1355:5
     3: core::result::Result<T,E>::unwrap
               at /rustc/a178d0322ce20e33eac124758e837cbd80a6f633/library/core/src/result.rs:1037:23
     4: build_script_build::main
               at ./build.rs:623:5
     5: core::ops::function::FnOnce::call_once
               at /rustc/a178d0322ce20e33eac124758e837cbd80a6f633/library/core/src/ops/function.rs:227:5
  note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

The other components can be turned off without problems (i.e. cargo build --no-default-features --features avcodec runs fine).

Build script failing on Windows with a stack overflow

rustc 1.49.0 stable-x86_64-pc-windows-gnu
Windows 10 19042.746

error: failed to run custom build command for `ffmpeg-sys v4.2.1

Caused by:
  process didn't exit successfully: `[...]\target\release\build\ffmpeg-sys-8f4a0330768df3c3\build-script-build` (exit code: 0xc00000fd, STATUS_STACK_OVERFLOW)
  --- stderr

  thread 'main' has overflowed its stack

After digging around in std::sys for awhile, it seems like the main thread on Windows is getting a stack overflow guard with a (hardcoded) very low minimum stack size. Commenting out ~half of the .header(...) method calls causes the overflow to stop happening. Spawning a new thread with 3MiB of stack space and just waiting on it in main has resolved the issue for me.

Note: I'm linking to dynamic libraries, not having ffmpeg-sys build ffmpeg.

regression on master: AVMotionVector

version 3.2.1 contains a struct AVMotionVector, building master (90981e4) it is absent.

arch linux

ffmpeg version 3.3.2 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 7.1.1 (GCC) 20170516
configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-avisynth --enable-avresample --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libass --enable-libbluray --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxvid --enable-shared --enable-version3
libavutil      55. 58.100 / 55. 58.100
libavcodec     57. 89.100 / 57. 89.100
libavformat    57. 71.100 / 57. 71.100
libavdevice    57.  6.100 / 57.  6.100
libavfilter     6. 82.100 /  6. 82.100
libavresample   3.  5.  0 /  3.  5.  0
libswscale      4.  6.100 /  4.  6.100
libswresample   2.  7.100 /  2.  7.100
libpostproc    54.  5.100 / 54.  5.100

failed to run custom build command for `ffmpeg-sys v2.8.9`

In Rust Hello world.

I just add one line in Cargo.toml

[dependencies]
ffmpeg-sys = "2.8.9"

then run cargo run , throw error

   Compiling ffmpeg-sys v2.8.9
error: failed to run custom build command for `ffmpeg-sys v2.8.9`
process didn't exit successfully: `C:\Users\jinzw\git\video_recoder\target\debug\build\ffmpeg-sys-11ede06eced1608f\build-script-build` (exit code: 101)
--- stderr
thread 'main' panicked at 'Command failed: Error { repr: Os { code: 2, message: "\u{7cfb}\u{7edf}\u{627e}\u{4e0d}\u{5230}\u{6307}\u{5b9a}\u{7684}\u{6587}\u{4ef6}\u{3002}" } }', ../src/libcore\result.rs:788
note: Run with `RUST_BACKTRACE=1` for a backtrace.

Win 10
Rust 1.11

Compilation failure: note: /usr/bin/ld: cannot find -lavutil

Thank you for releasing an alpha version of the ffmpeg crate!

I tried building an application using ffmpeg as follows:

git clone https://github.com/emk/substudy.git
cd substudy
git checkout ffmpeg
cargo test

This gave me the following error:

   Compiling substudy v0.1.1 (file:///home/emk/w/src/substudy)
error: linking with `cc` failed: exit code: 1
note: "cc" "-Wl,--as-needed" "-m64" "-L" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib" "/home/emk/w/src/substudy/target/debug/substudy-25f431e2769ace13.0.o" "-o" "/home/emk/w/src/substudy/target/debug/substudy-25f431e2769ace13" "-Wl,--gc-sections" "-pie" "-nodefaultlibs" "/home/emk/w/src/substudy/target/debug/deps/liblog-35171053ffe7ab96.rlib" "/home/emk/w/src/substudy/target/debug/deps/libencoding-a635ee1112a4a115.rlib" "/home/emk/w/src/substudy/target/debug/deps/libencoding_index_japanese-02d1e3db3f81af39.rlib" "/home/emk/w/src/substudy/target/debug/deps/libencoding_index_simpchinese-36d98fe1ee6656fc.rlib" "/home/emk/w/src/substudy/target/debug/deps/liblibc-29adb837ec836726.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/libtest-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/libserialize-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/libterm-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/liblog-1bf6e69c.rlib" "/home/emk/w/src/substudy/target/debug/deps/libencoding_index_singlebyte-989206689effef1e.rlib" "/home/emk/w/src/substudy/target/debug/deps/libencoding_index_tradchinese-1ea03524459844c3.rlib" "/home/emk/w/src/substudy/target/debug/deps/libregex-c5abedf84fe61ddb.rlib" "/home/emk/w/src/substudy/target/debug/deps/libaho_corasick-713d9a23dcd56f15.rlib" "/home/emk/w/src/substudy/target/debug/deps/libmemchr-49395bf503c0fa9c.rlib" "/home/emk/w/src/substudy/target/debug/deps/libffmpeg-9b3f15ec48a81b15.rlib" "/home/emk/w/src/substudy/target/debug/deps/libffmpeg_sys-72b52694e5f2edc4.rlib" "/home/emk/w/src/substudy/target/debug/deps/libbitflags-eec34728826d9769.rlib" "/home/emk/w/src/substudy/target/debug/deps/libregex_syntax-6d9e9f3bd76497d4.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/libgetopts-1bf6e69c.rlib" "/home/emk/w/src/substudy/target/debug/deps/libuchardet-19094d88b657fbb7.rlib" "/home/emk/w/src/substudy/target/debug/deps/libuchardet_sys-d6c135eb96b7863f.rlib" "/home/emk/w/src/substudy/target/debug/deps/liblibc-540159808ccfa9ab.rlib" "/home/emk/w/src/substudy/target/debug/deps/libencoding_index_korean-e6ea16a131576deb.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcollections-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_unicode-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/librand-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc_jemalloc-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/liblibc-1bf6e69c.rlib" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-1bf6e69c.rlib" "-L" "/home/emk/w/src/substudy/target/debug" "-L" "/home/emk/w/src/substudy/target/debug/deps" "-L" "/home/emk/w/src/substudy/target/debug/build/uchardet-sys-d6c135eb96b7863f/out/lib" "-L" "/home/emk/.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-L" "/home/emk/w/src/substudy/.rust/lib/x86_64-unknown-linux-gnu" "-L" "/home/emk/w/src/substudy/lib/x86_64-unknown-linux-gnu" "-Wl,-Bstatic" "-Wl,-Bdynamic" "-l" "c" "-l" "m" "-l" "avutil" "-l" "avcodec" "-l" "avdevice" "-l" "avformat" "-l" "avfilter" "-l" "avresample" "-l" "swresample" "-l" "swscale" "-l" "stdc++" "-l" "dl" "-l" "pthread" "-l" "gcc_s" "-l" "rt" "-l" "pthread" "-l" "c" "-l" "m" "-Wl,-rpath,$ORIGIN/../../../../../.multirust/toolchains/stable/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-Wl,-rpath,/usr/local/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-l" "compiler-rt"
note: /usr/bin/ld: cannot find -lavutil
/usr/bin/ld: cannot find -lavcodec
/usr/bin/ld: cannot find -lavdevice
/usr/bin/ld: cannot find -lavformat
/usr/bin/ld: cannot find -lavfilter
/usr/bin/ld: cannot find -lavresample
/usr/bin/ld: cannot find -lswresample
/usr/bin/ld: cannot find -lswscale
collect2: error: ld returned 1 exit status

I'm running Ubuntu 14.04. My ffmpeg build directory is empty:

$ tree target/debug/build/ffmpeg-sys-72b52694e5f2edc4/
target/debug/build/ffmpeg-sys-72b52694e5f2edc4/
├── build-script-build
├── out
└── output

1 directory, 2 files

Also:

$ dpkg -l '*avutil*'
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-=================================
ii  libavutil52:am 6:9.18-0ubun amd64        Libav utility library

I'm not sure what's going on here, but it's probably some fairly obvious build-system issue that I'm too tired to see right now.

Thank you for wrapping this library; I can't wait to take it for a spin.

"build" feature fails to link avresample

I'm building on macOS 10.13 using ffmpeg-sys 8a6d9c6

[dependencies.ffmpeg]
git = "https://github.com/pornel/rust-ffmpeg.git" # that pulls ffmpeg-rs master with ffmpeg-sys master
features = ["build"]

and crate a binary like this:

extern crate ffmpeg;
fn main() {ffmpeg::init().unwrap()}

cargo build fails with an error:

 = note: Undefined symbols for architecture x86_64:
            "_avresample_get_delay", referenced from:
                _filter_frame in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_get_out_samples", referenced from:
                _filter_frame in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
                _request_frame in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_close", referenced from:
                _uninit in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
                _config_output in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_convert", referenced from:
                _filter_frame in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
                _request_frame in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_available", referenced from:
                _filter_frame in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_alloc_context", referenced from:
                _config_output in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_free", referenced from:
                _uninit in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
                _config_output in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_open", referenced from:
                _config_output in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
            "_avresample_get_class", referenced from:
                _init in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
                _resample_child_class_next in libffmpeg_sys-e10cd590959afb4b.rlib(af_resample.o)
          ld: symbol(s) not found for architecture x86_64
          clang: error: linker command failed with exit code 1 (use -v to see invocation)

Build fails on Windows 10 64bit: { command: "\"pkg-config\" \"--libs\" \"--cflags\" \"libavformat\"", cause: Os { code: 2, kind: NotFound, message: "The system cannot find the file specified." }}

I'll probably work around this by using a pre-built version of ffmpeg which should avoid any issues building it.

Full output

 Compiling ffmpeg-sys v3.4.1
error: failed to run custom build command for `ffmpeg-sys v3.4.1`
process didn't exit successfully: `C:\<snip>\target\debug\build\ffmpeg-sys-a162081edadd1e97\build-script-build` (exit code: 101)
--- stderr
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Command { command: "\"pkg-config\" \"--libs\" \"--cflags\" \"libavformat\"", cause: Os { code: 2, kind: NotFound, message: "The system cannot find the file specified." } }', libcore\result.rs:945:5
stack backtrace:
   0: <std::sync::mpsc::select::Select as core::fmt::Debug>::fmt
   1: std::stdsimd::arch::detect::os::check_for
   2: std::panicking::take_hook
   3: std::panicking::take_hook
   4: std::panicking::rust_panic_with_hook
   5: std::panicking::begin_panic_fmt
   6: rust_begin_unwind
   7: core::panicking::panic_fmt
   8: core::result::unwrap_failed<pkg_config::Error>
             at C:\projects\rust\src\libcore\macros.rs:26
   9: core::result::Result<pkg_config::Library, pkg_config::Error>::unwrap<pkg_config::Library,pkg_config::Error>
             at C:\projects\rust\src\libcore\result.rs:782
  10: build_script_build::main
             at .\build.rs:518
  11: std::rt::lang_start::{{closure}}<()>
             at C:\projects\rust\src\libstd\rt.rs:74
  12: std::panicking::update_panic_count
  13: _rust_maybe_catch_panic
  14: std::rt::lang_start_internal
  15: std::rt::lang_start<()>
             at C:\projects\rust\src\libstd\rt.rs:74
  16: main
  17: invoke_main
             at f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:78
  18: __scrt_common_main_seh
             at f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:283
  19: BaseThreadInitThunk
  20: RtlUserThreadStart

Support overriding in Cargo config

I have built ffmpeg myself and want to use it with ffmpeg-sys. I'm overriding build script as described here. The issue is that build script in addition to actually building the library also detects its features. If I override the build script I will have to manually specify all these features which is error prone.

To allow overriding I think that ffmpeg-sys must be split into two crates.

  1. ffmpeg-sys-builld will only contain a build script to build ffmpeg (or find an existing installation) and will declare links value in it's Cargo.toml.
  2. ffmpeg-sys will depend on ffmpeg-sys-builld and contain build script which detects features.

This way it will be possible to use overriding mechanism as it will only override the build of ffmpeg (in ffmpeg-sys-builld/build.rs) but feature detection (in ffmpeg-sys/build.rs) will work as usual.

Building twice fails when re-fetching ffmpeg

I've got a build error due to missing deps, and when I ran cargo build for a second time I got this:

fatal: destination path 'ffmpeg-3.4' already exists and is not an empty directory.
thread 'main' panicked at 'called Result::unwrap() on an Err value: Error { repr: Custom(Custom { kind: Other, error: StringError("fetch failed") }) }', src/libcore/result.rs:906:4

I presume there's an unconditional git clone involved. Deleting the directory before the clone (or skipping clone when it exists) would prevent the problem.

cargo clean works as a workaround, but it's slower than re-running cached build would be.

Build failures due to missing libavresample

The package won't build on recent Archlinux installations due to libavresample being dropped..

This is expected behavior in the normal configuration, the lib is, after all, missing. When however disabling the respective feature the build will still fail with: "Package libavresample was not found in the pkg-config search path"

This is due to pkg-conf being called regardless of the feature being enabled. I wrote a quick fix for this in build.rs. Not sure if this is a great solution so let me know if you need any changes. The PR will follow in a minute.

This bug doesn't occur when FFMPEG_DIR is set.

cannot compile `ffmpeg-sys`

Hey there, I'm trying to build rust-ffmpeg, but it breaks when trying to compile ffmpeg-sys v.3.4.1.

There seems to be a bunch of errors so I feel like I'm missing something here... any help is appreciated. See the error output below:

khuynh@kmbp:dev/rust-ffmpeg ‹master›$ rustc --version
rustc 1.43.0 (4fb7144ed 2020-04-20)
khuynh@kmbp:dev/rust-ffmpeg ‹master›$ ffmpeg
ffmpeg version 4.2.2 Copyright (c) 2000-2019 the FFmpeg developers
  built with Apple clang version 11.0.0 (clang-1100.0.33.17)
  configuration: --prefix=/usr/local/Cellar/ffmpeg/4.2.2_2 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libmp3lame --enable-libopus --enable-librubberband --enable-libsnappy --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack
  libavutil      56. 31.100 / 56. 31.100
  libavcodec     58. 54.100 / 58. 54.100
  libavformat    58. 29.100 / 58. 29.100
  libavdevice    58.  8.100 / 58.  8.100
  libavfilter     7. 57.100 /  7. 57.100
  libavresample   4.  0.  0 /  4.  0.  0
  libswscale      5.  5.100 /  5.  5.100
  libswresample   3.  5.100 /  3.  5.100
  libpostproc    55.  5.100 / 55.  5.100
Hyper fast Audio and Video encoder
usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...

Use -h to get full help or, even better, run 'man ffmpeg'
khuynh@kmbp:dev/rust-ffmpeg ‹master›$ cargo build
   Compiling libc v0.2.69
   Compiling lazy_static v1.4.0
   Compiling memchr v2.3.3
   Compiling glob v0.2.11
   Compiling log v0.4.8
   Compiling ucd-util v0.1.8
   Compiling libloading v0.4.3
   Compiling bitflags v1.2.1
   Compiling cfg-if v0.1.10
   Compiling regex v0.2.11
   Compiling unicode-xid v0.1.0
   Compiling utf8-ranges v1.0.4
   Compiling unicode-width v0.1.7
   Compiling ansi_term v0.11.0
   Compiling bindgen v0.32.3
   Compiling vec_map v0.8.1
   Compiling strsim v0.8.0
   Compiling peeking_take_while v0.1.2
   Compiling cc v1.0.52
   Compiling pkg-config v0.3.17
   Compiling ffmpeg v0.2.0-alpha.2 (/Volumes/hdd/dev/rust-ffmpeg)
   Compiling bitflags v0.9.1
   Compiling thread_local v0.3.6
   Compiling regex-syntax v0.5.6
   Compiling proc-macro2 v0.2.3
   Compiling textwrap v0.11.0
   Compiling clang-sys v0.21.2
   Compiling quote v0.4.2
   Compiling log v0.3.9
   Compiling aho-corasick v0.6.10
   Compiling memchr v1.0.2
   Compiling atty v0.2.14
   Compiling which v1.0.5
   Compiling num_cpus v1.13.0
   Compiling nom v3.2.1
   Compiling clap v2.33.0
   Compiling cexpr v0.2.3
   Compiling env_logger v0.4.3
   Compiling ffmpeg-sys v3.4.1
error[E0369]: binary operation `==` cannot be applied to type `[i8; 56]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1694:5
     |
1694 |     pub __opaque: [libc::c_char; 56usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 56]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1694:5
     |
1694 |     pub __opaque: [libc::c_char; 56usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1694:5
     |
1694 |     pub __opaque: [libc::c_char; 56usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 56]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 56]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 40]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1733:5
     |
1733 |     pub __opaque: [libc::c_char; 40usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 40]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1733:5
     |
1733 |     pub __opaque: [libc::c_char; 40usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1733:5
     |
1733 |     pub __opaque: [libc::c_char; 40usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 40]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 40]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 56]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1815:5
     |
1815 |     pub __opaque: [libc::c_char; 56usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 56]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1815:5
     |
1815 |     pub __opaque: [libc::c_char; 56usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1815:5
     |
1815 |     pub __opaque: [libc::c_char; 56usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 56]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 56]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 192]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1938:5
     |
1938 |     pub __opaque: [libc::c_char; 192usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 192]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1938:5
     |
1938 |     pub __opaque: [libc::c_char; 192usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:1938:5
     |
1938 |     pub __opaque: [libc::c_char; 192usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 192]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 192]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 8176]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:2023:5
     |
2023 |     pub __opaque: [libc::c_char; 8176usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 8176]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:2023:5
     |
2023 |     pub __opaque: [libc::c_char; 8176usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:2023:5
     |
2023 |     pub __opaque: [libc::c_char; 8176usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 8176]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 8176]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:4764:5
     |
4764 |     pub __zmm_reg: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:4764:5
     |
4764 |     pub __zmm_reg: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:4764:5
     |
4764 |     pub __zmm_reg: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 64]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 64]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 224]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:4852:5
     |
4852 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 224]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:4852:5
     |
4852 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:4852:5
     |
4852 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 224]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 224]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 224]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5288:5
     |
5288 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5290:5
     |
5290 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 224]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5288:5
     |
5288 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5290:5
     |
5290 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5288:5
     |
5288 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 224]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 224]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5290:5
     |
5290 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 64]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 64]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 224]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5838:5
     |
5838 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5840:5
     |
5840 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 224]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5838:5
     |
5838 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5840:5
     |
5840 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5838:5
     |
5838 |     pub __fpu_rsrv4: [libc::c_char; 224usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 224]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 224]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:5840:5
     |
5840 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 64]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 64]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 96]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7175:5
     |
7175 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 96]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7175:5
     |
7175 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7175:5
     |
7175 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 96]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 96]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 96]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7715:5
     |
7715 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7717:5
     |
7717 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 96]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7715:5
     |
7715 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7717:5
     |
7717 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7715:5
     |
7715 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 96]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 96]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:7717:5
     |
7717 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 64]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 64]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 96]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:8476:5
     |
8476 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:8478:5
     |
8478 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 96]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:8476:5
     |
8476 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 64]`
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:8478:5
     |
8478 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:8476:5
     |
8476 |     pub __fpu_rsrv4: [libc::c_char; 96usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 96]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 96]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
    --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:8478:5
     |
8478 |     pub __avx_reserved1: [libc::c_char; 64usize],
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 64]`
     |
     = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 64]`
     = note: required by `std::cmp::AssertParamIsEq`
     = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `sigval`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10611:5
      |
10611 |     pub sigev_value: sigval,
      |     ^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `sigval`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `sigval`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10611:5
      |
10611 |     pub sigev_value: sigval,
      |     ^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `sigval`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: the trait bound `sigval: std::cmp::Eq` is not satisfied
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10611:5
      |
10611 |     pub sigev_value: sigval,
      |     ^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::cmp::Eq` is not implemented for `sigval`
      |
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `sigval`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10690:5
      |
10690 |     pub si_value: sigval,
      |     ^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `sigval`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `sigval`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10690:5
      |
10690 |     pub si_value: sigval,
      |     ^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `sigval`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: the trait bound `sigval: std::cmp::Eq` is not satisfied
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10690:5
      |
10690 |     pub si_value: sigval,
      |     ^^^^^^^^^^^^^^^^^^^^ the trait `std::cmp::Eq` is not implemented for `sigval`
      |
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `__sigaction_u`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10853:5
      |
10853 |     pub __sigaction_u: __sigaction_u,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `__sigaction_u`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `__sigaction_u`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10853:5
      |
10853 |     pub __sigaction_u: __sigaction_u,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `__sigaction_u`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: the trait bound `__sigaction_u: std::cmp::Eq` is not satisfied
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10853:5
      |
10853 |     pub __sigaction_u: __sigaction_u,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::cmp::Eq` is not implemented for `__sigaction_u`
      |
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `__sigaction_u`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10922:5
      |
10922 |     pub __sigaction_u: __sigaction_u,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `__sigaction_u`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `__sigaction_u`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10922:5
      |
10922 |     pub __sigaction_u: __sigaction_u,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `__sigaction_u`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: the trait bound `__sigaction_u: std::cmp::Eq` is not satisfied
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:10922:5
      |
10922 |     pub __sigaction_u: __sigaction_u,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::cmp::Eq` is not implemented for `__sigaction_u`
      |
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `AVOption__bindgen_ty_1`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:28308:5
      |
28308 |     pub default_val: AVOption__bindgen_ty_1,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `AVOption__bindgen_ty_1`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `AVOption__bindgen_ty_1`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:28308:5
      |
28308 |     pub default_val: AVOption__bindgen_ty_1,
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: an implementation of `std::cmp::PartialEq` might be missing for `AVOption__bindgen_ty_1`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 1024]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:33506:5
      |
33506 |     pub filename: [libc::c_char; 1024usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 1024]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:33506:5
      |
33506 |     pub filename: [libc::c_char; 1024usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:33506:5
      |
33506 |     pub filename: [libc::c_char; 1024usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 1024]`
      |
      = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 1024]`
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 61440]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:37351:5
      |
37351 |     pub reserved: [libc::c_char; 61440usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 61440]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:37351:5
      |
37351 |     pub reserved: [libc::c_char; 61440usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:37351:5
      |
37351 |     pub reserved: [libc::c_char; 61440usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 61440]`
      |
      = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 61440]`
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[[u32; 256]; 4]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:40010:5
      |
40010 |     pub s: [[u32; 256usize]; 4usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[[u32; 256]; 4]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:40010:5
      |
40010 |     pub s: [[u32; 256usize]; 4usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:40010:5
      |
40010 |     pub s: [[u32; 256usize]; 4usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[u32; 256]`
      |
      = note: required because of the requirements on the impl of `std::cmp::Eq` for `[u32; 256]`
      = note: required because of the requirements on the impl of `std::cmp::Eq` for `[[u32; 256]; 4]`
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[i8; 1000]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:40539:5
      |
40539 |     pub reserved_padding: [libc::c_char; 1000usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[i8; 1000]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:40539:5
      |
40539 |     pub reserved_padding: [libc::c_char; 1000usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:40539:5
      |
40539 |     pub reserved_padding: [libc::c_char; 1000usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[i8; 1000]`
      |
      = note: required because of the requirements on the impl of `std::cmp::Eq` for `[i8; 1000]`
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `==` cannot be applied to type `[u32; 64]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:42287:5
      |
42287 |     pub state: [libc::c_uint; 64usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0369]: binary operation `!=` cannot be applied to type `[u32; 64]`
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:42287:5
      |
42287 |     pub state: [libc::c_uint; 64usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      |
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: arrays only have std trait implementations for lengths 0..=32
     --> /Volumes/hdd/dev/rust-ffmpeg/target/debug/build/ffmpeg-sys-0509fe9e92bd50b3/out/bindings.rs:42287:5
      |
42287 |     pub state: [libc::c_uint; 64usize],
      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::array::LengthAtMost32` is not implemented for `[u32; 64]`
      |
      = note: required because of the requirements on the impl of `std::cmp::Eq` for `[u32; 64]`
      = note: required by `std::cmp::AssertParamIsEq`
      = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

error: aborting due to 77 previous errors

Some errors have detailed explanations: E0277, E0369.
For more information about an error, try `rustc --explain E0277`.
error: could not compile `ffmpeg-sys`.

To learn more, run the command again with --verbose.

Fails to compile without specific environment vars

Hi - I'm new to rust just pulled this library into my Cargo.toml, but unfortunately the build fails:
$ cargo build --verbose
check.c:3:32: fatal error: libavutil/avutil.h: No such file or directory

I'm running a brand new Ubuntu 16.04 desktop with the usual developer tools installed.

Looking through the code I found the environment vars to set and came to this command line which produces a build:
$ CARGO_FEATURE_BUILD= OUT_DIR=target cargo build

Is there some rusty-reason why this should be clearer to me? Or could the build.rs code fallback to defaults if needed?

  • Build w/ toolchain if not built
  • Use rust target directory

Thanks for this amazing repository!!

rust-ffmpeg-sys complains about missing definition

I am using FFMpeg 2.8.2 on Fedora system. Rust installation via cargo fails:

failed to run custom build command for `ffmpeg-sys v2.8.3-2`
Process didn't exit successfully: `/home/ibrasiskis/src/FramePlayerRust/target/debug/build/ffmpeg-sys-773b40f81173fb5a/build-script-build` (exit code: 101)
--- stderr
check.c: In function ‘main’:
check.c:8:19: error: ‘FF_API_OLD_AVOPTIONS’ undeclared (first use in this function)
    printf("%d\n", FF_API_OLD_AVOPTIONS);
                   ^
check.c:8:19: note: each undeclared identifier is reported only once for each function it appears in
thread '<main>' panicked at 'called `Result::unwrap()` on an `Err` value: Error { repr: Os { code: 2, message: "No such file or directory" } }', ../src/libcore/result.rs:738

It seems it is related to the either build of ffmpeg or deprecated features.

Build of `ffmpeg-sys` works, but using it as a dependency fails

With the following code

use ffmpeg_sys::*;

fn main() {
    let hi: ffmpeg_sys::__va_list_tag;
    println!("Hello, world!");
}

and the following Cargo.toml

[package]
name = "ffmpeg_sys_test"
version = "0.1.0"
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
ffmpeg-sys="4.3.3"

cargo build fails with the following error

error[E0412]: cannot find type `__va_list_tag` in crate `ffmpeg_sys`
 --> src/main.rs:4:25
  |
4 |     let hi: ffmpeg_sys::__va_list_tag;
  |                         ^^^^^^^^^^^^^ not found in `ffmpeg_sys`

There is no problem with building ffmpeg-sys by itself.

This is on Apple silicon, macOS 12.3.1 with ffmpeg 4.4.2 installed via brew install -s ffmpeg@4 and all the relevant paths added to .bash_profile. I also tried passing the build feature flag to ffmpeg-sys.

Can't find include directory on OSX

= note: Undefined symbols for architecture x86_64:
"_avcodec_free_frame", referenced from:

I've seen this before with other library dependencies, and have learned that the include path to ffmpeg is needed by cc. However I don't know the proper magic to tell this one where to look. Do you happen to know an environment variable or similar that I could set to tell it where to look?

Can't compile with Rust 1.39

With rust 1.39 is not possible to compile this crate anymore, I get the followig errors. Do you have any ideas?

error[E0369]: binary operation `==` cannot be applied to type `__mbstate_t__bindgen_ty_1`
    --> /home/andrea/Workspace/git/video_ludo/target/debug/build/ffmpeg-sys-77d9e656be992a77/out/bindings.rs:3000:5
     |
3000 |     pub __value: __mbstate_t__bindgen_ty_1,
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: an implementation of `std::cmp::PartialEq` might be missing for `__mbstate_t__bindgen_ty_1`

error[E0369]: binary operation `!=` cannot be applied to type `__mbstate_t__bindgen_ty_1`
    --> /home/andrea/Workspace/git/video_ludo/target/debug/build/ffmpeg-sys-77d9e656be992a77/out/bindings.rs:3000:5
     |
3000 |     pub __value: __mbstate_t__bindgen_ty_1,
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     |
     = note: an implementation of `std::cmp::PartialEq` might be missing for `__mbstate_t__bindgen_ty_1`

error[E0277]: the trait bound `__mbstate_t__bindgen_ty_1: std::cmp::Eq` is not satisfied
    --> /home/andrea/Workspace/git/video_ludo/target/debug/build/ffmpeg-sys-77d9e656be992a77/out/bindings.rs:3000:5
     |
3000 |     pub __value: __mbstate_t__bindgen_ty_1,
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::cmp::Eq` is not implemented for `__mbstate_t__bindgen_ty_1`
     |
     = note: required by `std::cmp::AssertParamIsEq`

Compiling failure with unresolved import `libc::EINVAL`

I'm trying to build package with only one dependency:

[dependencies]
ffmpeg = "0.1.1"

and obtain such output:

E:\rnd\rust\test>cargo version
cargo 0.3.0-nightly (2ac8a86 2015-06-10) (built 2015-06-10)

E:\rnd\rust\test>cargo build
    Updating registry `https://github.com/rust-lang/crates.io-index`
 Downloading libc v0.1.8
 Downloading ffmpeg v0.1.1
 Downloading ffmpeg-sys v2.6.2-4
 Downloading bitflags v0.1.1
   Compiling libc v0.1.8
   Compiling bitflags v0.1.1
   Compiling ffmpeg-sys v2.6.2-4
C:\Users\null\.cargo\registry\src\github.com-0a35038f75765ae4\ffmpeg-sys-2.6.2-4
\src\avutil\mem.rs:1:60: 1:66 error: unresolved import `libc::EINVAL`. There is
no `EINVAL` in `libc`
C:\Users\null\.cargo\registry\src\github.com-0a35038f75765ae4\ffmpeg-sys-2.6.2-4
\src\avutil\mem.rs:1 use libc::{c_void, c_char, c_int, c_uint, uint8_t, size_t,
EINVAL};


^~~~~~
error: aborting due to previous error
Could not compile `ffmpeg-sys`.

i've tried stable 1.0 and nightly 1.2 rust versions. my environment is Windows 7 64 bit.

Adding support for android (and others architectures)

Hi, I'll add support for other architectures. Take a look at the structure of the prebuilt binaries I have:

|-- android
|   |-- arm64-v8a
|   |   |-- include
|   |   |-- lib
|   |   `-- share
|   |-- armeabi-v7a
|   |   |-- include
|   |   |-- lib
|   |   `-- share
|   |-- x86
|   |   |-- include
|   |   |-- lib
|   |   `-- share
|   `-- x86_64
|       |-- include
|       |-- lib
|       `-- share
`-- desktop
    |-- aarch64
    |   |-- include
    |   |-- lib
    |   `-- share
    |-- x86_64
    |   |-- bin
    |   |-- include
    |   |-- lib
    |   `-- share
    `-- x86_64_generic
        |-- bin
        |-- include
        |-- lib
        `-- share

they're respecting android's jniLibs search model (even though we won't use it in this project). I have a docker container that builds then in this structure. For desktop this container builds with some hardware decoding support which is nice, I may link it here in the future, gotta clean it.

Anyways, looks like for now, rust-ffmpeg-sys supports specifying a folder that contains lib, bin, include. I'm planning to add an environment variable called MULTI_ARCHITECTURE_PREBUILT which would point to the root of my tree I just pasted here. Then if it's android it goes into android + right arch. I think I might change desktop/{x86_64,aarch64,x86_64_generic} to desktop/{linux/macos/windows}/{x86_64,aarch64,x86_64_generic}. Also there should be an iOS folder. What you think?

I'll have to delay iOS, Windows and macOS support because I dont have them now to build, but I plan to support them.

I also didn't look at how to use cargo to cross compile (for android for now) using build.rs. Gonna look on that. If somebody have a tip I appreciate. I want to build for android on linux, and for linux on linux (which already works)

Compilation error: can't find crate for `ffmpeg`

I have the follwing toml file:

[package]
name = "myserver"
version = "0.1.0"
authors = ["Sascha Häusler [email protected]"]

[dependencies.ffmpeg-sys]
version = "2.8.0"
default-features = false
features = ["static", "avcodec", "avdevice", "avfilter", "avformat", "swscale"]
optional = true

[dependencies.ffmpeg]

version = "~0.2.0"

git = "https://github.com/meh/rust-ffmpeg"
default-features = false
features = ["static", "codec", "device", "filter", "format", "software-scaling"]
optional = true

And the error message looks like this:
src/main.rs:1:1: 1:21 error: can't find crate for ffmpeg
src/main.rs:1 extern crate ffmpeg;

Am I doing something wrong? Or do I need to correct the toml file?

Cross compile from linux to windows

Host OS: Ubuntu
Target OS: Windows 10

command:
$ RUST_BACKTRACE=1 PKG_CONFIG_ALLOW_CROSS=1 cargo build --target x86_64-pc-windows-gnu

Log:

error: failed to run custom build command for `ffmpeg-sys v4.3.3`

Caused by:
  process didn't exit successfully: `/home/wojtess/Documents/rust/qbox/target/debug/build/ffmpeg-sys-7fbc21dc22bdcd9e/build-script-build` (exit status: 101)
  --- stdout
  cargo:rustc-link-search=native=/home/wojtess/Documents/rust/qbox/target/x86_64-pc-windows-gnu/debug/build/ffmpeg-sys-08f8dafae26dcfed/out/dist/lib
  cargo:rustc-link-lib=static=avcodec
  cargo:rustc-link-lib=static=avdevice
  cargo:rustc-link-lib=static=avfilter
  cargo:rustc-link-lib=static=avformat
  cargo:rustc-link-lib=static=avutil
  cargo:rustc-link-lib=static=swresample
  cargo:rustc-link-lib=static=swscale
  OPT_LEVEL = Some("0")
  TARGET = Some("x86_64-pc-windows-gnu")
  HOST = Some("x86_64-unknown-linux-gnu")
  cargo:rerun-if-env-changed=CC_x86_64-pc-windows-gnu
  CC_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CC_x86_64_pc_windows_gnu
  CC_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CC
  TARGET_CC = None
  cargo:rerun-if-env-changed=CC
  CC = None
  RUSTC_LINKER = None
  cargo:rerun-if-env-changed=CROSS_COMPILE
  CROSS_COMPILE = None
  cargo:rerun-if-env-changed=CFLAGS_x86_64-pc-windows-gnu
  CFLAGS_x86_64-pc-windows-gnu = None
  cargo:rerun-if-env-changed=CFLAGS_x86_64_pc_windows_gnu
  CFLAGS_x86_64_pc_windows_gnu = None
  cargo:rerun-if-env-changed=TARGET_CFLAGS
  TARGET_CFLAGS = None
  cargo:rerun-if-env-changed=CFLAGS
  CFLAGS = None
  cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some("true")
  CARGO_CFG_TARGET_FEATURE = Some("fxsr,llvm14-builtins-abi,sse,sse2")
  configure: Unknown OS 'windows'.

  If you think configure made a mistake, make sure you are using the latest
  version from Git.  If the latest version fails, report the problem to the
  [email protected] mailing list or IRC #ffmpeg on irc.libera.chat.
  Include the log file "ffbuild/config.log" produced by configure as this will help
  solve the problem.


  --- stderr
  Using stack size: Ok(3145728)
  Cloning into 'ffmpeg-4.3'...
  thread 'ffmpg-sys-build' panicked at 'called `Result::unwrap()` on an `Err` value: Custom { kind: Other, error: "configure failed " }', /home/wojtess/.cargo/registry/src/github.com-1ecc6299db9ec823/ffmpeg-sys-4.3.3/build.rs:644:21
  stack backtrace:
     0: rust_begin_unwind
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/std/src/panicking.rs:575:5
     1: core::panicking::panic_fmt
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/panicking.rs:65:14
     2: core::result::unwrap_failed
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/result.rs:1791:5
     3: core::result::Result<T,E>::unwrap
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/result.rs:1113:23
     4: build_script_build::thread_main
               at ./build.rs:644:13
     5: core::ops::function::FnOnce::call_once
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/ops/function.rs:251:5
  note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
  thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Any { .. }', /home/wojtess/.cargo/registry/src/github.com-1ecc6299db9ec823/ffmpeg-sys-4.3.3/build.rs:629:10
  stack backtrace:
     0: rust_begin_unwind
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/std/src/panicking.rs:575:5
     1: core::panicking::panic_fmt
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/panicking.rs:65:14
     2: core::result::unwrap_failed
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/result.rs:1791:5
     3: core::result::Result<T,E>::unwrap
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/result.rs:1113:23
     4: build_script_build::main
               at ./build.rs:623:5
     5: core::ops::function::FnOnce::call_once
               at /rustc/b8c35ca26b191bb9a9ac669a4b3f4d3d52d97fb1/library/core/src/ops/function.rs:251:5
  note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.