Change spec file to support excluding cluster components from the build.
This commit is contained in:
parent
f7383a5307
commit
fa028598e6
29
lvm2.spec
29
lvm2.spec
@ -1,7 +1,14 @@
|
||||
%define device_mapper_version 1.02.44
|
||||
%define enable_cluster 1
|
||||
|
||||
%if %{enable_cluster}
|
||||
%define corosync_version 1.2.0-1
|
||||
%define openais_version 1.1.1-1
|
||||
%define clusterlib_version 3.0.6-1
|
||||
%define configure_cluster --with-cluster=internal --with-clvmd=cman,openais,corosync --enable-cmirrord
|
||||
%else
|
||||
%define configure_cluster --with-cluster=internal --with-clvmd=none --disable-cmirrord
|
||||
%endif
|
||||
|
||||
# Do not reset Release to 1 unless both lvm2 and device-mapper
|
||||
# versions are increased together.
|
||||
@ -9,7 +16,7 @@
|
||||
Summary: Userland logical volume management tools
|
||||
Name: lvm2
|
||||
Version: 2.02.61
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
License: GPLv2
|
||||
Group: System Environment/Base
|
||||
URL: http://sources.redhat.com/lvm2
|
||||
@ -19,9 +26,11 @@ Patch0: lvm2-set-default-preferred_names.patch
|
||||
BuildRequires: libselinux-devel >= 1.30.19-4, libsepol-devel
|
||||
BuildRequires: ncurses-devel
|
||||
BuildRequires: readline-devel
|
||||
%if %{enable_cluster}
|
||||
BuildRequires: corosynclib-devel >= %{corosync_version}
|
||||
BuildRequires: openaislib-devel >= %{openais_version}
|
||||
BuildRequires: clusterlib-devel >= %{clusterlib_version}
|
||||
%endif
|
||||
BuildRequires: module-init-tools
|
||||
BuildRequires: pkgconfig
|
||||
BuildRequires: libudev-devel
|
||||
@ -54,7 +63,7 @@ or more physical volumes and creating one or more logical volumes
|
||||
%define _udevbasedir /lib/udev
|
||||
%define _udevdir %{_udevbasedir}/rules.d
|
||||
|
||||
%configure --enable-lvm1_fallback --enable-fsadm --with-clvmd=cman,openais,corosync --with-cluster=internal --with-pool=internal --with-user= --with-group= --with-usrlibdir=/usr/%{_lib} --with-usrsbindir=/usr/sbin --with-udevdir=%{_udevdir} --with-device-uid=0 --with-device-gid=6 --with-device-mode=0660 --enable-pkgconfig --enable-applib --enable-cmdlib --enable-dmeventd --enable-udev_sync --enable-cmirrord
|
||||
%configure --enable-lvm1_fallback --enable-fsadm --with-pool=internal --with-user= --with-group= --with-usrlibdir=/usr/%{_lib} --with-usrsbindir=/usr/sbin --with-udevdir=%{_udevdir} --with-device-uid=0 --with-device-gid=6 --with-device-mode=0660 --enable-pkgconfig --enable-applib --enable-cmdlib --enable-dmeventd --enable-udev_sync %{configure_cluster}
|
||||
|
||||
make %{?_smp_mflags}
|
||||
|
||||
@ -67,8 +76,10 @@ install -m 0700 -d $RPM_BUILD_ROOT/var/lock/lvm
|
||||
install -m 0600 /dev/null $RPM_BUILD_ROOT/etc/lvm/cache/.cache
|
||||
|
||||
mkdir -p -m755 $RPM_BUILD_ROOT/etc/rc.d/init.d
|
||||
%if %{enable_cluster}
|
||||
install scripts/clvmd_init_red_hat $RPM_BUILD_ROOT/etc/rc.d/init.d/clvmd
|
||||
install scripts/cmirrord_init_red_hat $RPM_BUILD_ROOT/etc/rc.d/init.d/cmirrord
|
||||
%endif
|
||||
install -m 0755 scripts/lvm2_monitoring_init_red_hat $RPM_BUILD_ROOT/etc/rc.d/init.d/lvm2-monitor
|
||||
install -m 0755 scripts/lvmconf.sh $RPM_BUILD_ROOT/sbin/lvmconf
|
||||
|
||||
@ -133,6 +144,7 @@ fi
|
||||
%{_sbindir}/vgs
|
||||
%{_sbindir}/vgscan
|
||||
%{_sbindir}/vgsplit
|
||||
%{_sbindir}/lvmconf
|
||||
%{_mandir}/man5/lvm.conf.5.gz
|
||||
%{_mandir}/man8/fsadm.8.gz
|
||||
%{_mandir}/man8/lvchange.8.gz
|
||||
@ -236,6 +248,8 @@ This package contains shared lvm2 libraries for applications.
|
||||
##############################################################################
|
||||
# Cluster subpackage
|
||||
##############################################################################
|
||||
%if %{enable_cluster}
|
||||
|
||||
%package cluster
|
||||
Summary: Cluster extensions for userland logical volume management tools
|
||||
License: GPLv2
|
||||
@ -250,6 +264,7 @@ Requires: openais >= %{openais_version}
|
||||
Requires: cman >= %{clusterlib_version}
|
||||
|
||||
%description cluster
|
||||
|
||||
Extensions to LVM2 to support clusters.
|
||||
|
||||
%post cluster
|
||||
@ -266,13 +281,16 @@ fi
|
||||
%files cluster
|
||||
%defattr(-,root,root,-)
|
||||
%attr(755,root,root) /usr/sbin/clvmd
|
||||
%{_sbindir}/lvmconf
|
||||
%{_mandir}/man8/clvmd.8.gz
|
||||
/etc/rc.d/init.d/clvmd
|
||||
|
||||
%endif
|
||||
|
||||
##############################################################################
|
||||
# Cluster mirror subpackage
|
||||
##############################################################################
|
||||
%if %{enable_cluster}
|
||||
|
||||
%package -n cmirror
|
||||
Summary: Daemon for device-mapper-based clustered mirrors
|
||||
Group: System Environment/Base
|
||||
@ -298,6 +316,8 @@ fi
|
||||
%{_mandir}/man8/cmirrord.8.gz
|
||||
/etc/rc.d/init.d/cmirrord
|
||||
|
||||
%endif
|
||||
|
||||
##############################################################################
|
||||
# Device-mapper subpackages
|
||||
##############################################################################
|
||||
@ -423,6 +443,9 @@ the device-mapper event library.
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Mar 05 2010 Peter Rajnoha <prajnoha@redhat.com> - 2.02.61-2
|
||||
- Change spec file to support excluding cluster components from the build.
|
||||
|
||||
* Tue Feb 16 2010 Alasdair Kergon <agk@redhat.com> - 2.02.61-1
|
||||
- Add %ORIGIN support to lv{create,extend,reduce,resize} --extents.
|
||||
- Accept a list of LVs with 'lvconvert --merge @tag' using process_each_lv.
|
||||
|
Loading…
Reference in New Issue
Block a user