We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[package] sail/0.9.0-rc2: PR broke the package
### Description

I've just noticed that the V2 version of sail suddenly disappeared from the center. This was caused by https://github.com/conan-io/conan-center-index/pull/18454

Please please please don't merge pull requests that break packages! Could you please also revert the PR? I have no access to the computer right now.

### Package and Environment Details

All envs

### Conan profile

All profiles

### Steps to reproduce

No steps

### Logs

No logs

--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `recipes/sail/all/conanfile.py`
Content:
```
1 from conan import ConanFile
2 from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout
3 from conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, rename, rmdir
4 from conan.tools.microsoft import is_msvc
5 import os
6 
7 required_conan_version = ">=1.53.0"
8 
9 class SAILConan(ConanFile):
10     name = "sail"
11     description = "The missing small and fast image decoding library for humans (not for machines)"
12     url = "https://github.com/conan-io/conan-center-index"
13     homepage = "https://sail.software"
14     topics = ( "image", "encoding", "decoding", "graphics" )
15     license = "MIT"
16     settings = "os", "arch", "compiler", "build_type"
17     options = {
18         "shared": [True, False],
19         "fPIC": [True, False],
20         "thread_safe": [True, False],
21         "with_avif": [True, False],
22         "with_gif": [True, False],
23         "with_jpeg2000": [True, False],
24         "with_jpeg": ["libjpeg", "libjpeg-turbo", False],
25         "with_png": [True, False],
26         "with_tiff": [True, False],
27         "with_webp": [True, False],
28     }
29     default_options = {
30         "shared": False,
31         "fPIC": True,
32         "thread_safe": True,
33         "with_avif": True,
34         "with_gif": True,
35         "with_jpeg2000": True,
36         "with_jpeg": "libjpeg",
37         "with_png": True,
38         "with_tiff": True,
39         "with_webp": True,
40     }
41 
42     def export_sources(self):
43         export_conandata_patches(self)
44 
45     def config_options(self):
46         if self.settings.os == "Windows":
47             self.options.rm_safe("fPIC")
48 
49     def configure(self):
50         if self.options.shared:
51             self.options.rm_safe("fPIC")
52 
53     def requirements(self):
54         if self.options.with_avif:
55             self.requires("libavif/0.11.1")
56         if self.options.with_gif:
57             self.requires("giflib/5.2.1")
58         if self.options.with_jpeg2000:
59             self.requires("jasper/4.0.0")
60         if self.options.with_jpeg == "libjpeg-turbo":
61             self.requires("libjpeg-turbo/2.1.5")
62         elif self.options.with_jpeg == "libjpeg":
63             self.requires("libjpeg/9e")
64         if self.options.with_png:
65             self.requires("libpng/1.6.40")
66         if self.options.with_tiff:
67             self.requires("libtiff/4.5.1")
68         if self.options.with_webp:
69             self.requires("libwebp/1.3.1")
70 
71     def layout(self):
72         cmake_layout(self, src_folder="src")
73 
74     def source(self):
75         get(self, **self.conan_data["sources"][self.version],
76             strip_root=True, destination=self.source_folder)
77 
78     def generate(self):
79         enable_codecs = []
80 
81         if self.options.with_avif:
82             enable_codecs.append("avif")
83         if self.options.with_gif:
84             enable_codecs.append("gif")
85         if self.options.with_jpeg2000:
86             enable_codecs.append("jpeg2000")
87         if self.options.with_jpeg:
88             enable_codecs.append("jpeg")
89         if self.options.with_png:
90             enable_codecs.append("png")
91         if self.options.with_tiff:
92             enable_codecs.append("tiff")
93         if self.options.with_webp:
94             enable_codecs.append("webp")
95 
96         tc = CMakeToolchain(self)
97         tc.variables["SAIL_BUILD_APPS"] = False
98         tc.variables["SAIL_BUILD_EXAMPLES"] = False
99         tc.variables["SAIL_BUILD_TESTS"] = False
100         tc.variables["SAIL_COMBINE_CODECS"] = True
101         tc.variables["SAIL_ENABLE_CODECS"] = ";".join(enable_codecs)
102         tc.variables["SAIL_INSTALL_PDB"] = False
103         tc.variables["SAIL_THREAD_SAFE"] = self.options.thread_safe
104         # TODO: Remove after fixing https://github.com/conan-io/conan/issues/12012
105         if is_msvc(self):
106             tc.cache_variables["CMAKE_TRY_COMPILE_CONFIGURATION"] = str(self.settings.build_type)
107         # TODO: Remove after fixing https://github.com/conan-io/conan-center-index/issues/13159
108         # C3I workaround to force CMake to choose the highest version of
109         # the windows SDK available in the system
110         if is_msvc(self) and not self.conf.get("tools.cmake.cmaketoolchain:system_version"):
111             tc.variables["CMAKE_SYSTEM_VERSION"] = "10.0"
112         tc.generate()
113 
114         deps = CMakeDeps(self)
115         deps.generate()
116 
117     def build(self):
118         apply_conandata_patches(self)
119 
120         cmake = CMake(self)
121         cmake.configure()
122         cmake.build()
123 
124     def package(self):
125         copy(self, "LICENSE.txt",       self.source_folder, os.path.join(self.package_folder, "licenses"))
126         copy(self, "LICENSE.INIH.txt",  self.source_folder, os.path.join(self.package_folder, "licenses"))
127         copy(self, "LICENSE.MUNIT.txt", self.source_folder, os.path.join(self.package_folder, "licenses"))
128 
129         cmake = CMake(self)
130         cmake.install()
131 
132         # Remove CMake and pkg-config rules
133         rmdir(self, os.path.join(self.package_folder, "lib", "cmake"))
134         rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig"))
135         # Move icons
136         rename(self, os.path.join(self.package_folder, "share"),
137                      os.path.join(self.package_folder, "res"))
138 
139     def package_info(self):
140         self.cpp_info.set_property("cmake_file_name", "Sail")
141 
142         self.cpp_info.filenames["cmake_find_package"]       = "Sail"
143         self.cpp_info.filenames["cmake_find_package_multi"] = "Sail"
144         self.cpp_info.names["cmake_find_package"]           = "SAIL"
145         self.cpp_info.names["cmake_find_package_multi"]     = "SAIL"
146 
147         self.cpp_info.components["sail-common"].set_property("cmake_target_name", "SAIL::SailCommon")
148         self.cpp_info.components["sail-common"].set_property("pkg_config_name", "libsail-common")
149         self.cpp_info.components["sail-common"].names["cmake_find_package"]       = "SailCommon"
150         self.cpp_info.components["sail-common"].names["cmake_find_package_multi"] = "SailCommon"
151         self.cpp_info.components["sail-common"].includedirs = ["include/sail"]
152         self.cpp_info.components["sail-common"].libs = ["sail-common"]
153 
154         self.cpp_info.components["sail-codecs"].set_property("cmake_target_name", "SAIL::SailCodecs")
155         self.cpp_info.components["sail-codecs"].names["cmake_find_package"]       = "SailCodecs"
156         self.cpp_info.components["sail-codecs"].names["cmake_find_package_multi"] = "SailCodecs"
157         self.cpp_info.components["sail-codecs"].libs = ["sail-codecs"]
158         self.cpp_info.components["sail-codecs"].requires = ["sail-common"]
159         if self.options.with_avif:
160             self.cpp_info.components["sail-codecs"].requires.append("libavif::libavif")
161         if self.options.with_gif:
162             self.cpp_info.components["sail-codecs"].requires.append("giflib::giflib")
163         if self.options.with_jpeg2000:
164             self.cpp_info.components["sail-codecs"].requires.append("jasper::jasper")
165         if self.options.with_jpeg:
166             self.cpp_info.components["sail-codecs"].requires.append("{0}::{0}".format(self.options.with_jpeg))
167         if self.options.with_png:
168             self.cpp_info.components["sail-codecs"].requires.append("libpng::libpng")
169         if self.options.with_tiff:
170             self.cpp_info.components["sail-codecs"].requires.append("libtiff::libtiff")
171         if self.options.with_webp:
172             self.cpp_info.components["sail-codecs"].requires.append("libwebp::libwebp")
173 
174         self.cpp_info.components["libsail"].set_property("cmake_target_name", "SAIL::Sail")
175         self.cpp_info.components["libsail"].set_property("pkg_config_name", "libsail")
176         self.cpp_info.components["libsail"].names["cmake_find_package"] = "Sail"
177         self.cpp_info.components["libsail"].names["cmake_find_package_multi"] = "Sail"
178         self.cpp_info.components["libsail"].libs = ["sail"]
179         if self.settings.os in ["Linux", "FreeBSD"]:
180             self.cpp_info.components["libsail"].system_libs.append("dl")
181             if self.options.thread_safe:
182                 self.cpp_info.components["libsail"].system_libs.append("pthread")
183         self.cpp_info.components["libsail"].requires = ["sail-common", "sail-codecs"]
184 
185         self.cpp_info.components["sail-manip"].set_property("cmake_target_name", "SAIL::SailManip")
186         self.cpp_info.components["sail-manip"].set_property("pkg_config_name", "libsail-manip")
187         self.cpp_info.components["sail-manip"].names["cmake_find_package"]       = "SailManip"
188         self.cpp_info.components["sail-manip"].names["cmake_find_package_multi"] = "SailManip"
189         self.cpp_info.components["sail-manip"].libs = ["sail-manip"]
190         self.cpp_info.components["sail-manip"].requires = ["sail-common"]
191 
192         self.cpp_info.components["sail-c++"].set_property("cmake_target_name", "SAIL::SailC++")
193         self.cpp_info.components["sail-c++"].set_property("pkg_config_name", "libsail-c++")
194         self.cpp_info.components["sail-c++"].names["cmake_find_package"]       = "SailC++"
195         self.cpp_info.components["sail-c++"].names["cmake_find_package_multi"] = "SailC++"
196         self.cpp_info.components["sail-c++"].libs = ["sail-c++"]
197         self.cpp_info.components["sail-c++"].requires = ["libsail", "sail-manip"]
198
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/recipes/sail/all/conanfile.py b/recipes/sail/all/conanfile.py
--- a/recipes/sail/all/conanfile.py
+++ b/recipes/sail/all/conanfile.py
@@ -104,11 +104,6 @@
         # TODO: Remove after fixing https://github.com/conan-io/conan/issues/12012
         if is_msvc(self):
             tc.cache_variables["CMAKE_TRY_COMPILE_CONFIGURATION"] = str(self.settings.build_type)
-        # TODO: Remove after fixing https://github.com/conan-io/conan-center-index/issues/13159
-        # C3I workaround to force CMake to choose the highest version of
-        # the windows SDK available in the system
-        if is_msvc(self) and not self.conf.get("tools.cmake.cmaketoolchain:system_version"):
-            tc.variables["CMAKE_SYSTEM_VERSION"] = "10.0"
         tc.generate()
 
         deps = CMakeDeps(self)

{"golden_diff": "diff --git a/recipes/sail/all/conanfile.py b/recipes/sail/all/conanfile.py\n--- a/recipes/sail/all/conanfile.py\n+++ b/recipes/sail/all/conanfile.py\n@@ -104,11 +104,6 @@\n         # TODO: Remove after fixing https://github.com/conan-io/conan/issues/12012\n         if is_msvc(self):\n             tc.cache_variables[\"CMAKE_TRY_COMPILE_CONFIGURATION\"] = str(self.settings.build_type)\n-        # TODO: Remove after fixing https://github.com/conan-io/conan-center-index/issues/13159\n-        # C3I workaround to force CMake to choose the highest version of\n-        # the windows SDK available in the system\n-        if is_msvc(self) and not self.conf.get(\"tools.cmake.cmaketoolchain:system_version\"):\n-            tc.variables[\"CMAKE_SYSTEM_VERSION\"] = \"10.0\"\n         tc.generate()\n \n         deps = CMakeDeps(self)\n", "issue": "[package] sail/0.9.0-rc2: PR broke the package\n### Description\n\nI've just noticed that the V2 version of sail suddenly disappeared from the center. This was caused by https://github.com/conan-io/conan-center-index/pull/18454\r\n\r\nPlease please please don't merge pull requests that break packages! Could you please also revert the PR? I have no access to the computer right now.\n\n### Package and Environment Details\n\nAll envs\n\n### Conan profile\n\nAll profiles\n\n### Steps to reproduce\n\nNo steps\n\n### Logs\n\nNo logs\n", "before_files": [{"content": "from conan import ConanFile\nfrom conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout\nfrom conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, rename, rmdir\nfrom conan.tools.microsoft import is_msvc\nimport os\n\nrequired_conan_version = \">=1.53.0\"\n\nclass SAILConan(ConanFile):\n    name = \"sail\"\n    description = \"The missing small and fast image decoding library for humans (not for machines)\"\n    url = \"https://github.com/conan-io/conan-center-index\"\n    homepage = \"https://sail.software\"\n    topics = ( \"image\", \"encoding\", \"decoding\", \"graphics\" )\n    license = \"MIT\"\n    settings = \"os\", \"arch\", \"compiler\", \"build_type\"\n    options = {\n        \"shared\": [True, False],\n        \"fPIC\": [True, False],\n        \"thread_safe\": [True, False],\n        \"with_avif\": [True, False],\n        \"with_gif\": [True, False],\n        \"with_jpeg2000\": [True, False],\n        \"with_jpeg\": [\"libjpeg\", \"libjpeg-turbo\", False],\n        \"with_png\": [True, False],\n        \"with_tiff\": [True, False],\n        \"with_webp\": [True, False],\n    }\n    default_options = {\n        \"shared\": False,\n        \"fPIC\": True,\n        \"thread_safe\": True,\n        \"with_avif\": True,\n        \"with_gif\": True,\n        \"with_jpeg2000\": True,\n        \"with_jpeg\": \"libjpeg\",\n        \"with_png\": True,\n        \"with_tiff\": True,\n        \"with_webp\": True,\n    }\n\n    def export_sources(self):\n        export_conandata_patches(self)\n\n    def config_options(self):\n        if self.settings.os == \"Windows\":\n            self.options.rm_safe(\"fPIC\")\n\n    def configure(self):\n        if self.options.shared:\n            self.options.rm_safe(\"fPIC\")\n\n    def requirements(self):\n        if self.options.with_avif:\n            self.requires(\"libavif/0.11.1\")\n        if self.options.with_gif:\n            self.requires(\"giflib/5.2.1\")\n        if self.options.with_jpeg2000:\n            self.requires(\"jasper/4.0.0\")\n        if self.options.with_jpeg == \"libjpeg-turbo\":\n            self.requires(\"libjpeg-turbo/2.1.5\")\n        elif self.options.with_jpeg == \"libjpeg\":\n            self.requires(\"libjpeg/9e\")\n        if self.options.with_png:\n            self.requires(\"libpng/1.6.40\")\n        if self.options.with_tiff:\n            self.requires(\"libtiff/4.5.1\")\n        if self.options.with_webp:\n            self.requires(\"libwebp/1.3.1\")\n\n    def layout(self):\n        cmake_layout(self, src_folder=\"src\")\n\n    def source(self):\n        get(self, **self.conan_data[\"sources\"][self.version],\n            strip_root=True, destination=self.source_folder)\n\n    def generate(self):\n        enable_codecs = []\n\n        if self.options.with_avif:\n            enable_codecs.append(\"avif\")\n        if self.options.with_gif:\n            enable_codecs.append(\"gif\")\n        if self.options.with_jpeg2000:\n            enable_codecs.append(\"jpeg2000\")\n        if self.options.with_jpeg:\n            enable_codecs.append(\"jpeg\")\n        if self.options.with_png:\n            enable_codecs.append(\"png\")\n        if self.options.with_tiff:\n            enable_codecs.append(\"tiff\")\n        if self.options.with_webp:\n            enable_codecs.append(\"webp\")\n\n        tc = CMakeToolchain(self)\n        tc.variables[\"SAIL_BUILD_APPS\"] = False\n        tc.variables[\"SAIL_BUILD_EXAMPLES\"] = False\n        tc.variables[\"SAIL_BUILD_TESTS\"] = False\n        tc.variables[\"SAIL_COMBINE_CODECS\"] = True\n        tc.variables[\"SAIL_ENABLE_CODECS\"] = \";\".join(enable_codecs)\n        tc.variables[\"SAIL_INSTALL_PDB\"] = False\n        tc.variables[\"SAIL_THREAD_SAFE\"] = self.options.thread_safe\n        # TODO: Remove after fixing https://github.com/conan-io/conan/issues/12012\n        if is_msvc(self):\n            tc.cache_variables[\"CMAKE_TRY_COMPILE_CONFIGURATION\"] = str(self.settings.build_type)\n        # TODO: Remove after fixing https://github.com/conan-io/conan-center-index/issues/13159\n        # C3I workaround to force CMake to choose the highest version of\n        # the windows SDK available in the system\n        if is_msvc(self) and not self.conf.get(\"tools.cmake.cmaketoolchain:system_version\"):\n            tc.variables[\"CMAKE_SYSTEM_VERSION\"] = \"10.0\"\n        tc.generate()\n\n        deps = CMakeDeps(self)\n        deps.generate()\n\n    def build(self):\n        apply_conandata_patches(self)\n\n        cmake = CMake(self)\n        cmake.configure()\n        cmake.build()\n\n    def package(self):\n        copy(self, \"LICENSE.txt\",       self.source_folder, os.path.join(self.package_folder, \"licenses\"))\n        copy(self, \"LICENSE.INIH.txt\",  self.source_folder, os.path.join(self.package_folder, \"licenses\"))\n        copy(self, \"LICENSE.MUNIT.txt\", self.source_folder, os.path.join(self.package_folder, \"licenses\"))\n\n        cmake = CMake(self)\n        cmake.install()\n\n        # Remove CMake and pkg-config rules\n        rmdir(self, os.path.join(self.package_folder, \"lib\", \"cmake\"))\n        rmdir(self, os.path.join(self.package_folder, \"lib\", \"pkgconfig\"))\n        # Move icons\n        rename(self, os.path.join(self.package_folder, \"share\"),\n                     os.path.join(self.package_folder, \"res\"))\n\n    def package_info(self):\n        self.cpp_info.set_property(\"cmake_file_name\", \"Sail\")\n\n        self.cpp_info.filenames[\"cmake_find_package\"]       = \"Sail\"\n        self.cpp_info.filenames[\"cmake_find_package_multi\"] = \"Sail\"\n        self.cpp_info.names[\"cmake_find_package\"]           = \"SAIL\"\n        self.cpp_info.names[\"cmake_find_package_multi\"]     = \"SAIL\"\n\n        self.cpp_info.components[\"sail-common\"].set_property(\"cmake_target_name\", \"SAIL::SailCommon\")\n        self.cpp_info.components[\"sail-common\"].set_property(\"pkg_config_name\", \"libsail-common\")\n        self.cpp_info.components[\"sail-common\"].names[\"cmake_find_package\"]       = \"SailCommon\"\n        self.cpp_info.components[\"sail-common\"].names[\"cmake_find_package_multi\"] = \"SailCommon\"\n        self.cpp_info.components[\"sail-common\"].includedirs = [\"include/sail\"]\n        self.cpp_info.components[\"sail-common\"].libs = [\"sail-common\"]\n\n        self.cpp_info.components[\"sail-codecs\"].set_property(\"cmake_target_name\", \"SAIL::SailCodecs\")\n        self.cpp_info.components[\"sail-codecs\"].names[\"cmake_find_package\"]       = \"SailCodecs\"\n        self.cpp_info.components[\"sail-codecs\"].names[\"cmake_find_package_multi\"] = \"SailCodecs\"\n        self.cpp_info.components[\"sail-codecs\"].libs = [\"sail-codecs\"]\n        self.cpp_info.components[\"sail-codecs\"].requires = [\"sail-common\"]\n        if self.options.with_avif:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libavif::libavif\")\n        if self.options.with_gif:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"giflib::giflib\")\n        if self.options.with_jpeg2000:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"jasper::jasper\")\n        if self.options.with_jpeg:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"{0}::{0}\".format(self.options.with_jpeg))\n        if self.options.with_png:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libpng::libpng\")\n        if self.options.with_tiff:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libtiff::libtiff\")\n        if self.options.with_webp:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libwebp::libwebp\")\n\n        self.cpp_info.components[\"libsail\"].set_property(\"cmake_target_name\", \"SAIL::Sail\")\n        self.cpp_info.components[\"libsail\"].set_property(\"pkg_config_name\", \"libsail\")\n        self.cpp_info.components[\"libsail\"].names[\"cmake_find_package\"] = \"Sail\"\n        self.cpp_info.components[\"libsail\"].names[\"cmake_find_package_multi\"] = \"Sail\"\n        self.cpp_info.components[\"libsail\"].libs = [\"sail\"]\n        if self.settings.os in [\"Linux\", \"FreeBSD\"]:\n            self.cpp_info.components[\"libsail\"].system_libs.append(\"dl\")\n            if self.options.thread_safe:\n                self.cpp_info.components[\"libsail\"].system_libs.append(\"pthread\")\n        self.cpp_info.components[\"libsail\"].requires = [\"sail-common\", \"sail-codecs\"]\n\n        self.cpp_info.components[\"sail-manip\"].set_property(\"cmake_target_name\", \"SAIL::SailManip\")\n        self.cpp_info.components[\"sail-manip\"].set_property(\"pkg_config_name\", \"libsail-manip\")\n        self.cpp_info.components[\"sail-manip\"].names[\"cmake_find_package\"]       = \"SailManip\"\n        self.cpp_info.components[\"sail-manip\"].names[\"cmake_find_package_multi\"] = \"SailManip\"\n        self.cpp_info.components[\"sail-manip\"].libs = [\"sail-manip\"]\n        self.cpp_info.components[\"sail-manip\"].requires = [\"sail-common\"]\n\n        self.cpp_info.components[\"sail-c++\"].set_property(\"cmake_target_name\", \"SAIL::SailC++\")\n        self.cpp_info.components[\"sail-c++\"].set_property(\"pkg_config_name\", \"libsail-c++\")\n        self.cpp_info.components[\"sail-c++\"].names[\"cmake_find_package\"]       = \"SailC++\"\n        self.cpp_info.components[\"sail-c++\"].names[\"cmake_find_package_multi\"] = \"SailC++\"\n        self.cpp_info.components[\"sail-c++\"].libs = [\"sail-c++\"]\n        self.cpp_info.components[\"sail-c++\"].requires = [\"libsail\", \"sail-manip\"]\n", "path": "recipes/sail/all/conanfile.py"}], "after_files": [{"content": "from conan import ConanFile\nfrom conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout\nfrom conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, rename, rmdir\nfrom conan.tools.microsoft import is_msvc\nimport os\n\nrequired_conan_version = \">=1.53.0\"\n\nclass SAILConan(ConanFile):\n    name = \"sail\"\n    description = \"The missing small and fast image decoding library for humans (not for machines)\"\n    url = \"https://github.com/conan-io/conan-center-index\"\n    homepage = \"https://sail.software\"\n    topics = ( \"image\", \"encoding\", \"decoding\", \"graphics\" )\n    license = \"MIT\"\n    settings = \"os\", \"arch\", \"compiler\", \"build_type\"\n    options = {\n        \"shared\": [True, False],\n        \"fPIC\": [True, False],\n        \"thread_safe\": [True, False],\n        \"with_avif\": [True, False],\n        \"with_gif\": [True, False],\n        \"with_jpeg2000\": [True, False],\n        \"with_jpeg\": [\"libjpeg\", \"libjpeg-turbo\", False],\n        \"with_png\": [True, False],\n        \"with_tiff\": [True, False],\n        \"with_webp\": [True, False],\n    }\n    default_options = {\n        \"shared\": False,\n        \"fPIC\": True,\n        \"thread_safe\": True,\n        \"with_avif\": True,\n        \"with_gif\": True,\n        \"with_jpeg2000\": True,\n        \"with_jpeg\": \"libjpeg\",\n        \"with_png\": True,\n        \"with_tiff\": True,\n        \"with_webp\": True,\n    }\n\n    def export_sources(self):\n        export_conandata_patches(self)\n\n    def config_options(self):\n        if self.settings.os == \"Windows\":\n            self.options.rm_safe(\"fPIC\")\n\n    def configure(self):\n        if self.options.shared:\n            self.options.rm_safe(\"fPIC\")\n\n    def requirements(self):\n        if self.options.with_avif:\n            self.requires(\"libavif/0.11.1\")\n        if self.options.with_gif:\n            self.requires(\"giflib/5.2.1\")\n        if self.options.with_jpeg2000:\n            self.requires(\"jasper/4.0.0\")\n        if self.options.with_jpeg == \"libjpeg-turbo\":\n            self.requires(\"libjpeg-turbo/2.1.5\")\n        elif self.options.with_jpeg == \"libjpeg\":\n            self.requires(\"libjpeg/9e\")\n        if self.options.with_png:\n            self.requires(\"libpng/1.6.40\")\n        if self.options.with_tiff:\n            self.requires(\"libtiff/4.5.1\")\n        if self.options.with_webp:\n            self.requires(\"libwebp/1.3.1\")\n\n    def layout(self):\n        cmake_layout(self, src_folder=\"src\")\n\n    def source(self):\n        get(self, **self.conan_data[\"sources\"][self.version],\n            strip_root=True, destination=self.source_folder)\n\n    def generate(self):\n        enable_codecs = []\n\n        if self.options.with_avif:\n            enable_codecs.append(\"avif\")\n        if self.options.with_gif:\n            enable_codecs.append(\"gif\")\n        if self.options.with_jpeg2000:\n            enable_codecs.append(\"jpeg2000\")\n        if self.options.with_jpeg:\n            enable_codecs.append(\"jpeg\")\n        if self.options.with_png:\n            enable_codecs.append(\"png\")\n        if self.options.with_tiff:\n            enable_codecs.append(\"tiff\")\n        if self.options.with_webp:\n            enable_codecs.append(\"webp\")\n\n        tc = CMakeToolchain(self)\n        tc.variables[\"SAIL_BUILD_APPS\"] = False\n        tc.variables[\"SAIL_BUILD_EXAMPLES\"] = False\n        tc.variables[\"SAIL_BUILD_TESTS\"] = False\n        tc.variables[\"SAIL_COMBINE_CODECS\"] = True\n        tc.variables[\"SAIL_ENABLE_CODECS\"] = \";\".join(enable_codecs)\n        tc.variables[\"SAIL_INSTALL_PDB\"] = False\n        tc.variables[\"SAIL_THREAD_SAFE\"] = self.options.thread_safe\n        # TODO: Remove after fixing https://github.com/conan-io/conan/issues/12012\n        if is_msvc(self):\n            tc.cache_variables[\"CMAKE_TRY_COMPILE_CONFIGURATION\"] = str(self.settings.build_type)\n        tc.generate()\n\n        deps = CMakeDeps(self)\n        deps.generate()\n\n    def build(self):\n        apply_conandata_patches(self)\n\n        cmake = CMake(self)\n        cmake.configure()\n        cmake.build()\n\n    def package(self):\n        copy(self, \"LICENSE.txt\",       self.source_folder, os.path.join(self.package_folder, \"licenses\"))\n        copy(self, \"LICENSE.INIH.txt\",  self.source_folder, os.path.join(self.package_folder, \"licenses\"))\n        copy(self, \"LICENSE.MUNIT.txt\", self.source_folder, os.path.join(self.package_folder, \"licenses\"))\n\n        cmake = CMake(self)\n        cmake.install()\n\n        # Remove CMake and pkg-config rules\n        rmdir(self, os.path.join(self.package_folder, \"lib\", \"cmake\"))\n        rmdir(self, os.path.join(self.package_folder, \"lib\", \"pkgconfig\"))\n        # Move icons\n        rename(self, os.path.join(self.package_folder, \"share\"),\n                     os.path.join(self.package_folder, \"res\"))\n\n    def package_info(self):\n        self.cpp_info.set_property(\"cmake_file_name\", \"Sail\")\n\n        self.cpp_info.filenames[\"cmake_find_package\"]       = \"Sail\"\n        self.cpp_info.filenames[\"cmake_find_package_multi\"] = \"Sail\"\n        self.cpp_info.names[\"cmake_find_package\"]           = \"SAIL\"\n        self.cpp_info.names[\"cmake_find_package_multi\"]     = \"SAIL\"\n\n        self.cpp_info.components[\"sail-common\"].set_property(\"cmake_target_name\", \"SAIL::SailCommon\")\n        self.cpp_info.components[\"sail-common\"].set_property(\"pkg_config_name\", \"libsail-common\")\n        self.cpp_info.components[\"sail-common\"].names[\"cmake_find_package\"]       = \"SailCommon\"\n        self.cpp_info.components[\"sail-common\"].names[\"cmake_find_package_multi\"] = \"SailCommon\"\n        self.cpp_info.components[\"sail-common\"].includedirs = [\"include/sail\"]\n        self.cpp_info.components[\"sail-common\"].libs = [\"sail-common\"]\n\n        self.cpp_info.components[\"sail-codecs\"].set_property(\"cmake_target_name\", \"SAIL::SailCodecs\")\n        self.cpp_info.components[\"sail-codecs\"].names[\"cmake_find_package\"]       = \"SailCodecs\"\n        self.cpp_info.components[\"sail-codecs\"].names[\"cmake_find_package_multi\"] = \"SailCodecs\"\n        self.cpp_info.components[\"sail-codecs\"].libs = [\"sail-codecs\"]\n        self.cpp_info.components[\"sail-codecs\"].requires = [\"sail-common\"]\n        if self.options.with_avif:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libavif::libavif\")\n        if self.options.with_gif:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"giflib::giflib\")\n        if self.options.with_jpeg2000:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"jasper::jasper\")\n        if self.options.with_jpeg:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"{0}::{0}\".format(self.options.with_jpeg))\n        if self.options.with_png:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libpng::libpng\")\n        if self.options.with_tiff:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libtiff::libtiff\")\n        if self.options.with_webp:\n            self.cpp_info.components[\"sail-codecs\"].requires.append(\"libwebp::libwebp\")\n\n        self.cpp_info.components[\"libsail\"].set_property(\"cmake_target_name\", \"SAIL::Sail\")\n        self.cpp_info.components[\"libsail\"].set_property(\"pkg_config_name\", \"libsail\")\n        self.cpp_info.components[\"libsail\"].names[\"cmake_find_package\"] = \"Sail\"\n        self.cpp_info.components[\"libsail\"].names[\"cmake_find_package_multi\"] = \"Sail\"\n        self.cpp_info.components[\"libsail\"].libs = [\"sail\"]\n        if self.settings.os in [\"Linux\", \"FreeBSD\"]:\n            self.cpp_info.components[\"libsail\"].system_libs.append(\"dl\")\n            if self.options.thread_safe:\n                self.cpp_info.components[\"libsail\"].system_libs.append(\"pthread\")\n        self.cpp_info.components[\"libsail\"].requires = [\"sail-common\", \"sail-codecs\"]\n\n        self.cpp_info.components[\"sail-manip\"].set_property(\"cmake_target_name\", \"SAIL::SailManip\")\n        self.cpp_info.components[\"sail-manip\"].set_property(\"pkg_config_name\", \"libsail-manip\")\n        self.cpp_info.components[\"sail-manip\"].names[\"cmake_find_package\"]       = \"SailManip\"\n        self.cpp_info.components[\"sail-manip\"].names[\"cmake_find_package_multi\"] = \"SailManip\"\n        self.cpp_info.components[\"sail-manip\"].libs = [\"sail-manip\"]\n        self.cpp_info.components[\"sail-manip\"].requires = [\"sail-common\"]\n\n        self.cpp_info.components[\"sail-c++\"].set_property(\"cmake_target_name\", \"SAIL::SailC++\")\n        self.cpp_info.components[\"sail-c++\"].set_property(\"pkg_config_name\", \"libsail-c++\")\n        self.cpp_info.components[\"sail-c++\"].names[\"cmake_find_package\"]       = \"SailC++\"\n        self.cpp_info.components[\"sail-c++\"].names[\"cmake_find_package_multi\"] = \"SailC++\"\n        self.cpp_info.components[\"sail-c++\"].libs = [\"sail-c++\"]\n        self.cpp_info.components[\"sail-c++\"].requires = [\"libsail\", \"sail-manip\"]\n", "path": "recipes/sail/all/conanfile.py"}]}