in latest libfmt, <fmt/time.h> is deprecated.
to silence warnings like
/home/kchai/ceph/src/fmt/include/fmt/time.h:13:2: warning: #warning
fmt/time.h is deprecated, use fmt/chrono.h instead [-Wcpp]
#warning fmt/time.h is deprecated, use fmt/chrono.h instead
^~~~~~~
In file included from
/home/kchai/ceph/src/seastar/include/seastar/core/reactor.hh:72:0,
from
/home/kchai/ceph/src/seastar/include/seastar/core/sharded.hh:24,
from /home/kchai/ceph/src/crimson/net/Fwd.h:18,
from /home/kchai/ceph/src/crimson/net/Protocol.h:9,
from /home/kchai/ceph/src/crimson/net/ProtocolV2.h:6,
from /home/kchai/ceph/src/crimson/net/ProtocolV2.cc:4:
Signed-off-by: Kefu Chai <kchai@redhat.com>
#include <seastar/core/lowres_clock.hh>
#include <fmt/format.h>
+#if __has_include(<fmt/chrono.h>)
+#include <fmt/chrono.h>
+#else
#include <fmt/time.h>
-
+#endif
#include "include/msgr.h"
#include "include/random.h"