forked from pool/ocfs2-tools
Accepting request 602563 from home:elvigia:branches:network:ha-clustering:Factory
- fix pre/post/preun/postun scripts when systemd_enabled - insserv_prereq is only needed when !systemd_enabled - run fillup to actually provision /etc/sysconfig/o2cb OBS-URL: https://build.opensuse.org/request/show/602563 OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/ocfs2-tools?expand=0&rev=113
This commit is contained in:
parent
70b3733b20
commit
1c09ae681b
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Apr 30 13:49:06 UTC 2018 - crrodriguez@opensuse.org
|
||||
|
||||
- fix pre/post/preun/postun scripts when systemd_enabled
|
||||
- insserv_prereq is only needed when !systemd_enabled
|
||||
- run fillup to actually provision /etc/sysconfig/o2cb
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Dec 13 03:11:37 UTC 2017 - lchen@suse.com
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package ocfs2-tools
|
||||
#
|
||||
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2018 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
|
||||
@ -37,7 +37,7 @@ Name: ocfs2-tools
|
||||
Version: 1.8.5
|
||||
Release: 0
|
||||
Summary: Oracle Cluster File System 2 Core Tools
|
||||
License: GPL-2.0
|
||||
License: GPL-2.0-only
|
||||
Group: System/Filesystems
|
||||
Url: https://ocfs2.wiki.kernel.org/
|
||||
Source: ocfs2-tools-%{version}.tar.gz
|
||||
@ -72,7 +72,6 @@ BuildRequires: update-desktop-files
|
||||
BuildRequires: pkgconfig(glib-2.0)
|
||||
BuildRequires: pkgconfig(libxml-2.0)
|
||||
Requires(pre): %fillup_prereq
|
||||
Requires(pre): %insserv_prereq
|
||||
Requires: /sbin/chkconfig
|
||||
Requires: e2fsprogs
|
||||
Requires: glib2 >= 2.2.3
|
||||
@ -81,9 +80,10 @@ Requires: net-tools
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
Recommends: ocfs2-kmp
|
||||
%if 0%{?suse_version} >= 1315
|
||||
%define systemd_enabled 1
|
||||
%define systemd_enabled 1
|
||||
%else
|
||||
%define systemd_enabled 0
|
||||
%define systemd_enabled 0
|
||||
Requires(pre): %insserv_prereq
|
||||
%endif
|
||||
|
||||
%description
|
||||
@ -224,14 +224,34 @@ chmod a-x %{buildroot}/%{_libdir}/libocfs2.a
|
||||
%if 0%{_ocfs2console} == 1
|
||||
python -c "import compileall; compileall.compile_dir('%{buildroot}/%{py_sitedir}/ocfs2interface', ddir='%{py_sitedir}/ocfs2interface')"
|
||||
%endif
|
||||
|
||||
%pre o2cb
|
||||
%if %{systemd_enabled}
|
||||
%service_add_pre ocfs2.service o2cb.service
|
||||
%endif
|
||||
|
||||
%preun o2cb
|
||||
%if %{systemd_enabled}
|
||||
%service_del_preun ocfs2.service o2cb.service
|
||||
%else
|
||||
%stop_on_removal ocfs2
|
||||
%stop_on_removal o2cb
|
||||
%endif
|
||||
|
||||
%post o2cb
|
||||
%fillup_only -n o2cb
|
||||
%if %{systemd_enabled}
|
||||
%service_add_post ocfs2.service o2cb.service
|
||||
%endif
|
||||
|
||||
%postun o2cb
|
||||
%if %{systemd_enabled}
|
||||
%service_del_postun ocfs2.service o2cb.service
|
||||
%else
|
||||
%{insserv_cleanup}
|
||||
%restart_on_update ocfs2
|
||||
%restart_on_update o2cb
|
||||
%endif
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
|
Loading…
Reference in New Issue
Block a user