Push RPM deps down into libvirt-daemon-driver-XXXX sub-RPMs

For inexplicable reasons, many of the 3rd party package deps
were left against the 'libvirt-daemon' RPM when the drivers
were split out. This makes a minimal install heavier that
it should be. Push them all down into libvirt-daemon-driver-XXX
so they're only pulled in when truly needed

With this change applied, a minimal install of just the
libvirt-daemon-driver-lxc RPM is reduced by 41 MB on a
Fedora 19 host.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
Daniel P. Berrange 2013-10-29 11:27:45 +00:00
parent b51038a4cd
commit 23142ac91a

View File

@ -657,31 +657,6 @@ Requires: avahi
Requires: avahi-libs Requires: avahi-libs
%endif %endif
%endif %endif
%if %{with_network}
Requires: dnsmasq >= 2.41
Requires: radvd
%endif
%if %{with_network} || %{with_nwfilter}
Requires: iptables
Requires: iptables-ipv6
%endif
%if %{with_nwfilter}
Requires: ebtables
%endif
%if %{with_netcf} && (0%{?fedora} >= 18 || 0%{?rhel} >= 7)
Requires: netcf-libs >= 0.2.2
%endif
# needed for device enumeration
%if %{with_hal}
Requires: hal
%endif
%if %{with_udev}
%if 0%{?fedora} >= 18 || 0%{?rhel} >= 7
Requires: systemd >= 185
%else
Requires: udev >= 145
%endif
%endif
%if %{with_polkit} %if %{with_polkit}
%if 0%{?fedora} >= 12 || 0%{?rhel} >=6 %if 0%{?fedora} >= 12 || 0%{?rhel} >=6
Requires: polkit >= 0.93 Requires: polkit >= 0.93
@ -689,50 +664,6 @@ Requires: polkit >= 0.93
Requires: PolicyKit >= 0.6 Requires: PolicyKit >= 0.6
%endif %endif
%endif %endif
%if %{with_storage_fs}
Requires: nfs-utils
# For mkfs
Requires: util-linux
# For glusterfs
%if 0%{?fedora} >= 11
Requires: glusterfs-client >= 2.0.1
%endif
%endif
%if %{with_qemu}
# From QEMU RPMs
Requires: /usr/bin/qemu-img
# For image compression
Requires: gzip
Requires: bzip2
Requires: lzop
Requires: xz
%else
%if %{with_xen}
# From Xen RPMs
Requires: /usr/sbin/qcow-create
%endif
%endif
%if %{with_storage_lvm}
# For LVM drivers
Requires: lvm2
%endif
%if %{with_storage_iscsi}
# For ISCSI driver
Requires: iscsi-initiator-utils
%endif
%if %{with_storage_disk}
# For disk driver
Requires: parted
Requires: device-mapper
%endif
%if %{with_storage_mpath}
# For multipath support
Requires: device-mapper
%endif
%if %{with_storage_sheepdog}
# For Sheepdog support
Requires: sheepdog
%endif
%if %{with_cgconfig} %if %{with_cgconfig}
Requires: libcgroup Requires: libcgroup
%endif %endif
@ -788,6 +719,10 @@ Network filter configuration files for cleaning guest traffic
Summary: Network driver plugin for the libvirtd daemon Summary: Network driver plugin for the libvirtd daemon
Group: Development/Libraries Group: Development/Libraries
Requires: libvirt-daemon = %{version}-%{release} Requires: libvirt-daemon = %{version}-%{release}
Requires: dnsmasq >= 2.41
Requires: radvd
Requires: iptables
Requires: iptables-ipv6
%description daemon-driver-network %description daemon-driver-network
The network driver plugin for the libvirtd daemon, providing The network driver plugin for the libvirtd daemon, providing
@ -801,6 +736,9 @@ bridge capabilities.
Summary: Nwfilter driver plugin for the libvirtd daemon Summary: Nwfilter driver plugin for the libvirtd daemon
Group: Development/Libraries Group: Development/Libraries
Requires: libvirt-daemon = %{version}-%{release} Requires: libvirt-daemon = %{version}-%{release}
Requires: iptables
Requires: iptables-ipv6
Requires: ebtables
%description daemon-driver-nwfilter %description daemon-driver-nwfilter
The nwfilter driver plugin for the libvirtd daemon, providing The nwfilter driver plugin for the libvirtd daemon, providing
@ -814,6 +752,17 @@ iptables and ip6tables capabilities
Summary: Nodedev driver plugin for the libvirtd daemon Summary: Nodedev driver plugin for the libvirtd daemon
Group: Development/Libraries Group: Development/Libraries
Requires: libvirt-daemon = %{version}-%{release} Requires: libvirt-daemon = %{version}-%{release}
# needed for device enumeration
%if %{with_hal}
Requires: hal
%endif
%if %{with_udev}
%if 0%{?fedora} >= 18 || 0%{?rhel} >= 7
Requires: systemd >= 185
%else
Requires: udev >= 145
%endif
%endif
%description daemon-driver-nodedev %description daemon-driver-nodedev
The nodedev driver plugin for the libvirtd daemon, providing The nodedev driver plugin for the libvirtd daemon, providing
@ -827,6 +776,9 @@ capabilities.
Summary: Interface driver plugin for the libvirtd daemon Summary: Interface driver plugin for the libvirtd daemon
Group: Development/Libraries Group: Development/Libraries
Requires: libvirt-daemon = %{version}-%{release} Requires: libvirt-daemon = %{version}-%{release}
%if %{with_netcf} && (0%{?fedora} >= 18 || 0%{?rhel} >= 7)
Requires: netcf-libs >= 0.2.2
%endif
%description daemon-driver-interface %description daemon-driver-interface
The interface driver plugin for the libvirtd daemon, providing The interface driver plugin for the libvirtd daemon, providing
@ -850,6 +802,45 @@ an implementation of the secret key APIs.
Summary: Storage driver plugin for the libvirtd daemon Summary: Storage driver plugin for the libvirtd daemon
Group: Development/Libraries Group: Development/Libraries
Requires: libvirt-daemon = %{version}-%{release} Requires: libvirt-daemon = %{version}-%{release}
%if %{with_storage_fs}
Requires: nfs-utils
# For mkfs
Requires: util-linux
# For glusterfs
%if 0%{?fedora} >= 11
Requires: glusterfs-client >= 2.0.1
%endif
%endif
%if %{with_storage_lvm}
# For LVM drivers
Requires: lvm2
%endif
%if %{with_storage_iscsi}
# For ISCSI driver
Requires: iscsi-initiator-utils
%endif
%if %{with_storage_disk}
# For disk driver
Requires: parted
Requires: device-mapper
%endif
%if %{with_storage_mpath}
# For multipath support
Requires: device-mapper
%endif
%if %{with_storage_sheepdog}
# For Sheepdog support
Requires: sheepdog
%endif
%if %{with_qemu}
# From QEMU RPMs
Requires: /usr/bin/qemu-img
%else
%if %{with_xen}
# From Xen RPMs
Requires: /usr/sbin/qcow-create
%endif
%endif
%description daemon-driver-storage %description daemon-driver-storage
The storage driver plugin for the libvirtd daemon, providing The storage driver plugin for the libvirtd daemon, providing
@ -865,6 +856,12 @@ Group: Development/Libraries
Requires: libvirt-daemon = %{version}-%{release} Requires: libvirt-daemon = %{version}-%{release}
# There really is a hard cross-driver dependency here # There really is a hard cross-driver dependency here
Requires: libvirt-daemon-driver-network = %{version}-%{release} Requires: libvirt-daemon-driver-network = %{version}-%{release}
Requires: /usr/bin/qemu-img
# For image compression
Requires: gzip
Requires: bzip2
Requires: lzop
Requires: xz
%description daemon-driver-qemu %description daemon-driver-qemu
The qemu driver plugin for the libvirtd daemon, providing The qemu driver plugin for the libvirtd daemon, providing