File casync.spec of Package casync

#
# spec file for package casync
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           casync
Version:        0.1.git+1497994684.675e790
Release:        0
Summary:        Content-Addressable Data Synchronization Tool
License:        LGPL-2.1+
Group:          Productivity/Archiving/Backup
Url:            https://github.com/systemd/casync
Source:         %{name}-%{version}.tar.xz
BuildRequires:  etags
BuildRequires:  git
BuildRequires:  libacl-devel
BuildRequires:  libgcrypt-devel
BuildRequires:  meson >= 0.40
BuildRequires:  ninja
BuildRequires:  pkgconfig(fuse) >= 2.6
BuildRequires:  pkgconfig(libcurl) >= 7.32.0
BuildRequires:  pkgconfig(liblzma) >= 5.1.0
%if 0%{?leap_version} == 420300
BuildRequires:  gcc5
%else
BuildRequires:  gcc >= 4.9.0
%endif
%if 0%{?suse_version} > 1320
BuildRequires:  python3-Sphinx >= 1.4
%endif
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
1. A combination of the rsync algorithm and content-addressable storage
2. An efficient way to store and retrieve multiple related versions of large
   file systems or directory trees
3. An efficient way to deliver and update OS, VM, IoT and container images
   over the Internet in an HTTP and CDN friendly way
4. An efficient backup system

%prep
%setup -q

%build
%if 0%{?leap_version} == 420300
export CC="gcc-5"
%endif
%{meson}
%{meson_build}
%if 0%{?suse_version} > 1320
sphinx-build -b man doc build/doc
%endif

%install
%{meson_install}
%if 0%{?suse_version} > 1320
install -Dm 0644 build/doc/%{name}.1 -t %{buildroot}%{_mandir}/man1/
%endif

%files
%defattr(-,root,root)
%doc LICENSE.LGPL2.1 README.md TODO
%{_bindir}/%{name}
%dir %{_libexecdir}/%{name}
%dir %{_libexecdir}/%{name}/protocols
%{_libexecdir}/%{name}/protocols/%{name}-*
%if 0%{?suse_version} > 1320
%{_mandir}/man?/casync.?%{ext_man}
%endif

%changelog
openSUSE Build Service is sponsored by