From 15d2acb41f7cd58b38f9cb8385bede7d4d09e029 Mon Sep 17 00:00:00 2001 From: Francisco Ramirez de Anton Date: Mon, 15 Nov 2021 18:30:16 +0100 Subject: [PATCH] Changed legacy names and build_modules by set_properties() --- recipes/openssl/3.x.x/conanfile.py | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/recipes/openssl/3.x.x/conanfile.py b/recipes/openssl/3.x.x/conanfile.py index a54202983043b..136766bdaaa89 100644 --- a/recipes/openssl/3.x.x/conanfile.py +++ b/recipes/openssl/3.x.x/conanfile.py @@ -6,7 +6,7 @@ import os import textwrap -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.36.0" class OpenSSLConan(ConanFile): @@ -711,13 +711,14 @@ def _module_file_rel_path(self): "conan-official-{}-variables.cmake".format(self.name)) def package_info(self): - self.cpp_info.names["cmake_find_package"] = "OpenSSL" - self.cpp_info.names["cmake_find_package_multi"] = "OpenSSL" - self.cpp_info.names["pkg_config"] = "openssl" + self.cpp_info.set_property("cmake_target_name", "OpenSSL") + self.cpp_info.set_property("pkg_config_name", "openssl") + self.cpp_info.components["ssl"].builddirs.append(self._module_subfolder) - self.cpp_info.components["ssl"].build_modules["cmake_find_package"] = [self._module_file_rel_path] + self.cpp_info.components["ssl"].set_property("cmake_build_modules", [self._module_file_rel_path]) self.cpp_info.components["crypto"].builddirs.append(self._module_subfolder) - self.cpp_info.components["crypto"].build_modules["cmake_find_package"] = [self._module_file_rel_path] + self.cpp_info.components["crypto"].set_property("cmake_build_modules", [self._module_file_rel_path]) + if self._use_nmake: libsuffix = "d" if self.settings.build_type == "Debug" else "" self.cpp_info.components["ssl"].libs = ["libssl" + libsuffix] @@ -743,9 +744,7 @@ def package_info(self): self.cpp_info.components["crypto"].system_libs.append("atomic") self.cpp_info.components["ssl"].system_libs.append("atomic") - self.cpp_info.components["crypto"].names["cmake_find_package"] = "Crypto" - self.cpp_info.components["crypto"].names["cmake_find_package_multi"] = "Crypto" - self.cpp_info.components["crypto"].names["pkg_config"] = "libcrypto" - self.cpp_info.components["ssl"].names["cmake_find_package"] = "SSL" - self.cpp_info.components["ssl"].names["cmake_find_package_multi"] = "SSL" - self.cpp_info.components["ssl"].names["pkg_config"] = "libssl" + self.cpp_info.components["crypto"].set_property("cmake_target_name", "Crypto") + self.cpp_info.components["crypto"].set_property("pkg_config_name", "libcrypto") + self.cpp_info.components["ssl"].set_property("cmake_target_name", "SSL") + self.cpp_info.components["ssl"].set_property("pkg_config_name", "libssl")