Skip to content

Commit 0f24d33

Browse files
committed
ffmpeg: added openvino support
1 parent fc72565 commit 0f24d33

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

recipes/ffmpeg/all/conanfile.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ class FFMpegConan(ConanFile):
4848
"with_freetype": [True, False],
4949
"with_openjpeg": [True, False],
5050
"with_openh264": [True, False],
51+
"with_openvino": [True, False],
5152
"with_opus": [True, False],
5253
"with_vorbis": [True, False],
5354
"with_zeromq": [True, False],
@@ -125,6 +126,7 @@ class FFMpegConan(ConanFile):
125126
"with_freetype": True,
126127
"with_openjpeg": True,
127128
"with_openh264": True,
129+
"with_openvino": True,
128130
"with_opus": True,
129131
"with_vorbis": True,
130132
"with_zeromq": False,
@@ -202,6 +204,7 @@ def _dependencies(self):
202204
"with_libiconv": ["avcodec"],
203205
"with_openjpeg": ["avcodec"],
204206
"with_openh264": ["avcodec"],
207+
"with_openvino": ["avfilter"],
205208
"with_vorbis": ["avcodec"],
206209
"with_opus": ["avcodec"],
207210
"with_libx264": ["avcodec"],
@@ -249,6 +252,8 @@ def config_options(self):
249252
def configure(self):
250253
if self.options.shared:
251254
self.options.rm_safe("fPIC")
255+
if not self.options.avfilter or Version(self.version) < "6.1":
256+
del self.options.with_openvino
252257
self.settings.rm_safe("compiler.cppstd")
253258
self.settings.rm_safe("compiler.libcxx")
254259

@@ -270,6 +275,8 @@ def requirements(self):
270275
self.requires("openjpeg/2.5.0")
271276
if self.options.with_openh264:
272277
self.requires("openh264/2.3.1")
278+
if self.options.get_safe("with_openvino"):
279+
self.requires("openvino/2023.2.0")
273280
if self.options.with_vorbis:
274281
self.requires("vorbis/1.3.7")
275282
if self.options.with_opus:
@@ -450,6 +457,7 @@ def opt_append_disable_if_set(args, what, v):
450457
opt_enable_disable("iconv", self.options.with_libiconv),
451458
opt_enable_disable("libopenjpeg", self.options.with_openjpeg),
452459
opt_enable_disable("libopenh264", self.options.with_openh264),
460+
opt_enable_disable("libopenvino", self.options.get_safe("with_openvino")),
453461
opt_enable_disable("libvorbis", self.options.with_vorbis),
454462
opt_enable_disable("libopus", self.options.with_opus),
455463
opt_enable_disable("libzmq", self.options.with_zeromq),
@@ -970,6 +978,8 @@ def package_info(self):
970978
"CoreImage")
971979
if Version(self.version) >= "5.0" and is_apple_os(self):
972980
self.cpp_info.components["avfilter"].frameworks.append("Metal")
981+
if self.options.get_safe("with_openvino"):
982+
self.cpp_info.components["avfilter"].requires.append("openvino::Runtime_C")
973983

974984
if self.options.get_safe("with_vaapi"):
975985
self.cpp_info.components["avutil"].requires.extend(

0 commit comments

Comments
 (0)