Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support linking with a subset of FFmpeg using feature flags #128

Open
JohnstonJ opened this issue Sep 29, 2024 · 0 comments
Open

Support linking with a subset of FFmpeg using feature flags #128

JohnstonJ opened this issue Sep 29, 2024 · 0 comments
Assignees

Comments

@JohnstonJ
Copy link

My application has no use for some FFmpeg libraries. For example, I don't need to use avdevice because I'm not working with any actual devices - I'm just transcoding media files. So I built FFmpeg without that library. (I am using vcpkg and they offer a feature for each FFmpeg library that you want to build, so I excluded avdevice.)

rust-ffmpeg-sys is a similar type of package offering FFmpeg bindings, and it offers the ability to opt in & out of each library using features: https://github.com/zmwangx/rust-ffmpeg-sys/blob/a13516c4f2183330468f3f5867262a78674f61e0/Cargo.toml#L103-L111

By excluding some features, it reduces the build time for building FFmpeg. And less things for the compiler/linker to deal with: a whole bunch of bindings don't even need to be generated, etc.

My current preference is rsmpeg over ffmpeg_next, but it would be nice if I could build only the subset of FFmpeg that I need.

@ldm0 ldm0 self-assigned this Sep 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants