2018-04-13 13:19:25 +02:00
|
|
|
# Determine based on distribution & version what options & packages to include
|
|
|
|
%if 0%{?fedora} || 0%{?rhel} >= 7
|
|
|
|
%global with_systemd 1
|
|
|
|
%else
|
|
|
|
%global with_systemd 0
|
|
|
|
%endif
|
|
|
|
|
|
|
|
Name: onedrive
|
2020-05-27 00:47:35 +02:00
|
|
|
Version: 2.4.2
|
2018-04-15 00:57:22 +02:00
|
|
|
Release: 1%{?dist}
|
2018-04-13 13:19:25 +02:00
|
|
|
Summary: Microsoft OneDrive Client
|
|
|
|
Group: System Environment/Network
|
|
|
|
License: GPLv3
|
2018-04-15 00:57:22 +02:00
|
|
|
URL: https://github.com/abraunegg/onedrive
|
2020-04-18 22:24:35 +02:00
|
|
|
Source0: v%{version}.tar.gz
|
2018-04-13 13:19:25 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
|
|
2020-04-18 22:24:35 +02:00
|
|
|
BuildRequires: dmd >= 2.083.0
|
|
|
|
BuildRequires: sqlite-devel >= 3.7.15
|
|
|
|
BuildRequires: libcurl-devel
|
|
|
|
Requires: sqlite >= 3.7.15
|
|
|
|
Requires: libcurl
|
2018-04-13 13:19:25 +02:00
|
|
|
|
|
|
|
%if 0%{?with_systemd}
|
|
|
|
Requires(post): systemd
|
|
|
|
Requires(preun): systemd
|
|
|
|
Requires(postun): systemd
|
|
|
|
%else
|
|
|
|
Requires(post): chkconfig
|
|
|
|
Requires(preun): chkconfig
|
|
|
|
Requires(preun): initscripts
|
|
|
|
Requires(postun): initscripts
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%define debug_package %{nil}
|
|
|
|
|
|
|
|
%description
|
|
|
|
Microsoft OneDrive Client for Linux
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
2020-04-18 22:24:35 +02:00
|
|
|
%setup -q
|
|
|
|
# This creates the directory %{_builddir}/%{name}-%{version}/
|
2018-04-13 13:19:25 +02:00
|
|
|
|
|
|
|
%build
|
2020-04-18 22:24:35 +02:00
|
|
|
# cd %{_builddir}/%{name}-%{version}
|
|
|
|
%configure
|
|
|
|
make
|
2018-04-13 13:19:25 +02:00
|
|
|
|
|
|
|
%install
|
2020-04-18 22:24:35 +02:00
|
|
|
%make_install PREFIX="%{buildroot}"
|
2018-04-13 13:19:25 +02:00
|
|
|
|
|
|
|
%clean
|
|
|
|
|
|
|
|
%files
|
2020-04-18 22:24:35 +02:00
|
|
|
%doc README.md LICENSE CHANGELOG.md
|
|
|
|
%config %{_sysconfdir}/logrotate.d/onedrive
|
|
|
|
%{_mandir}/man1/%{name}.1.gz
|
|
|
|
%{_docdir}/%{name}
|
|
|
|
%{_bindir}/%{name}
|
2018-04-13 13:19:25 +02:00
|
|
|
%if 0%{?with_systemd}
|
2020-04-18 22:24:35 +02:00
|
|
|
%{_unitdir}/%{name}.service
|
|
|
|
%{_unitdir}/%{name}@.service
|
2018-04-13 13:19:25 +02:00
|
|
|
%else
|
2020-04-18 22:24:35 +02:00
|
|
|
%{_bindir}/onedrive_service.sh
|
|
|
|
/etc/init.d/onedrive
|
2018-04-13 13:19:25 +02:00
|
|
|
%endif
|
|
|
|
|
2020-04-18 22:24:35 +02:00
|
|
|
%changelog
|