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

opencv(4.x): disable quirc if dnn is disabled #13215

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions recipes/opencv/4.x/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@ def configure(self):
del self.options.contrib_sfm
if not self.options.dnn:
del self.options.dnn_cuda
del self.options.with_quirc
if not self.options.with_cuda:
del self.options.with_cublas
del self.options.with_cudnn
Expand Down Expand Up @@ -190,7 +191,7 @@ def requirements(self):
if self.options.with_openexr:
self.requires("openexr/2.5.7")
if self.options.get_safe("with_tiff"):
self.requires("libtiff/4.3.0")
self.requires("libtiff/4.4.0")
if self.options.with_eigen:
self.requires("eigen/3.3.9")
if self.options.get_safe("with_ffmpeg"):
Expand All @@ -207,7 +208,7 @@ def requirements(self):
if self.options.get_safe("contrib_sfm"):
self.requires("gflags/2.2.2")
self.requires("glog/0.5.0")
if self.options.with_quirc:
if self.options.get_safe("with_quirc"):
self.requires("quirc/1.1")
if self.options.get_safe("with_gtk"):
self.requires("gtk/system")
Expand Down Expand Up @@ -435,7 +436,7 @@ def _configure_cmake(self):
self._cmake.definitions["WITH_OPENJPEG"] = self.options.with_jpeg2000 == "openjpeg"
self._cmake.definitions["WITH_OPENEXR"] = self.options.with_openexr
self._cmake.definitions["WITH_EIGEN"] = self.options.with_eigen
self._cmake.definitions["HAVE_QUIRC"] = self.options.with_quirc # force usage of quirc requirement
self._cmake.definitions["HAVE_QUIRC"] = self.options.get_safe("with_quirc") # force usage of quirc requirement
self._cmake.definitions["WITH_DSHOW"] = self._is_msvc
self._cmake.definitions["WITH_MSMF"] = self._is_msvc
self._cmake.definitions["WITH_MSMF_DXVA"] = self._is_msvc
Expand Down Expand Up @@ -587,7 +588,7 @@ def parallel():
return ["onetbb::onetbb"] if self.options.parallel == "tbb" else []

def quirc():
return ["quirc::quirc"] if self.options.with_quirc else []
return ["quirc::quirc"] if self.options.get_safe("with_quirc") else []

def gtk():
return ["gtk::gtk"] if self.options.get_safe("with_gtk") else []
Expand Down