#9881 closed enhancement (wontfix)
[feature] Support CMake build system.
| Reported by: | Haowei Hsu | Owned by: | |
|---|---|---|---|
| Priority: | normal | Component: | build system |
| Version: | git-master | Keywords: | cmake |
| Cc: | Haowei Hsu | Blocked By: | |
| Blocking: | Reproduced by developer: | no | |
| Analyzed by developer: | no |
Description
Since CMake is the most popular build system of C/C++, I would expect that FFmpeg can support using CMake to compile the source code. Moreover, I hope that CMake can provide Config files for find_package() and Imported Targets.
Normally, there would be the following files generated for find_package() in Config Mode:
ffmpeg-config.cmakeffmpeg-config-version.cmakeffmpeg-targets.cmakeffmpeg-targets-[debug|release].cmake
As for Imported Targets, consider FFmpeg has several components, I suggest that it take Qt or Poco for reference, providing the following Component Imported Targets with the namespace ffmpeg:::
ffmpeg::avcodecffmpeg::avformatffmpeg::avfilterffmpeg::avdeviceffmpeg::avutilffmpeg::swscaleffmpeg::swresampleffmpeg::postproc
Change History (8)
follow-up: 2 comment:1 by , 4 years ago
| Resolution: | → wontfix |
|---|---|
| Status: | new → closed |
comment:2 by , 4 years ago
comment:3 by , 4 years ago
| Summary: | Support CMake build system. → [feature] Support CMake build system. |
|---|
follow-up: 5 comment:4 by , 4 years ago
Cmake is extra dependency. Why does linux kernel not do it? Same here.
It does not matter anyway, ffmpeg really requires a big framework to comfortably check everything out and compile all together.
comment:5 by , 4 years ago
Replying to Balling:
Cmake is extra dependency. Why does linux kernel not do it? Same here.
It does not matter anyway, ffmpeg really requires a big framework to comfortably check everything out and compile all together.
What does it matter with "linux kernel"? What do you mean "big framework"?
I was thinking that since lots of C/C++ libraries use CMake as their build system, it is better for FFmpeg to do so, as well. Besides, using CMake to build projects is more convienient and easy-to-use in Windows.
comment:6 by , 4 years ago
Sorry, bunch of FFmpeg devs are not switching to cmake anytime soon.
Besides there are more important task to be done first.
comment:7 by , 4 years ago
linux kernel (mainline, that is, no one uses it, everyone uses backports repo) https://github.com/torvalds/linux
big framework: https://github.com/rdp/ffmpeg-windows-build-helpers and many others.
comment:8 by , 10 months ago
If it's more about not willing to put in the effort of porting over, I'm more than willing to do so.



Replying to Elon Musk:
Why not support using CMake to build the FFmpeg project? Does it have some obstacles?
It seems that CMake is more convenient to compile the Cross-Platform projects.
If there are some obstacles indeed, then I suggest to provide some CMake-specific Config Files for find_package() at least.