From 6c8dc88c651d81bb9f8845fb5620986309292e72 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 9 Jan 2022 21:19:55 +0100 Subject: [PATCH 1/2] modernize & fix pkg_config name --- recipes/spirv-headers/all/conanfile.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/spirv-headers/all/conanfile.py b/recipes/spirv-headers/all/conanfile.py index f8aed7a6b1928..c889b36cc89a4 100644 --- a/recipes/spirv-headers/all/conanfile.py +++ b/recipes/spirv-headers/all/conanfile.py @@ -1,7 +1,7 @@ from conans import ConanFile, tools, CMake import os -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.43.0" class SpirvheadersConan(ConanFile): @@ -53,5 +53,10 @@ def package(self): tools.rmdir(os.path.join(self.package_folder, "share")) def package_info(self): + self.cpp_info.set_property("cmake_file_name", "SPIRV-Headers") + self.cpp_info.set_property("cmake_target_name", "SPIRV-Headers::SPIRV-Headers") + self.cpp_info.set_property("pkg_config_name", "SPIRV-Headers") + + # TODO: remove in conan v2 once cmake_find_package* generators removed self.cpp_info.names["cmake_find_package"] = "SPIRV-Headers" self.cpp_info.names["cmake_find_package_multi"] = "SPIRV-Headers" From ccfb3b5cd1b4c1e0368905a48eb5a8450b95b180 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 11 Jan 2022 01:30:26 +0100 Subject: [PATCH 2/2] keep .names[pkg_config] --- recipes/spirv-headers/all/conanfile.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/recipes/spirv-headers/all/conanfile.py b/recipes/spirv-headers/all/conanfile.py index c889b36cc89a4..7c5ae768b807b 100644 --- a/recipes/spirv-headers/all/conanfile.py +++ b/recipes/spirv-headers/all/conanfile.py @@ -57,6 +57,7 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "SPIRV-Headers::SPIRV-Headers") self.cpp_info.set_property("pkg_config_name", "SPIRV-Headers") - # TODO: remove in conan v2 once cmake_find_package* generators removed + # TODO: to remove in conan v2 once cmake_find_package* & pkg_config generators removed self.cpp_info.names["cmake_find_package"] = "SPIRV-Headers" self.cpp_info.names["cmake_find_package_multi"] = "SPIRV-Headers" + self.cpp_info.names["pkg_config"] = "SPIRV-Headers"