From 16bb5b850493d931779aef87ee5e394c4219d8b2 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Fri, 18 Aug 2023 17:34:08 -0700 Subject: [PATCH] spdlog: make sure libdirs is empty when header_only=True --- recipes/spdlog/all/conanfile.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/recipes/spdlog/all/conanfile.py b/recipes/spdlog/all/conanfile.py index f2653d49db0738..81b7d905c11c36 100644 --- a/recipes/spdlog/all/conanfile.py +++ b/recipes/spdlog/all/conanfile.py @@ -142,7 +142,10 @@ def package_info(self): self.cpp_info.components["libspdlog"].defines.append("SPDLOG_FMT_EXTERNAL") self.cpp_info.components["libspdlog"].requires = ["fmt::fmt"] - if not self.options.header_only: + if self.options.header_only: + self.cpp_info.libdirs = [] + self.cpp_info.components["libspdlog"].libdirs = [] + else: suffix = "d" if self.settings.build_type == "Debug" else "" self.cpp_info.components["libspdlog"].libs = [f"spdlog{suffix}"] self.cpp_info.components["libspdlog"].defines.append("SPDLOG_COMPILED_LIB")