-#
-# TODO:
-# - seems that lxc patch is not needed anymore, verify that before removing
-# - pldize virtlockd.init
-#
# Conditional build:
%bcond_without ceph # RADOS BD (Ceph) storage support
%bcond_without esx # VMware ESX support
Summary: Toolkit to interact with virtualization capabilities
Summary(pl.UTF-8): Narzędzia współpracujące z funkcjami wirtualizacji
Name: libvirt
-Version: 1.2.12
+Version: 1.2.14
Release: 1
License: LGPL v2.1+
Group: Libraries
Source0: ftp://ftp.libvirt.org/libvirt/%{name}-%{version}.tar.gz
-# Source0-md5: 2ae99535265ce4687d8718d744024c27
+# Source0-md5: 983345c4ee6535437a6ba408dd59289a
Source1: %{name}.init
-Source2: %{name}.tmpfiles
Patch0: %{name}-sasl.patch
Patch1: %{name}-lxc.patch
Patch2: %{name}-qemu-acl.patch
BuildRequires: readline-devel
BuildRequires: rpmbuild(macros) >= 1.627
%{?with_sanlock:BuildRequires: sanlock-devel >= 0.8}
-BuildRequires: systemd-devel
%{?with_systemtap:BuildRequires: systemtap-sdt-devel}
BuildRequires: udev-devel >= 1:145
%{?with_xen:BuildRequires: xen-devel >= 4.2}
Requires: rc-scripts
# Needed for probing the power management features of the host.
Requires: pm-utils
-Requires: systemd-units >= 37-0.10
Requires: udev-libs >= 1:145
Requires: util-linux
Requires: virtual(module-tools)
Requires: xorg-lib-libpciaccess >= 0.10.0
-Requires(post): systemd-units
Requires(post,preun): /sbin/chkconfig
-Requires(postun): systemd-units
-Requires(preun): systemd-units
Suggests: bridge-utils
Suggests: cyrus-sasl
Suggests: cyrus-sasl-digest-md5
Requires: gnutls >= 1.0.25
Requires: netcat-openbsd
Requires: rc-scripts
-Requires(post): systemd-units
Requires(post,preun): /sbin/chkconfig
-Requires(postun): systemd-units
-Requires(preun): systemd-units
%description client
Client binaries needed to access to the virtualization capabilities of
%{?with_static_libs:--enable-static} \
--with-html-dir=%{_gtkdocdir} \
--with-html-subdir=%{name} \
- --with-init-script=systemd+redhat \
- --with-packager="PLD-Linux" \
+ --with-init-script=redhat \
+ --with-packager="TLD-Linux" \
--with-packager-version="%{name}-%{version}-%{release}.%{_target_cpu}" \
--with-qemu-user=qemu \
--with-qemu-group=qemu \
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d} \
- $RPM_BUILD_ROOT%{systemdtmpfilesdir}
+install -d $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d}
%{__make} install \
DEVHELP_DIR=%{_gtkdocdir}/%{name}/devhelp \
- SYSTEMD_UNIT_DIR=%{systemdunitdir} \
DESTDIR=$RPM_BUILD_ROOT
install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/libvirtd
-install %{SOURCE2} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/%{name}.conf
%{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la
%{__rm} $RPM_BUILD_ROOT%{_libdir}/libvirt/connection-driver/*.la \
%{?with_static_libs:$RPM_BUILD_ROOT%{_libdir}/libvirt/lock-driver/*.a}
%endif
-%{__mv} $RPM_BUILD_ROOT%{_localedir}/{eu_ES,eu}
-# duplicate of vi, just one less message translated
-%{__rm} -r $RPM_BUILD_ROOT%{_localedir}/vi_VN
-
%find_lang %{name}
%clean
%post daemon
/sbin/chkconfig --add libvirtd
%service libvirtd restart
-%systemd_post libvirtd.service
%preun daemon
if [ "$1" = "0" ]; then
%service -q libvirtd stop
/sbin/chkconfig --del libvirtd
fi
-%systemd_preun libvirtd.service
%postun daemon
-%systemd_reload
%post client
/sbin/chkconfig --add libvirt-guests
%service -n libvirt-guests restart
NORESTART=1
-%systemd_post libvirt-guests.service
%preun client
-%systemd_preun libvirt-guests.service
if [ "$1" = "0" ]; then
%service -q libvirt-guests stop
/sbin/chkconfig --del libvirt-guests
fi
%postun client
-%systemd_reload
%files -f %{name}.lang
%defattr(644,root,root,755)
%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/virtlockd
%attr(754,root,root) /etc/rc.d/init.d/libvirtd
%attr(754,root,root) /etc/rc.d/init.d/virtlockd
-%{systemdunitdir}/libvirtd.service
-%{systemdunitdir}/libvirtd.socket
-%{systemdunitdir}/virtlockd.service
-%{systemdunitdir}/virtlockd.socket
%config(noreplace) %verify(not md5 mtime size) /usr/lib/sysctl.d/libvirtd.conf
%config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/libvirtd
%attr(755,root,root) %{_libdir}/libvirt_iohelper
%attr(711,root,root) %dir /var/cache/libvirt
%dir /var/run/libvirt
%dir /var/run/libvirt/network
-%{systemdtmpfilesdir}/%{name}.conf
%attr(755,root,root) %{_libexecdir}/libvirt_leaseshelper
%dir %{_libdir}/libvirt/connection-driver
%{_datadir}/libvirt/cpu_map.xml
%attr(755,root,root) %{_libdir}/libvirt/connection-driver/libvirt_driver_secret.so
%attr(755,root,root) %{_libdir}/libvirt/connection-driver/libvirt_driver_storage.so
%attr(755,root,root) %{_libdir}/libvirt/connection-driver/libvirt_driver_vbox.so
-%attr(755,root,root) %{_libdir}/libvirt/connection-driver/libvirt_driver_vbox_network.so
-%attr(755,root,root) %{_libdir}/libvirt/connection-driver/libvirt_driver_vbox_storage.so
%dir %{_libdir}/libvirt/lock-driver
%attr(755,root,root) %{_libdir}/libvirt/lock-driver/lockd.so
%defattr(644,root,root,755)
%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/libvirt-guests
%attr(754,root,root) /etc/rc.d/init.d/libvirt-guests
-%{systemdunitdir}/libvirt-guests.service
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/libvirt/virt-login-shell.conf
%attr(755,root,root) %{_bindir}/virsh
%attr(755,root,root) %{_bindir}/virt-host-validate