mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-01 17:35:17 +00:00
Enable udev instead of hal on F12 / RHEL-6 or later
HAL has been deprecated since F12 and RHEL-6, so if building on these platforms, switch on the udev driver instead * libvirt.spec.in: Activate udev on F12/RHEL6
This commit is contained in:
parent
eb81396863
commit
4811fab790
@ -53,12 +53,13 @@
|
|||||||
%define with_storage_mpath 0%{!?_without_storage_mpath:%{server_drivers}}
|
%define with_storage_mpath 0%{!?_without_storage_mpath:%{server_drivers}}
|
||||||
%define with_numactl 0%{!?_without_numactl:%{server_drivers}}
|
%define with_numactl 0%{!?_without_numactl:%{server_drivers}}
|
||||||
%define with_selinux 0%{!?_without_selinux:%{server_drivers}}
|
%define with_selinux 0%{!?_without_selinux:%{server_drivers}}
|
||||||
%define with_hal 0%{!?_without_hal:%{server_drivers}}
|
|
||||||
|
|
||||||
# A few optional bits off by default, we enable later
|
# A few optional bits off by default, we enable later
|
||||||
%define with_polkit 0%{!?_without_polkit:0}
|
%define with_polkit 0%{!?_without_polkit:0}
|
||||||
%define with_capng 0%{!?_without_capng:0}
|
%define with_capng 0%{!?_without_capng:0}
|
||||||
%define with_netcf 0%{!?_without_netcf:0}
|
%define with_netcf 0%{!?_without_netcf:0}
|
||||||
|
%define with_udev 0%{!?_without_udev:0}
|
||||||
|
%define with_hal 0%{!?_without_hal:0}
|
||||||
|
|
||||||
# Non-server/HV driver defaults which are always enabled
|
# Non-server/HV driver defaults which are always enabled
|
||||||
%define with_python 0%{!?_without_python:1}
|
%define with_python 0%{!?_without_python:1}
|
||||||
@ -133,6 +134,13 @@
|
|||||||
%define with_netcf 0%{!?_without_netcf:%{server_drivers}}
|
%define with_netcf 0%{!?_without_netcf:%{server_drivers}}
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
# udev is used to manage host devices in Fedora 12 / RHEL-6 or newer
|
||||||
|
%if 0%{?fedora} >= 12 || 0%{?rhel} >= 6
|
||||||
|
%define with_udev 0%{!?_without_udev:%{server_drivers}}
|
||||||
|
%else
|
||||||
|
%define with_hal 0%{!?_without_hal:%{server_drivers}}
|
||||||
|
%endif
|
||||||
|
|
||||||
# Force QEMU to run as non-root
|
# Force QEMU to run as non-root
|
||||||
%if 0%{?fedora} >= 12 || 0%{?rhel} >= 6
|
%if 0%{?fedora} >= 12 || 0%{?rhel} >= 6
|
||||||
%define qemu_user qemu
|
%define qemu_user qemu
|
||||||
@ -179,6 +187,9 @@ Requires: iptables
|
|||||||
%if %{with_hal}
|
%if %{with_hal}
|
||||||
Requires: hal
|
Requires: hal
|
||||||
%endif
|
%endif
|
||||||
|
%if %{with_udev}
|
||||||
|
Requires: udev >= 145
|
||||||
|
%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
|
||||||
@ -242,6 +253,10 @@ BuildRequires: gnutls-devel
|
|||||||
%if %{with_hal}
|
%if %{with_hal}
|
||||||
BuildRequires: hal-devel
|
BuildRequires: hal-devel
|
||||||
%endif
|
%endif
|
||||||
|
%if %{with_udev}
|
||||||
|
BuildRequires: libudev-devel >= 145
|
||||||
|
BuildRequires: libpciaccess-devel >= 0.10.9
|
||||||
|
%endif
|
||||||
%if %{with_avahi}
|
%if %{with_avahi}
|
||||||
BuildRequires: avahi-devel
|
BuildRequires: avahi-devel
|
||||||
%endif
|
%endif
|
||||||
@ -476,6 +491,10 @@ of recent versions of Linux (and other OSes).
|
|||||||
%define _without_hal --without-hal
|
%define _without_hal --without-hal
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
%if ! %{with_udev}
|
||||||
|
%define _without_udev --without-udev
|
||||||
|
%endif
|
||||||
|
|
||||||
%configure %{?_without_xen} \
|
%configure %{?_without_xen} \
|
||||||
%{?_without_qemu} \
|
%{?_without_qemu} \
|
||||||
%{?_without_openvz} \
|
%{?_without_openvz} \
|
||||||
@ -502,6 +521,7 @@ of recent versions of Linux (and other OSes).
|
|||||||
%{?_without_netcf} \
|
%{?_without_netcf} \
|
||||||
%{?_without_selinux} \
|
%{?_without_selinux} \
|
||||||
%{?_without_hal} \
|
%{?_without_hal} \
|
||||||
|
%{?_without_udev} \
|
||||||
--with-qemu-user=%{qemu_user} \
|
--with-qemu-user=%{qemu_user} \
|
||||||
--with-qemu-group=%{qemu_group} \
|
--with-qemu-group=%{qemu_group} \
|
||||||
--with-init-script=redhat \
|
--with-init-script=redhat \
|
||||||
|
Loading…
x
Reference in New Issue
Block a user