lg2 does not support sdbusplus::message::object_path type
lxwinspur opened this issue · 1 comments
lxwinspur commented
Here is a piece of pseudo code:
sdbusplus::message::object_path objectPath;
... ...
info("objectPath: {PATH}", "PATH", objectPath);
When I compile, the error message is as follows:
In file included from /usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:8,
from ../fault-monitor/fru-fault-monitor.cpp:6:
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp: In instantiation of ‘auto lg2::details::log_convert(const char*, lg2::details::log_flag<As ...>, T) [with Fs = {}; T = sdbusplus::message::details::string_path_wrapper]’:
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:343:50: required from ‘static void lg2::details::log_conversion::step(std::tuple<_Tps ...>&&, const lg2::details::header_str&, V&&, Ss&& ...) [with Ts = {lg2::level&, const std::source_location&, const char*&}; V = sdbusplus::message::details::string_path_wrapper&; Ss = {}]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:387:17: required from ‘static void lg2::details::log_conversion::start(lg2::level, const source_location&, const char*, Ts&& ...) [with Ts = {const lg2::details::header_str&, sdbusplus::message::details::string_path_wrapper&}; lg2::source_location = std::source_location]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:29:39: required from ‘lg2::log<S, Ts>::log(const source_location&, const char*, lg2::details::header_str_conversion_t<Ts&&>...) [with lg2::level S = lg2::level::info; Ts = {const char (&)[5], sdbusplus::message::details::string_path_wrapper&}; lg2::source_location = std::source_location]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:43:80: required from ‘lg2::log<S, Ts>::log(const char*, lg2::details::header_str_conversion_t<Ts&&>..., const source_location&) [with lg2::level S = lg2::level::info; Ts = {const char (&)[5], sdbusplus::message::details::string_path_wrapper&}; lg2::source_location = std::source_location]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:85:1: required from here
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:71:19: error: static assertion failed: Unsupported type for logging value.
71 | static_assert(!std::is_same_v<T, T>, "Unsupported type for logging value.");
| ^~~~~~~~~~~~~~~~~~~~~
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:71:19: note: ‘!(bool)std::is_same_v<sdbusplus::message::details::string_path_wrapper, sdbusplus::message::details::string_path_wrapper>’ evaluates to false
@williamspatrick Could you take a look this issue?
lxwinspur commented