mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-10-30 18:03:32 +00:00
configure: move network driver check to its own file
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
parent
13b238dc86
commit
bdfb892ba8
24
configure.ac
24
configure.ac
@ -607,26 +607,8 @@ LIBVIRT_DRIVER_CHECK_PHYP
|
|||||||
|
|
||||||
dnl check if the network driver should be compiled
|
dnl check if the network driver should be compiled
|
||||||
|
|
||||||
LIBVIRT_ARG_WITH_ALT([NETWORK], [with virtual network driver], [yes])
|
LIBVIRT_DRIVER_ARG_NETWORK
|
||||||
|
LIBVIRT_DRIVER_CHECK_NETWORK
|
||||||
dnl there's no use compiling the network driver without the libvirt
|
|
||||||
dnl daemon, nor compiling it for MacOS X, where it breaks the compile
|
|
||||||
|
|
||||||
if test "$with_libvirtd" = "no" || test "$with_osx" = "yes"; then
|
|
||||||
with_network=no
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "$with_network" = "yes" ; then
|
|
||||||
AC_DEFINE_UNQUOTED([WITH_NETWORK], 1, [whether network driver is enabled])
|
|
||||||
fi
|
|
||||||
AM_CONDITIONAL([WITH_NETWORK], [test "$with_network" = "yes"])
|
|
||||||
|
|
||||||
with_bridge=no
|
|
||||||
if test "$with_qemu:$with_lxc:$with_network" != "no:no:no"; then
|
|
||||||
with_bridge=yes
|
|
||||||
AC_DEFINE_UNQUOTED([WITH_BRIDGE], 1, [whether bridge code is needed])
|
|
||||||
fi
|
|
||||||
AM_CONDITIONAL([WITH_BRIDGE], [test "$with_bridge" = "yes"])
|
|
||||||
|
|
||||||
|
|
||||||
LIBVIRT_ARG_WITH([SECRETS], [local secrets management driver], [yes])
|
LIBVIRT_ARG_WITH([SECRETS], [local secrets management driver], [yes])
|
||||||
@ -1300,7 +1282,7 @@ LIBVIRT_DRIVER_RESULT_VZ
|
|||||||
LIBVIRT_DRIVER_RESULT_BHYVE
|
LIBVIRT_DRIVER_RESULT_BHYVE
|
||||||
LIBVIRT_DRIVER_RESULT_TEST
|
LIBVIRT_DRIVER_RESULT_TEST
|
||||||
LIBVIRT_DRIVER_RESULT_REMOTE
|
LIBVIRT_DRIVER_RESULT_REMOTE
|
||||||
AC_MSG_NOTICE([ Network: $with_network])
|
LIBVIRT_DRIVER_RESULT_NETWORK
|
||||||
LIBVIRT_DRIVER_RESULT_LIBVIRTD
|
LIBVIRT_DRIVER_RESULT_LIBVIRTD
|
||||||
AC_MSG_NOTICE([Interface: $with_interface])
|
AC_MSG_NOTICE([Interface: $with_interface])
|
||||||
AC_MSG_NOTICE([])
|
AC_MSG_NOTICE([])
|
||||||
|
51
m4/virt-driver-network.m4
Normal file
51
m4/virt-driver-network.m4
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
dnl The network driver
|
||||||
|
dnl
|
||||||
|
dnl Copyright (C) 2016 Red Hat, Inc.
|
||||||
|
dnl
|
||||||
|
dnl This library is free software; you can redistribute it and/or
|
||||||
|
dnl modify it under the terms of the GNU Lesser General Public
|
||||||
|
dnl License as published by the Free Software Foundation; either
|
||||||
|
dnl version 2.1 of the License, or (at your option) any later version.
|
||||||
|
dnl
|
||||||
|
dnl This library is distributed in the hope that it will be useful,
|
||||||
|
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
dnl Lesser General Public License for more details.
|
||||||
|
dnl
|
||||||
|
dnl You should have received a copy of the GNU Lesser General Public
|
||||||
|
dnl License along with this library. If not, see
|
||||||
|
dnl <http://www.gnu.org/licenses/>.
|
||||||
|
dnl
|
||||||
|
|
||||||
|
AC_DEFUN([LIBVIRT_DRIVER_ARG_NETWORK], [
|
||||||
|
LIBVIRT_ARG_WITH_ALT([NETWORK], [with virtual network driver], [yes])
|
||||||
|
])
|
||||||
|
|
||||||
|
AC_DEFUN([LIBVIRT_DRIVER_CHECK_NETWORK], [
|
||||||
|
AC_REQUIRE([LIBVIRT_DRIVER_CHECK_LIBVIRTD])
|
||||||
|
AC_REQUIRE([LIBVIRT_DRIVER_CHECK_QEMU])
|
||||||
|
AC_REQUIRE([LIBVIRT_DRIVER_CHECK_LXC])
|
||||||
|
|
||||||
|
dnl there's no use compiling the network driver without the libvirt
|
||||||
|
dnl daemon, nor compiling it for MacOS X, where it breaks the compile
|
||||||
|
|
||||||
|
if test "$with_libvirtd" = "no" || test "$with_osx" = "yes"; then
|
||||||
|
with_network=no
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "$with_network" = "yes" ; then
|
||||||
|
AC_DEFINE_UNQUOTED([WITH_NETWORK], 1, [whether network driver is enabled])
|
||||||
|
fi
|
||||||
|
AM_CONDITIONAL([WITH_NETWORK], [test "$with_network" = "yes"])
|
||||||
|
|
||||||
|
with_bridge=no
|
||||||
|
if test "$with_qemu:$with_lxc:$with_network" != "no:no:no"; then
|
||||||
|
with_bridge=yes
|
||||||
|
AC_DEFINE_UNQUOTED([WITH_BRIDGE], 1, [whether bridge code is needed])
|
||||||
|
fi
|
||||||
|
AM_CONDITIONAL([WITH_BRIDGE], [test "$with_bridge" = "yes"])
|
||||||
|
])
|
||||||
|
|
||||||
|
AC_DEFUN([LIBVIRT_DRIVER_RESULT_NETWORK], [
|
||||||
|
LIBVIRT_RESULT([Network], [$with_network])
|
||||||
|
])
|
Loading…
Reference in New Issue
Block a user