~serge-hallyn/ubuntu/raring/libvirt/libvirt-hugepages

« back to all changes in this revision

Viewing changes to configure.ac

  • Committer: Package Import Robot
  • Author(s): Chuck Short
  • Date: 2012-07-11 12:37:49 UTC
  • mfrom: (1.2.14)
  • Revision ID: package-import@ubuntu.com-20120711123749-gt314clvb7840c6p
Tags: 0.9.13-0ubuntu1
* New upstream version: 
* debian/rules: Remove .la files
* debian/control: Dropped debian vcs info.
* Dropped:
  - debian/paches/9022-pass-the-virt-driver-name-into-security-drivers:
    Already applied upstream.
  - debian/patches/9023-dont-enable-apparmor-driver-with-lxc
    Already applied upstream.
  - debian/patches/9024-initialize-random-generator-in-lxc:
    Already applied upstream.
* Re-diffed:
  - debian/patches/9002-better_default_uri_virsh.patch
* Added:
  - debian/patches/add-libvirt-highbank-support.patch: Add highbank 
    CPU detection support.
  - debian/patches/fix-lxc-container-unmounting.patch: Fix container
    mounting.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
dnl Copyright (C) 2005-2012 Red Hat, Inc.
4
4
dnl See COPYING.LIB for the License of this software
5
5
 
6
 
AC_INIT([libvirt], [0.9.12], [libvir-list@redhat.com], [], [http://libvirt.org])
 
6
AC_INIT([libvirt], [0.9.13], [libvir-list@redhat.com], [], [http://libvirt.org])
7
7
AC_CONFIG_SRCDIR([src/libvirt.c])
8
8
AC_CONFIG_AUX_DIR([build-aux])
9
9
AC_CONFIG_HEADERS([config.h])
80
80
AC_PROG_CC
81
81
AC_PROG_INSTALL
82
82
AC_PROG_CPP
83
 
AM_PROG_CC_STDC
84
83
 
85
84
gl_EARLY
86
85
gl_INIT
158
157
AC_CHECK_HEADERS([pwd.h paths.h regex.h sys/un.h \
159
158
  sys/poll.h syslog.h mntent.h net/ethernet.h linux/magic.h \
160
159
  sys/un.h sys/syscall.h netinet/tcp.h ifaddrs.h libtasn1.h \
161
 
  net/if.h])
 
160
  net/if.h execinfo.h])
162
161
 
163
162
AC_MSG_CHECKING([for struct ifreq in net/if.h])
164
163
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
369
368
AC_ARG_WITH([init-script],
370
369
            [AC_HELP_STRING([--with-init-script@<:@=STYLE@:>@],
371
370
                            [Style of init script to install: redhat, systemd, systemd+redhat,
372
 
                             upstart, auto, none @<:@default=auto@:>@])],[],[with_init_script=check])
 
371
                             upstart, check, none @<:@default=check@:>@])],[],[with_init_script=check])
373
372
init_redhat=no
374
373
init_systemd=no
375
374
init_upstart=no
408
407
AC_MSG_CHECKING([for whether to install sysctl config])
409
408
AC_ARG_WITH([sysctl],
410
409
            [AC_HELP_STRING([--with-sysctl@<:@=yes/no@:>@],
411
 
                            [Whether to install sysctl configs @<:@default=auto@:>@])],
 
410
                            [Whether to install sysctl configs @<:@default=check@:>@])],
412
411
                            [],[with_sysctl=check])
413
412
 
414
413
if test "$with_sysctl" = "yes" || test "$with_sysctl" = "check"
555
554
                   [Location of directory containing VirtualBox XPCOMC library])
556
555
 
557
556
if test "x$with_vbox" = "xyes"; then
558
 
    case "$host" in
559
 
      *-*-mingw* | *-*-msvc*) MSCOM_LIBS="-lole32 -loleaut32" ;;
560
 
      *) MSCOM_LIBS= ;;
561
 
    esac
562
 
    AC_SUBST([MSCOM_LIBS])
563
 
 
564
557
    AC_DEFINE_UNQUOTED([WITH_VBOX], 1, [whether VirtualBox driver is enabled])
565
558
fi
566
559
AM_CONDITIONAL([WITH_VBOX], [test "$with_vbox" = "yes"])
998
991
  [],
999
992
  [with_yajl=check])
1000
993
 
 
994
if test "$with_qemu:$with_yajl" = yes:check; then
 
995
  dnl Some versions of qemu require the use of yajl; try to detect them
 
996
  dnl here, although we do not require qemu to exist in order to compile.
 
997
  dnl This check mirrors src/qemu/qemu_capabilities.c
 
998
  AC_PATH_PROGS([QEMU], [qemu-kvm qemu kvm qemu-system-x86_64],
 
999
                [], [$PATH:/usr/bin:/usr/libexec])
 
1000
  if test -x "$QEMU"; then
 
1001
    if `$QEMU -help | grep libvirt` >/dev/null; then
 
1002
      with_yajl=yes
 
1003
    else
 
1004
      [qemu_version_sed='s/.*ersion \([0-9.,]*\).*/\1/']
 
1005
      qemu_version=`$QEMU -version | sed "$qemu_version_sed"`
 
1006
      AS_VERSION_COMPARE([$qemu_version], [0.15],
 
1007
                         [], [with_yajl=yes], [with_yajl=yes])
 
1008
    fi
 
1009
  fi
 
1010
fi
 
1011
 
1001
1012
YAJL_CFLAGS=
1002
1013
YAJL_LIBS=
1003
1014
with_yajl2=no
1128
1139
  LIBS="$save_LIBS"
1129
1140
  CFLAGS="$save_CFLAGS"
1130
1141
fi
 
1142
AM_CONDITIONAL([HAVE_DBUS], [test "$have_dbus" = "yes"])
1131
1143
 
1132
1144
 
1133
1145
dnl PolicyKit library
1360
1372
  fail=0
1361
1373
  AC_CHECK_FUNC([selinux_virtual_domain_context_path], [], [fail=1])
1362
1374
  AC_CHECK_FUNC([selinux_virtual_image_context_path], [], [fail=1])
 
1375
  AC_CHECK_FUNCS([selinux_lxc_contexts_path])
1363
1376
  CFLAGS="$old_cflags"
1364
1377
  LIBS="$old_libs"
1365
1378
 
1810
1823
  AC_HELP_STRING([--with-storage-mpath], [with mpath backend for the storage driver @<:@default=check@:>@]),[],[with_storage_mpath=check])
1811
1824
AC_ARG_WITH([storage-disk],
1812
1825
  AC_HELP_STRING([--with-storage-disk], [with GPartd Disk backend for the storage driver @<:@default=check@:>@]),[],[with_storage_disk=check])
 
1826
AC_ARG_WITH([storage-rbd],
 
1827
  AC_HELP_STRING([--with-storage-rbd], [with RADOS Block Device backend for the storage driver @<:@default=check@:>@]),[],[with_storage_rbd=check])
1813
1828
 
1814
1829
if test "$with_libvirtd" = "no"; then
1815
1830
  with_storage_dir=no
1819
1834
  with_storage_scsi=no
1820
1835
  with_storage_mpath=no
1821
1836
  with_storage_disk=no
 
1837
  with_storage_rbd=no
1822
1838
fi
1823
1839
if test "$with_storage_dir" = "yes" ; then
1824
1840
  AC_DEFINE_UNQUOTED([WITH_STORAGE_DIR], 1, [whether directory backend for storage driver is enabled])
1977
1993
fi
1978
1994
AM_CONDITIONAL([WITH_STORAGE_MPATH], [test "$with_storage_mpath" = "yes"])
1979
1995
 
 
1996
LIBRBD_LIBS=
 
1997
if test "$with_storage_rbd" = "yes" || test "$with_storage_rbd" = "check"; then
 
1998
    AC_CHECK_HEADER([rbd/librbd.h], [LIBRBD_FOUND=yes; break;])
 
1999
 
 
2000
    if test "$LIBRBD_FOUND" = "yes"; then
 
2001
        with_storage_rbd=yes
 
2002
        LIBRBD_LIBS="-lrbd -lrados -lcrypto"
 
2003
        AC_DEFINE_UNQUOTED([WITH_STORAGE_RBD], [1],
 
2004
         [whether RBD backend for storage driver is enabled])
 
2005
    else
 
2006
        with_storage_rbd=no
 
2007
    fi
 
2008
fi
 
2009
AM_CONDITIONAL([WITH_STORAGE_RBD], [test "$with_storage_rbd" = "yes"])
 
2010
AC_SUBST([LIBRBD_LIBS])
 
2011
 
1980
2012
LIBPARTED_CFLAGS=
1981
2013
LIBPARTED_LIBS=
1982
2014
if test "$with_storage_disk" = "yes" ||
2062
2094
AC_SUBST([DEVMAPPER_CFLAGS])
2063
2095
AC_SUBST([DEVMAPPER_LIBS])
2064
2096
 
 
2097
with_storage=no
 
2098
for backend in dir fs lvm iscsi scsi mpath rbd disk; do
 
2099
    if eval test \$with_storage_$backend = yes; then
 
2100
        with_storage=yes
 
2101
        break
 
2102
    fi
 
2103
done
 
2104
if test $with_storage = yes; then
 
2105
    AC_DEFINE([WITH_STORAGE], [1],
 
2106
      [Define to 1 if at least one storage backend is in use])
 
2107
fi
 
2108
AM_CONDITIONAL([WITH_STORAGE], [test "$with_storage" = "yes"])
 
2109
 
2065
2110
dnl
2066
2111
dnl check for libcurl (ESX/XenAPI)
2067
2112
dnl
2229
2274
AC_SUBST([PYTHON_VERSION])
2230
2275
AC_SUBST([PYTHON_INCLUDES])
2231
2276
 
 
2277
dnl Allow perl overrides
 
2278
AC_PATH_PROG([PERL], [perl])
 
2279
 
2232
2280
AC_ARG_ENABLE([with-test-suite],
2233
2281
              AC_HELP_STRING([--with-test-suite], [build test suite by default @<:@default=check@:>@]),
2234
2282
              [case "${withval}" in
2344
2392
WIN32_EXTRA_CFLAGS=
2345
2393
LIBVIRT_SYMBOL_FILE=libvirt.syms
2346
2394
LIBVIRT_QEMU_SYMBOL_FILE='$(srcdir)/libvirt_qemu.syms'
 
2395
MSCOM_LIBS=
2347
2396
case "$host" in
2348
2397
  *-*-cygwin*)
2349
2398
    CYGWIN_EXTRA_LDFLAGS="-no-undefined"
2350
2399
    CYGWIN_EXTRA_LIBADD="${INTLLIBS}"
 
2400
    MSCOM_LIBS="-lole32 -loleaut32"
 
2401
 
2351
2402
    if test "x$PYTHON_VERSION" != "x"; then
2352
2403
      CYGWIN_EXTRA_PYTHON_LIBADD="-L/usr/lib/python${PYTHON_VERSION}/config -lpython${PYTHON_VERSION}"
2353
2404
    fi
2354
2405
    ;;
2355
2406
  *-*-mingw*)
2356
2407
    MINGW_EXTRA_LDFLAGS="-no-undefined"
 
2408
    MSCOM_LIBS="-lole32 -loleaut32"
 
2409
    ;;
 
2410
  *-*-msvc*)
 
2411
    MSCOM_LIBS="-lole32 -loleaut32"
2357
2412
    ;;
2358
2413
esac
2359
2414
case "$host" in
2386
2441
AC_SUBST([LIBVIRT_SYMBOL_FILE])
2387
2442
AC_SUBST([LIBVIRT_QEMU_SYMBOL_FILE])
2388
2443
AC_SUBST([VERSION_SCRIPT_FLAGS])
 
2444
AC_SUBST([MSCOM_LIBS])
2389
2445
 
2390
2446
 
2391
2447
dnl Look for windres to build a Windows icon resource.
2399
2455
 
2400
2456
dnl Driver-Modules library
2401
2457
AC_ARG_WITH([driver-modules],
2402
 
  AC_HELP_STRING([--with-driver-modules], [build drivers as loadable modules @<:@default=no@:>@]),
 
2458
  AC_HELP_STRING([--with-driver-modules],
 
2459
  [build drivers as loadable modules @<:@default=check@:>@]),
2403
2460
  [],
2404
 
  [with_driver_modules=no])
 
2461
  [with_driver_modules=check])
 
2462
 
 
2463
if test "$with_libvirtd" = "no" ; then
 
2464
  with_driver_modules=no
 
2465
fi
2405
2466
 
2406
2467
DRIVER_MODULE_CFLAGS=
2407
2468
DRIVER_MODULE_LIBS=
2408
 
if test "$with_driver_modules" = "yes"; then
 
2469
if test "$with_driver_modules" = "yes" || test "$with_driver_modules" = "check"; then
2409
2470
  if test "$dlfcn_found" != "yes" || test "$dlopen_found" != "yes"; then
2410
 
    AC_MSG_ERROR([You must have dlfcn.h / dlopen() support to build driver modules])
 
2471
    if test "$with_driver_modules" = "yes" ; then
 
2472
      AC_MSG_ERROR([You must have dlfcn.h / dlopen() support to build driver modules])
 
2473
    else
 
2474
      with_driver_modules=no
 
2475
    fi
 
2476
  else
 
2477
    with_driver_modules=yes
2411
2478
  fi
 
2479
fi
 
2480
 
 
2481
if test "$with_driver_modules" = "yes" ; then
2412
2482
  DRIVER_MODULE_CFLAGS="-export-dynamic"
2413
2483
  case $ac_cv_search_dlopen in
2414
2484
    no*) DRIVER_MODULE_LIBS= ;;
2700
2770
          docs/schemas/Makefile \
2701
2771
          gnulib/lib/Makefile \
2702
2772
          gnulib/tests/Makefile \
2703
 
          libvirt.pc libvirt.spec mingw32-libvirt.spec \
 
2773
          libvirt.pc libvirt.spec mingw-libvirt.spec \
2704
2774
          po/Makefile.in \
2705
2775
          include/libvirt/Makefile include/libvirt/libvirt.h \
2706
2776
          python/Makefile python/tests/Makefile \
2753
2823
AC_MSG_NOTICE([    SCSI: $with_storage_scsi])
2754
2824
AC_MSG_NOTICE([   mpath: $with_storage_mpath])
2755
2825
AC_MSG_NOTICE([    Disk: $with_storage_disk])
 
2826
AC_MSG_NOTICE([     RBD: $with_storage_rbd])
2756
2827
AC_MSG_NOTICE([])
2757
2828
AC_MSG_NOTICE([Security Drivers])
2758
2829
AC_MSG_NOTICE([])