Waybar: rebuild for libfmt.so.8.
This commit is contained in:
parent
8430406c25
commit
d248139471
2 changed files with 41 additions and 1 deletions
40
srcpkgs/Waybar/patches/libfmt8-compatibility.patch
Normal file
40
srcpkgs/Waybar/patches/libfmt8-compatibility.patch
Normal file
|
@ -0,0 +1,40 @@
|
|||
From 368e4813de5356332d1167e8200cb5633e772ed6 Mon Sep 17 00:00:00 2001
|
||||
From: John Helmert III <jchelmert3@posteo.net>
|
||||
Date: Tue, 29 Jun 2021 21:29:12 -0500
|
||||
Subject: [PATCH] libfmt >=8.0.0 compatibility
|
||||
|
||||
---
|
||||
include/util/format.hpp | 4 ++++
|
||||
src/modules/clock.cpp | 3 +++
|
||||
2 files changed, 7 insertions(+)
|
||||
|
||||
diff --git a/include/util/format.hpp b/include/util/format.hpp
|
||||
index 288d8f0cd..543a100fb 100644
|
||||
--- a/Waybar-0.9.7/include/util/format.hpp
|
||||
+++ b/Waybar-0.9.7/include/util/format.hpp
|
||||
@@ -35,7 +35,11 @@ namespace fmt {
|
||||
// The rationale for ignoring it is that the only reason to specify
|
||||
// an alignment and a with is to get a fixed width bar, and ">" is
|
||||
// sufficient in this implementation.
|
||||
+#if FMT_VERSION < 80000
|
||||
width = parse_nonnegative_int(it, end, ctx);
|
||||
+#else
|
||||
+ width = detail::parse_nonnegative_int(it, end, -1);
|
||||
+#endif
|
||||
}
|
||||
return it;
|
||||
}
|
||||
diff --git a/src/modules/clock.cpp b/src/modules/clock.cpp
|
||||
index 22bedc783..82c570102 100644
|
||||
--- a/Waybar-0.9.7/src/modules/clock.cpp
|
||||
+++ b/Waybar-0.9.7/src/modules/clock.cpp
|
||||
@@ -196,6 +196,9 @@ template <>
|
||||
struct fmt::formatter<waybar_time> : fmt::formatter<std::tm> {
|
||||
template <typename FormatContext>
|
||||
auto format(const waybar_time& t, FormatContext& ctx) {
|
||||
+#if FMT_VERSION >= 80000
|
||||
+ auto& tm_format = specs;
|
||||
+#endif
|
||||
return format_to(ctx.out(), "{}", date::format(t.locale, fmt::to_string(tm_format), t.ztime));
|
||||
}
|
||||
};
|
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'Waybar'
|
||||
pkgname=Waybar
|
||||
version=0.9.7
|
||||
revision=1
|
||||
revision=2
|
||||
_date_version=3.0.0
|
||||
create_wrksrc=yes
|
||||
build_wrksrc=${pkgname}-${version}
|
||||
|
|
Loading…
Reference in a new issue