summaryrefslogtreecommitdiff
path: root/games-emulation/dolphin/files/dolphin-5.0_p20220520-libfmt-9.0.0-fix-build.patch
blob: 5bc2ae3877f472e4bf2a734223845d30cf226d00 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
From: Christopher Rudolph
Fix build with libfmt-9.0.0
Upstream report: https://github.com/dolphin-emu/dolphin/pull/10825

diff --git a/Source/Core/Common/MsgHandler.h b/Source/Core/Common/MsgHandler.h
index 750da51..1d6a467 100644
--- a/Source/Core/Common/MsgHandler.h
+++ b/Source/Core/Common/MsgHandler.h
@@ -41,7 +41,11 @@ bool MsgAlertFmt(bool yes_no, MsgType style, Common::Log::LogType log_type, cons
   static_assert(NumFields == sizeof...(args),
                 "Unexpected number of replacement fields in format string; did you pass too few or "
                 "too many arguments?");
+#if FMT_VERSION >= 90000
+  static_assert(fmt::detail::is_compile_string<S>::value);
+#else
   static_assert(fmt::is_compile_string<S>::value);
+#endif
   return MsgAlertFmtImpl(yes_no, style, log_type, file, line, format,
                          fmt::make_format_args(args...));
 }
@@ -56,7 +60,11 @@ bool MsgAlertFmtT(bool yes_no, MsgType style, Common::Log::LogType log_type, con
   static_assert(NumFields == sizeof...(args),
                 "Unexpected number of replacement fields in format string; did you pass too few or "
                 "too many arguments?");
+#if FMT_VERSION >= 90000
+  static_assert(fmt::detail::is_compile_string<S>::value);
+#else
   static_assert(fmt::is_compile_string<S>::value);
+#endif
   auto arg_list = fmt::make_format_args(args...);
   return MsgAlertFmtImpl(yes_no, style, log_type, file, line, translated_format, arg_list);
 }