Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGuillaume Egles2022-02-05 10:32:06 -0800
committerMartin Hořeňovský2022-02-05 20:53:43 +0100
commit190f71792a0989c3d67ae4fcc656439aae4f8593 (patch)
tree3eb0ce930c42f0ac95fcf7f7a7e295db8ca51a35
parentc912f62fc46b2c1ab048399a5dadda703952dddf (diff)
downloadcatch3-190f71792a0989c3d67ae4fcc656439aae4f8593.tar.gz
proper support for lib suffix in conan
-rw-r--r--conanfile.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/conanfile.py b/conanfile.py
index 1c25827b..c6f12e07 100644
--- a/conanfile.py
+++ b/conanfile.py
@@ -42,16 +42,18 @@ conan_basic_setup()'''.format(line_to_replace, self.install_folder.replace("\\",
cmake.install()
def package_info(self):
+ lib_suffix = "d" if self.settings.build_type == "Debug" else ""
+
self.cpp_info.names["cmake_find_package"] = "Catch2"
self.cpp_info.names["cmake_find_package_multi"] = "Catch2"
# Catch2
self.cpp_info.components["catch2base"].names["cmake_find_package"] = "Catch2"
self.cpp_info.components["catch2base"].names["cmake_find_package_multi"] = "Catch2"
self.cpp_info.components["catch2base"].names["pkg_config"] = "Catch2"
- self.cpp_info.components["catch2base"].libs = ["Catch2"]
+ self.cpp_info.components["catch2base"].libs = ["Catch2" + lib_suffix]
# Catch2WithMain
self.cpp_info.components["catch2main"].names["cmake_find_package"] = "Catch2WithMain"
self.cpp_info.components["catch2main"].names["cmake_find_package_multi"] = "Catch2WithMain"
self.cpp_info.components["catch2main"].names["pkg_config"] = "Catch2WithMain"
- self.cpp_info.components["catch2main"].libs = ["Catch2Main"]
+ self.cpp_info.components["catch2main"].libs = ["Catch2Main" + lib_suffix]
self.cpp_info.components["catch2main"].requires = ["catch2base"]