1diff --git a/src/thirdparty/axom/fmt/compile.h b/src/thirdparty/axom/fmt/compile.h
2index 4a4643667..a482090dc 100644
3--- a/src/thirdparty/axom/fmt/compile.h
4+++ b/src/thirdparty/axom/fmt/compile.h
5@@ -475,7 +475,9 @@ class compiled_format : private compiled_format_base<S> {
6       : compiled_format_base<S>(format_str), format_str_(format_str) {}
7 };
8
9-#ifdef __cpp_if_constexpr
10+// start axom change
11+#if defined(__cpp_if_constexpr) && defined(__cpp_return_type_deduction)
12+// end axom change
13 template <typename... Args> struct type_list {};
14
15 // Returns a reference to the argument at index N from [first, rest...].
16@@ -798,7 +800,9 @@ template <typename... Args, typename S,
17 constexpr auto compile(S format_str) -> detail::compiled_format<S, Args...> {
18   return detail::compiled_format<S, Args...>(to_string_view(format_str));
19 }
20-#endif  // __cpp_if_constexpr
21+// start axom change
22+#endif  // defined(__cpp_if_constexpr) && defined(__cpp_return_type_deduction)
23+// end axom change
24
25 // Compiles the format string which must be a string literal.
26 template <typename... Args, typename Char, size_t N>
27