Add config options for systemd files
This commit is contained in:
parent
3d7b66474e
commit
c13eaf6b70
22
lvm2.spec
22
lvm2.spec
@ -2,16 +2,25 @@
|
||||
%define enable_cluster 1
|
||||
|
||||
%if "%{fedora}" == "12"
|
||||
%define enable_systemd 0
|
||||
%define enable_udev 0
|
||||
%define configure_default_data_alignment --with-default-data-alignment=0
|
||||
%else
|
||||
%if "%{fedora}" == "13"
|
||||
%define enable_systemd 0
|
||||
%define enable_udev 1
|
||||
%define udev_version 153-1
|
||||
%define configure_default_data_alignment --with-default-data-alignment=0
|
||||
%else
|
||||
%if "%{fedora}" == "14"
|
||||
%define enable_systemd 0
|
||||
%define enable_udev 1
|
||||
%define udev_version 158-1
|
||||
%else
|
||||
%define enable_systemd 1
|
||||
%define enable_udev 1
|
||||
%define udev_version 158-1
|
||||
%endif
|
||||
%endif
|
||||
%endif
|
||||
|
||||
@ -30,12 +39,14 @@
|
||||
Summary: Userland logical volume management tools
|
||||
Name: lvm2
|
||||
Version: 2.02.84
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
License: GPLv2
|
||||
Group: System Environment/Base
|
||||
URL: http://sources.redhat.com/lvm2
|
||||
Source0: ftp://sources.redhat.com/pub/lvm2/LVM2.%{version}.tgz
|
||||
%if %{enable_systemd}
|
||||
Source1: %{name}-tmpfiles.conf
|
||||
%endif
|
||||
Patch0: lvm2-set-default-preferred_names.patch
|
||||
|
||||
BuildRequires: libselinux-devel >= 1.30.19-4, libsepol-devel
|
||||
@ -52,7 +63,9 @@ BuildRequires: pkgconfig
|
||||
BuildRequires: libudev-devel
|
||||
%endif
|
||||
Requires: %{name}-libs = %{version}-%{release}
|
||||
%if %{enable_systemd}
|
||||
Requires: initscripts
|
||||
%endif
|
||||
Requires: module-init-tools
|
||||
Requires(post): chkconfig
|
||||
Requires(preun): chkconfig
|
||||
@ -89,8 +102,10 @@ make %{?_smp_mflags}
|
||||
make install DESTDIR=$RPM_BUILD_ROOT
|
||||
make install_system_dirs DESTDIR=$RPM_BUILD_ROOT
|
||||
make install_initscripts DESTDIR=$RPM_BUILD_ROOT
|
||||
%if %{enable_systemd}
|
||||
mkdir -p %{buildroot}%{_sysconfdir}/tmpfiles.d
|
||||
install -m 0644 %{SOURCE1} %{buildroot}%{_sysconfdir}/tmpfiles.d/%{name}.conf
|
||||
%endif
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
@ -215,7 +230,9 @@ fi
|
||||
%dir %{_localstatedir}/lock/lvm
|
||||
%dir %{_localstatedir}/run/lvm
|
||||
%{_sysconfdir}/rc.d/init.d/lvm2-monitor
|
||||
%if %{enable_systemd}
|
||||
%config(noreplace) %{_sysconfdir}/tmpfiles.d/%{name}.conf
|
||||
%endif
|
||||
|
||||
##############################################################################
|
||||
# Library and Development subpackages
|
||||
@ -475,6 +492,9 @@ the device-mapper event library.
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri May 6 2011 Zdenek Kabelac <zkabelac@redhat.com> - 2.02.84-2
|
||||
- Merge rawhide spec file and make systemd initscripts configurable.
|
||||
|
||||
* Wed Feb 9 2011 Alasdair Kergon <agk@redhat.com> - 2.02.84-1
|
||||
- Fix big-endian CRC32 checksumming broken since 2.02.75. If affected,
|
||||
ensure metadata backups in /etc/lvm/backup are up-to-date (vgcfgbackup)
|
||||
|
Loading…
Reference in New Issue
Block a user