use std::format instead of fmt::format
The std::format is sufficient for the uses in this repository except
for in one file (override_fan_target.cpp, since P2286 isn't supported
by GCC yet). Switch to std::format whenever possible.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ib2576fb530a4d7ce238e1b0bd95b40b476ec2107
diff --git a/control/json/manager.hpp b/control/json/manager.hpp
index ad92720..369b6bf 100644
--- a/control/json/manager.hpp
+++ b/control/json/manager.hpp
@@ -25,8 +25,6 @@
#include "utils/flight_recorder.hpp"
#include "zone.hpp"
-#include <fmt/format.h>
-
#include <nlohmann/json.hpp>
#include <phosphor-logging/log.hpp>
#include <sdbusplus/bus.hpp>
@@ -36,6 +34,7 @@
#include <sdeventplus/utility/timer.hpp>
#include <chrono>
+#include <format>
#include <map>
#include <memory>
#include <optional>
@@ -210,7 +209,7 @@
if (!confFile.empty())
{
FlightRecorder::instance().log(
- "main", fmt::format("Loading configuration from {}",
+ "main", std::format("Loading configuration from {}",
confFile.string()));
for (const auto& entry : fan::JsonConfig::load(confFile))
{
@@ -242,11 +241,11 @@
std::move(obj));
}
log<level::INFO>(
- fmt::format("Configuration({}) loaded successfully",
+ std::format("Configuration({}) loaded successfully",
T::confFileName)
.c_str());
FlightRecorder::instance().log(
- "main", fmt::format("Configuration({}) loaded successfully",
+ "main", std::format("Configuration({}) loaded successfully",
T::confFileName));
}
return config;