[packages/lizardfs] - fix building with spdlog 1.x

baggins baggins at pld-linux.org
Tue Jun 9 22:36:08 CEST 2020


commit 4b13ae9dc2062835b682f2ee7cf979811f478f68
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Tue Jun 9 22:35:53 2020 +0200

    - fix building with spdlog 1.x

 lizardfs.spec  |  4 +++-
 spdlog-1.patch | 11 +++++++++++
 2 files changed, 14 insertions(+), 1 deletion(-)
---
diff --git a/lizardfs.spec b/lizardfs.spec
index 5008893..086aa84 100644
--- a/lizardfs.spec
+++ b/lizardfs.spec
@@ -17,6 +17,7 @@ Source2:	%{name}-chunkserver.service
 Patch0:		system-spdlog.patch
 Patch1:		x32.patch
 Patch2:		0001-Add-missing-header.patch
+Patch3:		spdlog-1.patch
 URL:		https://github.com/lizardfs/lizardfs
 BuildRequires:	/usr/bin/a2x
 BuildRequires:	asciidoc
@@ -33,7 +34,7 @@ BuildRequires:	judy-devel
 BuildRequires:	libfuse-devel
 BuildRequires:	pkgconfig
 BuildRequires:	rpmbuild(macros) >= 1.647
-BuildRequires:	spdlog-devel >= 0.14.0
+BuildRequires:	spdlog-devel >= 1.12-2
 BuildRequires:	zlib-devel
 Requires(post,preun,postun):	systemd-units >= 38
 Requires(postun):	/usr/sbin/groupdel
@@ -94,6 +95,7 @@ CGI server
 %patch0 -p1
 %patch1 -p1
 %patch2 -p1
+%patch3 -p1
 
 %{__rm} -r external/crcutil-1.0
 
diff --git a/spdlog-1.patch b/spdlog-1.patch
new file mode 100644
index 0000000..c523bac
--- /dev/null
+++ b/spdlog-1.patch
@@ -0,0 +1,11 @@
+--- lizardfs-3.12.0/src/common/slogger.cc~	2017-12-20 10:59:37.000000000 +0100
++++ lizardfs-3.12.0/src/common/slogger.cc	2020-06-09 22:20:57.067884728 +0200
+@@ -97,7 +97,7 @@
+ 
+ bool lzfs::add_log_stderr(log_level::LogLevel level) {
+ 	try {
+-		LoggerPtr logger = spdlog::stderr_color_mt("stderr");
++		LoggerPtr logger = spdlog::stderr_logger_mt("stderr", true);
+ 		logger->set_level((spdlog::level::level_enum)level);
+ 		// Format: DATE TIME [LEVEL] [PID:TID] : MESSAGE
+ 		logger->set_pattern("%D %H:%M:%S.%e [%l] [%P:%t] : %v");
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/lizardfs.git/commitdiff/4b13ae9dc2062835b682f2ee7cf979811f478f68



More information about the pld-cvs-commit mailing list