[packages/lizardfs] - up to 3.12.0 - build with system spdlog - add missing header for makedev(2) (patch from fedora)
baggins
baggins at pld-linux.org
Tue Jun 9 22:12:18 CEST 2020
commit 207db56a83545f0f58e8c4a6ba3496eb7b2f1785
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Tue Jun 9 22:11:32 2020 +0200
- up to 3.12.0
- build with system spdlog
- add missing header for makedev(2) (patch from fedora)
0001-Add-missing-header.patch | 25 ++++++++++++++++++++++++
lizardfs.spec | 29 ++++++++++++++++++++--------
system-spdlog.patch | 44 +++++++++++++++++++++++++++++++++++++++++++
3 files changed, 90 insertions(+), 8 deletions(-)
---
diff --git a/lizardfs.spec b/lizardfs.spec
index 3788809..5008893 100644
--- a/lizardfs.spec
+++ b/lizardfs.spec
@@ -6,15 +6,17 @@
Summary: Open Source Distributed File System
Summary(pl.UTF-8): Rozporoszony system plików Open Source
Name: lizardfs
-Version: 3.11.3
-Release: 0.1
+Version: 3.12.0
+Release: 1
License: GPL v3
Group: Applications
-Source0: https://github.com/lizardfs/lizardfs/archive/v%{version}.tar.gz
-# Source0-md5: 0b3647e69503e5d3b37f07f1b07f4850
+Source0: https://github.com/lizardfs/lizardfs/archive/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5: e584aa9534f900ca04d40a4772e01302
Source1: %{name}-master.service
Source2: %{name}-chunkserver.service
+Patch0: system-spdlog.patch
Patch1: x32.patch
+Patch2: 0001-Add-missing-header.patch
URL: https://github.com/lizardfs/lizardfs
BuildRequires: /usr/bin/a2x
BuildRequires: asciidoc
@@ -31,9 +33,8 @@ BuildRequires: judy-devel
BuildRequires: libfuse-devel
BuildRequires: pkgconfig
BuildRequires: rpmbuild(macros) >= 1.647
+BuildRequires: spdlog-devel >= 0.14.0
BuildRequires: zlib-devel
-
-
Requires(post,preun,postun): systemd-units >= 38
Requires(postun): /usr/sbin/groupdel
Requires(postun): /usr/sbin/userdel
@@ -90,10 +91,23 @@ CGI server
%prep
%setup -q
+%patch0 -p1
%patch1 -p1
+%patch2 -p1
%{__rm} -r external/crcutil-1.0
+
+%{__sed} -E -i -e '1s,#!\s*/usr/bin/env\s+python2(\s|$),#!%{__python}\1,' \
+ src/cgi/chart.cgi.in \
+ src/cgi/lizardfs-cgiserver.py.in \
+ src/cgi/mfs.cgi.in \
+ src/cgi/cgiserv.py.in
+
+%{__sed} -E -i -e '1s,#!\s*/usr/bin/env\s+bash(\s|$),#!/bin/bash\1,' \
+ src/master/mfsrestoremaster.in \
+ src/tools/mfstools.sh
+
%build
install -d build
cd build
@@ -152,7 +166,7 @@ fi
%files
%defattr(644,root,root,755)
-%doc doc COPYING README UPGRADE NEWS INSTALL
+%doc doc COPYING README.md UPGRADE NEWS INSTALL
%dir %{_sysconfdir}/mfs
%dir %attr(750,root,root) /var/lib/%{name}
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mfs/globaliolimits.cfg.dist
@@ -184,7 +198,6 @@ fi
%attr(755,root,root) %{_bindir}/mfssetgoal
%attr(755,root,root) %{_bindir}/mfssetquota
%attr(755,root,root) %{_bindir}/mfssettrashtime
-%attr(755,root,root) %{_bindir}/mfssnapshot
%attr(755,root,root) %{_bindir}/mfstools.sh
%attr(755,root,root) %{_sbindir}/mfsmetadump
%attr(755,root,root) %{_sbindir}/mfsmetarestore
diff --git a/0001-Add-missing-header.patch b/0001-Add-missing-header.patch
new file mode 100644
index 0000000..fe41891
--- /dev/null
+++ b/0001-Add-missing-header.patch
@@ -0,0 +1,25 @@
+From b3dbe01831b4c5594c5c9144ef3b4f26dad6f22b Mon Sep 17 00:00:00 2001
+From: Jonathan Dieter <jdieter at gmail.com>
+Date: Thu, 15 Mar 2018 14:26:03 +0200
+Subject: [PATCH] Add missing header
+
+Signed-off-by: Jonathan Dieter <jdieter at gmail.com>
+---
+ src/chunkserver/iostat.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/chunkserver/iostat.h b/src/chunkserver/iostat.h
+index e1a50e97..85fcccd3 100644
+--- a/src/chunkserver/iostat.h
++++ b/src/chunkserver/iostat.h
+@@ -28,6 +28,7 @@
+ #include <algorithm>
+ #include <unordered_map>
+ #include <vector>
++#include <sys/sysmacros.h>
+
+ #include <sys/stat.h>
+ #include <sys/types.h>
+--
+2.14.3
+
diff --git a/system-spdlog.patch b/system-spdlog.patch
new file mode 100644
index 0000000..0dbb95f
--- /dev/null
+++ b/system-spdlog.patch
@@ -0,0 +1,44 @@
+--- lizardfs-3.12.0/CMakeLists.txt.orig 2017-12-20 10:59:37.000000000 +0100
++++ lizardfs-3.12.0/CMakeLists.txt 2020-06-09 21:44:09.672395481 +0200
+@@ -279,9 +279,7 @@
+ include_directories(${ZLIB_INCLUDE_DIRS})
+ endif()
+ include_directories(src) # Allow paths relative to src, eg. #include common/crc.h
+-include_directories(external/spdlog-0.14.0/include)
+ link_directories( ${LINK_DIRECTORIES} ${FUSE_LIBRARY_DIR} )
+-add_subdirectory(external)
+ add_subdirectory(src/admin)
+ add_subdirectory(src/common)
+ add_subdirectory(src/protocol)
+--- lizardfs-3.12.0/cmake/Libraries.cmake.orig 2017-12-20 10:59:37.000000000 +0100
++++ lizardfs-3.12.0/cmake/Libraries.cmake 2020-06-09 21:45:21.020487858 +0200
+@@ -1,17 +1,5 @@
+ include(DownloadExternal)
+
+-# Download GoogleTest
+-if(ENABLE_TESTS)
+- download_external(GTEST "googletest-release-1.7.0"
+- "https://github.com/google/googletest/archive/release-1.7.0.zip"
+- "ef5e700c8a0f3ee123e2e0209b8b4961")
+-endif()
+-
+-download_external(SPDLOG "spdlog-0.14.0"
+- "https://github.com/gabime/spdlog/archive/v0.14.0.zip"
+- "f213d83c466aa7044a132e2488d71b11"
+- "spdlog-1")
+-
+ # Find standard libraries
+ find_package(Socket REQUIRED)
+ find_package(Threads REQUIRED)
+--- lizardfs-3.12.0/src/common/slogger.h~ 2017-12-20 10:59:37.000000000 +0100
++++ lizardfs-3.12.0/src/common/slogger.h 2020-06-09 21:58:10.169405549 +0200
+@@ -26,6 +26,9 @@
+ #define SPDLOG_ENABLE_SYSLOG
+ #endif
+ #include "common/small_vector.h"
++#if !defined(LIZARDFS_HAVE_THREAD_LOCAL)
++#define SPDLOG_DISABLE_TID_CACHING
++#endif
+ #include "spdlog/spdlog.h"
+
+ typedef std::shared_ptr<spdlog::logger> LoggerPtr;
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/lizardfs.git/commitdiff/207db56a83545f0f58e8c4a6ba3496eb7b2f1785
More information about the pld-cvs-commit
mailing list