diff --git a/recipes/openexr/3.x/conanfile.py b/recipes/openexr/3.x/conanfile.py index 83b40c8cc3b06..e96841da78ea1 100644 --- a/recipes/openexr/3.x/conanfile.py +++ b/recipes/openexr/3.x/conanfile.py @@ -1,11 +1,11 @@ from conan import ConanFile from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import apply_conandata_patches, copy, get, rmdir +from conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, rmdir from conan.tools.scm import Version import os -required_conan_version = ">=1.50.2 <1.51.0 || >=1.51.2" +required_conan_version = ">=1.53.0" class OpenEXRConan(ConanFile): @@ -28,8 +28,7 @@ class OpenEXRConan(ConanFile): } def export_sources(self): - for p in self.conan_data.get("patches", {}).get(self.version, []): - copy(self, p["patch_file"], self.recipe_folder, self.export_sources_folder) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -41,20 +40,18 @@ def configure(self): def requirements(self): self.requires("zlib/1.2.13") - # Note: OpenEXR and Imath are versioned independently. - self.requires("imath/3.1.5", transitive_headers=True) + self.requires("imath/3.1.6", transitive_headers=True) def validate(self): - if self.info.settings.compiler.cppstd: + if self.settings.compiler.cppstd: check_min_cppstd(self, 11) def layout(self): cmake_layout(self, src_folder="src") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self)