1. 13 12月, 2012 2 次提交
  2. 12 12月, 2012 1 次提交
  3. 11 12月, 2012 1 次提交
    • D
      parallels: add network driver · 6034ce31
      Dmitry Guryanov 提交于
      Parallels Cloud Server uses virtual networks model for network
      configuration. It uses own tools for virtual network management.
      So add network driver, which will be responsible for listing
      virtual networks and performing different operations on them
      (in consequent patched).
      
      This patch only allows listing virtual network names, without
      any parameters like DHCP server settings.
      Signed-off-by: NDmitry Guryanov <dguryanov@parallels.com>
      6034ce31
  4. 05 12月, 2012 1 次提交
    • B
      implement managedsave in libvirt xen legacy driver · 501bfad1
      Bamvor Jian Zhang 提交于
      Implement the domainManagedSave, domainHasManagedSaveImage, and
      domainManagedSaveRemove functions in the libvirt legacy xen driver.
      
      domainHasManagedSaveImage check the managedsave image from filesystem
      everytime. This is different from qemu and libxl driver. In qemu or
      libxl driver, there is a hasManagesSave flag in virDomainObjPtr which
      is not used in xen legacy driver. This flag could not add into xen
      driver ptr either, because the driver ptr will be released at the end of
      every libvirt api call. Meanwhile, AFAIK, xen store all the flags in
      xen not in libvirt xen driver. There is no need to add this flag in xen.
      Signed-off-by: NBamvor Jian Zhang <bjzhang@suse.com>
      501bfad1
  5. 04 12月, 2012 2 次提交
    • D
      Replace polling for active VMs with signalling by drivers · 79b8a569
      Daniel P. Berrange 提交于
      Currently to deal with auto-shutdown libvirtd must periodically
      poll all stateful drivers. Thus sucks because it requires
      acquiring both the driver lock and locks on every single virtual
      machine. Instead pass in a "inhibit" callback to virStateInitialize
      which drivers can invoke whenever they want to inhibit shutdown
      due to existance of active VMs.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      79b8a569
    • A
      Add iSCSI backend storage driver for ESX · 60f0f55e
      Ata E Husain Bohra 提交于
      The patch adds the backend driver to support iSCSI format storage pools
      and volumes for ESX host. The mapping of ESX iSCSI specifics to Libvirt
      is as follows:
      
      1. ESX static iSCSI target <------> Libvirt Storage Pools
      2. ESX iSCSI LUNs          <------> Libvirt Storage Volumes.
      
      The above understanding is based on http://libvirt.org/storage.html.
      
      The operation supported on iSCSI pools includes:
      
      1. List storage pools & volumes.
      2. Get XML descriptor operaion on pools & volumes.
      3. Lookup operation on pools & volumes by name, UUID and path (if applicable).
      
      iSCSI pools does not support operations such as: Create / remove pools
      and volumes.
      60f0f55e
  6. 01 12月, 2012 2 次提交
  7. 28 11月, 2012 1 次提交
    • G
      add fuse support for libvirt lxc · 2a596dac
      Gao feng 提交于
      this patch addes fuse support for libvirt lxc.
      we can use fuse filesystem to generate sysinfo dynamically,
      So we can isolate /proc/meminfo,cpuinfo and so on through
      fuse filesystem.
      
      we mount fuse filesystem for every container.
      the mount name is libvirt,mount point is
      localstatedir/run/libvirt/lxc/containername.
      Signed-off-by: NGao feng <gaofeng@cn.fujitsu.com>
      2a596dac
  8. 27 11月, 2012 1 次提交
    • A
      Refactor ESX storage driver to implement facade pattern · 067e83eb
      Ata E Husain Bohra 提交于
      The patch refactors the current ESX storage driver due to following reasons:
      
      1. Given most of the public APIs exposed by the storage driver in Libvirt
      remains same, ESX storage driver should not implement logic specific
      for only one supported format (current implementation only supports VMFS).
      2. Decoupling interface from specific storage implementation gives us an
      extensible design to hook implementation for other supported storage
      formats.
      
      This patch refactors the current driver to implement it as a facade pattern i.e.
      the driver exposes all the public libvirt APIs, but uses backend drivers to get
      the required task done. The backend drivers provide implementation specific to
      the type of storage device.
      
      File changes:
      ------------------
      esx_storage_driver.c ----> esx_storage_driver.c (base storage driver)
                           |
                           |---> esx_storage_backend_vmfs.c (VMFS backend)
      067e83eb
  9. 30 10月, 2012 1 次提交
    • E
      build: fix linking with systemtap probes · a047a24d
      Eric Blake 提交于
      Commit 34e8f63a altered virfile.o to drag in additional symbols,
      which in turn led to pulling in other .o files and eventually causing
      a link failure when systemtap probes are enabled, such as:
      
      ./.libs/libvirt_util.a(libvirt_util_la-event_poll.o): In function `virEventPollRunOnce':
      /home/dummy/libvirt/src/util/event_poll.c:614: undefined reference to `libvirt_event_poll_run_semaphore'
      ./.libs/libvirt_util.a(libvirt_util_la-event_poll.o):(.note.stapsdt+0x24): undefined reference to `libvirt_event_poll_add_handle_semaphore'
      
      Even though libvirt_iohelper and libvirt_parthelper don't directly
      use the portion of virfile.o that drags in probing, it was easier
      to satisfy the linker and get the build back up, than to figure out
      whether it is even possible or worth trying to disentangle the mess.
      
      * src/Makefile.am (libvirt_iohelper_LDADD)
      (libvirt_parthelper_LDADD): Use libvirt_probes.lo when needed.
      a047a24d
  10. 18 10月, 2012 1 次提交
  11. 16 10月, 2012 1 次提交
    • D
      Introduce an internal API for handling file based lockspaces · eca72d47
      Daniel P. Berrange 提交于
      The previously introduced virFile{Lock,Unlock} APIs provide a
      way to acquire/release fcntl() locks on individual files. For
      unknown reason though, the POSIX spec says that fcntl() locks
      are released when *any* file handle referring to the same path
      is closed. In the following sequence
      
        threadA: fd1 = open("foo")
        threadB: fd2 = open("foo")
        threadA: virFileLock(fd1)
        threadB: virFileLock(fd2)
        threadB: close(fd2)
      
      you'd expect threadA to come out holding a lock on 'foo', and
      indeed it does hold a lock for a very short time. Unfortunately
      when threadB does close(fd2) this releases the lock associated
      with fd1. For the current libvirt use case for virFileLock -
      pidfiles - this doesn't matter since the lock is acquired
      at startup while single threaded an never released until
      exit.
      
      To provide a more generally useful API though, it is necessary
      to introduce a slightly higher level abstraction, which is to
      be referred to as a "lockspace".  This is to be provided by
      a virLockSpacePtr object in src/util/virlockspace.{c,h}. The
      core idea is that the lockspace keeps track of what files are
      already open+locked. This means that when a 2nd thread comes
      along and tries to acquire a lock, it doesn't end up opening
      and closing a new FD. The lockspace just checks the current
      list of held locks and immediately returns VIR_ERR_RESOURCE_BUSY.
      
      NB, the API as it stands is designed on the basis that the
      files being locked are not being otherwise opened and used
      by the application code. One approach to using this API is to
      acquire locks based on a hash of the filepath.
      
      eg to lock /var/lib/libvirt/images/foo.img the application
      might do
      
         virLockSpacePtr lockspace = virLockSpaceNew("/var/lib/libvirt/imagelocks");
         lockname = md5sum("/var/lib/libvirt/images/foo.img");
         virLockSpaceAcquireLock(lockspace, lockname);
      
      NB, in this example, the caller should ensure that the path
      is canonicalized before calculating the checksum.
      
      It is also possible to do locks directly on resources by
      using a NULL lockspace directory and then using the file
      path as the lock name eg
      
         virLockSpacePtr lockspace = virLockSpaceNew(NULL);
         virLockSpaceAcquireLock(lockspace, "/var/lib/libvirt/images/foo.img");
      
      This is only safe to do though if no other part of the process
      will be opening the files. This will be the case when this
      code is used inside the soon-to-be-reposted virlockd daemon
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      eca72d47
  12. 11 10月, 2012 2 次提交
    • J
      locking: Implement lock failure action in sanlock driver · 89364767
      Jiri Denemark 提交于
      While the changes to sanlock driver should be stable, the actual
      implementation of sanlock_helper is supposed to be replaced in the
      future. However, before we can implement a better sanlock_helper, we
      need an administrative interface to libvirtd so that the helper can just
      pass a "leases lost" event to the particular libvirt driver and
      everything else will be taken care of internally. This approach will
      also allow libvirt to pass such event to applications and use
      appropriate reasons when changing domain states.
      
      The temporary implementation handles all actions directly by calling
      appropriate libvirt APIs (which among other things means that it needs
      to know the credentials required to connect to libvirtd).
      89364767
    • J
      locking: Add support for lock failure action · 297c704a
      Jiri Denemark 提交于
      297c704a
  13. 09 10月, 2012 2 次提交
    • D
      interface: always build all available backends · 43dbcb15
      Doug Goldstein 提交于
      Always build all available backends to avoid bit-rot. At run time we
      select the correct backend and load it by attempting netcf first and
      then udev.
      43dbcb15
    • D
      interface: add udev based backend for virInterface · 5a33366f
      Doug Goldstein 提交于
      Add a read-only udev based backend for virInterface. Useful for distros
      that do not have netcf support yet. Multiple libvirt based utilities use
      a HAL based fallback when virInterface is not available which is less
      than ideal. This implements:
      * virConnectNumOfInterfaces()
      * virConnectListInterfaces()
      * virConnectNumOfDefinedInterfaces()
      * virConnectListDefinedInterfaces()
      * virConnectListAllInterfaces()
      * virConnectInterfaceLookupByName()
      * virConnectInterfaceLookupByMACString()
      5a33366f
  14. 05 10月, 2012 2 次提交
    • E
      build: fix VPATH builds · a86c039d
      Eric Blake 提交于
      This reverts part of commit 5468594f; the perl changes in that
      patch were sufficient.  Since libvirt.syms is already a generated
      file created in part from libvirt_private.syms, we don't need a
      second pass over libvirt_private.syms in isolation.
      
      * src/Makefile.am: Undo addition of check-private-symfile.
      a86c039d
    • M
      Check for private symbols presence as well · 5468594f
      Michal Privoznik 提交于
      Currently, we are checking if libvirt.so contains public symbols.
      However, sometimes we rename an internal symbol and forget to
      change libvirt_private.syms accordingly. Hence, it's safer to check
      for internal symbols as well.
      5468594f
  15. 26 9月, 2012 1 次提交
  16. 19 9月, 2012 1 次提交
    • D
      build: define WITH_INTERFACE for the driver · b95ad92e
      Doug Goldstein 提交于
      Based exclusively on work by Eric Blake in a patch posted with the same
      subject. However some modifications related to comments and my plans to
      add another backend.
      
      Added WITH_INTERFACE as the only automake variable deciding whether to
      build the driver and using WITH_NETCF to identify that we're wanting to
      use the netcf library as the backend.
      
      * configure.ac: Added with_interface
      * src/interface/netcf_driver.c: Renamed..
      * src/interface/interface_backend_netcf.c: ..to this to match storage.
      * src/interface/netcf_driver.h: Renamed..
      * src/interface/interface_driver.h: ..to this.
      * daemon/Makefile.am: Respect WITH_INTERFACE and WITH_NETCF.
      * libvirt.spec.in: Add RPM support for --with-interface
      b95ad92e
  17. 06 9月, 2012 1 次提交
    • E
      build: avoid check-symfile on non-Linux · ae94cf2d
      Eric Blake 提交于
      I tested both OpenBSD and cygwin; both failed 'make check' with:
      
        GEN    check-symfile
      Can't return outside a subroutine at ./check-symfile.pl line 13.
      
      Perl requires 'exit 77' instead of 'return 77' in that context,
      but even with that tweak, the build still fails, since the exit
      code of 77 is only special to explicit TESTS=foo listings, and
      not to make-only dependency rules where we are not going through
      automake's test framework.
      
      * src/check-symfile.pl: Kill bogus platform check...
      * src/Makefile.am (check-symfile): ...and replace with an automake
      conditional.
      ae94cf2d
  18. 05 9月, 2012 1 次提交
    • E
      build: use correct libraries for clock_gettime · d74e5a4d
      Eric Blake 提交于
      On OpenBSD, clock_gettime() exists in libc rather than librt, and
      blindly linking with -lrt made the build fail.  Gnulib already
      did the work for determining which libraries to use, so we should
      reuse that work rather than doing it ourselves.
      
      * bootstrap.conf (gnulib_modules): Pull in clock-time.
      * configure.ac (RT_LIBS): Drop.
      * src/Makefile.am (libvirt_util_la_LIBADD): Use gnulib variable
      instead.
      * src/util/virtime.c (includes): Simplify.
      d74e5a4d
  19. 26 8月, 2012 1 次提交
    • L
      build: add LIBNL_CFLAGS to build of libvirt_lxc · 9cb9cbee
      Laine Stump 提交于
      When libvirt_lxc is built, it uses the utility library and #includes
      virnetdev.h, which #includes virnetlink.h, which includes
      <netlink/msg.h>.
      
      Normally, the netlink include directory would be just off
      /usr/include, so that wouldn't create a problem, but on Fedora and
      RHEL systems using libnl3, the libnl includes have been moved into
      /usr/include/libnl3 (to allow concurrent installation of libnl-1.1).
      
      All other binaries that need it have added $(LIBNL_CFLAGS) to their
      CFLAGS, but not libvirt_lxc, so it fails to build on Fedora and RHEL
      that have only libnl3-devel installed. This was previously unnoticed
      because everyone was building with libnl headers in
      /usr/include/netlink (even on systems with the headers in
      /usr/include/libnl3/netlink, many people (like me) usually also have
      the libnl1.1 headers in /usr/include/netlink).
      
      This patch adds the necessary CFLAGS for libvirt_lxc.
      
      Note that we don't need to add $(LIBNL_LIBS) to the LDADD for this
      binary, because it never directly calls libnl functions, but only
      calls them indirectly through the util library, which it's already
      linking against.
      9cb9cbee
  20. 24 8月, 2012 1 次提交
    • E
      snapshot: split snapshot conf code into own file · 6478ec16
      Eric Blake 提交于
      This has several benefits:
      1. Future snapshot-related code has a definite place to go (and I
      _will_ be adding some)
      2. Snapshot errors now use the VIR_FROM_DOMAIN_SNAPSHOT error
      classification, which has been underutilized (previously only in
      libvirt.c)
      
      * src/conf/domain_conf.h, domain_conf.c: Split...
      * src/conf/snapshot_conf.h, snapshot_conf.c: ...into new files.
      * src/Makefile.am (DOMAIN_CONF_SOURCES): Build new files.
      * po/POTFILES.in: Mark new file for translation.
      * src/vbox/vbox_tmpl.c: Update caller.
      * src/esx/esx_driver.c: Likewise.
      * src/qemu/qemu_command.c: Likewise.
      * src/qemu/qemu_domain.h: Likewise.
      6478ec16
  21. 22 8月, 2012 5 次提交
    • D
      Fix typo in Makefile.am s/LDFOAGS/LDFLAGS/ · 66473616
      Daniel P. Berrange 提交于
      66473616
    • E
      build: avoid $(builddir) in Makefile · 4fce1c43
      Eric Blake 提交于
      Older automake 1.9.6 (hello there, RHEL 5) did not populate
      $(builddir), which meant 'make check' failed with:
      
      make[3]: *** No rule to make target `/.libs/libvirt.la', needed by `check-symfile'.  Stop.
      
      For that matter, even newer automake doesn't directly emit rules
      to build .libs/libvirt.la; we are better off basing our rules
      on the public ./libvirt.la.
      
      * src/Makefile.am (check-symfile): Delete useless variable.
      4fce1c43
    • E
      build: network requires location of dbus headers · f97d02d7
      Eric Blake 提交于
      Without this patch, RHEL 5 fails to compile, since the dbus
      files lives under /usr/include/dbus-1.0/dbus/dbus.h, and
      DBUS_CFLAGS contains -I/usr/include/dbus-1.0.
      
      In file included from network/bridge_driver.c:67:
      ../src/util/virdbus.h:26:25: error: dbus/dbus.h: No such file or directory
      
      * src/Makefile.am (libvirt_driver_network_impl_la_CFLAGS): Add
      DBUS_CFLAGS.
      f97d02d7
    • S
      nwfilter: provide basic support for firewalld · 4efde75f
      Stefan Berger 提交于
      This patch provides basic support for using firewalld's firewall-cmd
      rather than then plain eb/ip(6)tables commands.
      4efde75f
    • T
      network: use firewalld instead of iptables, when available · bf156385
      Thomas Woerner 提交于
      * configure.ac, spec file: firewalld defaults to enabled if dbus is
        available, otherwise is disabled. If --with_firewalld is explicitly
        requested and dbus is not available, configure will fail.
      
      * bridge_driver: add dbus filters to get the FirewallD1.Reloaded
        signal and DBus.NameOwnerChanged on org.fedoraproject.FirewallD1.
        When these are encountered, reload all the iptables reuls of all
        libvirt's virtual networks (similar to what happens when libvirtd is
        restarted).
      
      * iptables, ebtables: use firewall-cmd's direct passthrough interface
        when available, otherwise use iptables and ebtables commands. This
        decision is made once the first time libvirt calls
        iptables/ebtables, and that decision is maintained for the life of
        libvirtd.
      
      * Note that the nwfilter part of this patch was separated out into
        another patch by Stefan in V2, so that needs to be revised and
        re-reviewed as well.
      
      ================
      
      All the configure.ac and specfile changes are unchanged from Thomas'
      V3.
      
      V3 re-ran "firewall-cmd --state" every time a new rule was added,
      which was extremely inefficient.  V4 uses VIR_ONCE_GLOBAL_INIT to set
      up a one-time initialization function.
      
      The VIR_ONCE_GLOBAL_INIT(x) macro references a static function called
      vir(Ip|Eb)OnceInit(), which will then be called the first time that
      the static function vir(Ip|Eb)TablesInitialize() is called (that
      function is defined for you by the macro). This is
      thread-safe, so there is no chance of any race.
      
      IMPORTANT NOTE: I've left the VIR_DEBUG messages in these two init
      functions (one for iptables, on for ebtables) as VIR_WARN so that I
      don't have to turn on all the other debug message just to see
      these. Even if this patch doesn't need any other modification, those
      messages need to be changed to VIR_DEBUG before pushing.
      
      This one-time initialization works well. However, I've encountered
      problems with testing:
      
      1) Whenever I have enabled the firewalld service, *all* attempts to
      call firewall-cmd from within libvirtd end with firewall-cmd hanging
      internally somewhere. This is *not* the case if firewall-cmd returns
      non-0 in response to "firewall-cmd --state" (i.e. *that* command runs
      and returns to libvirt successfully.)
      
      2) If I start libvirtd while firewalld is stopped, then start
      firewalld later, this triggers libvirtd to reload its iptables rules,
      however it also spits out a *ton* of complaints about deletion failing
      (I suppose because firewalld has nuked all of libvirt's rules). I
      guess we need to suppress those messages (which is a more annoying
      problem to fix than you might think, but that's another story).
      
      3) I noticed a few times during this long line of errors that
      firewalld made a complaint about "Resource Temporarily
      unavailable. Having libvirtd access iptables commands directly at the
      same time as firewalld is doing so is apparently problematic.
      
      4) In general, I'm concerned about the "set it once and never change
      it" method - if firewalld is disabled at libvirtd startup, causing
      libvirtd to always use iptables/ebtables directly, this won't cause
      *terrible* problems, but if libvirtd decides to use firewall-cmd and
      firewalld is later disabled, libvirtd will not be able to recover.
      bf156385
  22. 21 8月, 2012 2 次提交
    • E
      build: split driver_storage into convenience library · 1a4379cb
      Eric Blake 提交于
      Commit 1d22ba95 was complete at the time, but we have since
      reintroduced a warning that is fixed in the same manner:
      
        CCLD   storagebackendsheepdogtest
      
      *** Warning: Linking the executable storagebackendsheepdogtest against the loadable module
      *** libvirt_driver_storage.so is not portable!
      
      * src/Makefile.am (libvirt_driver_storage.la): Factor into new
      convenience library libvirt_driver_storage_impl.la.
      * tests/Makefile.am (storagebackendsheepdogtest_LDADD): Link to
      convenience library, not shared library.
      1a4379cb
    • P
      libssh2_transport: add main libssh2 transport implementation · 1193fc5f
      Peter Krempa 提交于
      This patch adds helper functions that enable us to use libssh2 in
      conjunction with libvirt's virNetSockets for ssh transport instead of
      spawning "ssh" client process.
      
      This implemetation supports tunneled plaintext, keyboard-interactive,
      private key, ssh agent based and null authentication. Libvirt's Auth
      callback is used for interaction with the user. (Keyboard interactive
      authentication, adding of host keys, private key passphrases). This
      enables seamless integration into the application using libvirt. No
      helpers as "ssh-askpass" are needed.
      
      Reading and writing of OpenSSH style "known_hosts" files is supported.
      
      Communication is done using SSH exec channel, where the user may specify
      arbitrary command to be executed on the remote side and reads and writes
      to/from stdin/out are sent through the ssh channel. Usage of stderr is
      not (yet) supported.
      1193fc5f
  23. 18 8月, 2012 1 次提交
  24. 17 8月, 2012 1 次提交
    • E
      build: ship stamp files · b44e6bef
      Eric Blake 提交于
      'make distcheck' fails because the generated ESX and HyperV files
      are (intentionally) marked read-only, but since the stamp file was
      missing, make assumes they need to be rebuilt.  Shipping the stamp
      file solves the problem.
      
      * src/Makefile.am (EXTRA_DIST): Ship stamp files.
      b44e6bef
  25. 16 8月, 2012 2 次提交
    • L
      conf: add <vlan> element to network and domain interface elements · 3f9274a5
      Laine Stump 提交于
      The following config elements now support a <vlan> subelements:
      
      within a domain: <interface>, and the <actual> subelement of <interface>
      within a network: the toplevel, as well as any <portgroup>
      
      Each vlan element must have one or more <tag id='n'/> subelements.  If
      there is more than one tag, it is assumed that vlan trunking is being
      requested. If trunking is required with only a single tag, the
      attribute "trunk='yes'" should be added to the toplevel <vlan>
      element.
      
      Some examples:
      
        <interface type='hostdev'/>
          <vlan>
            <tag id='42'/>
          </vlan>
          <mac address='52:54:00:12:34:56'/>
          ...
        </interface>
      
        <network>
          <name>vlan-net</name>
          <vlan trunk='yes'>
            <tag id='30'/>
          </vlan>
          <virtualport type='openvswitch'/>
        </network>
      
        <interface type='network'/>
          <source network='vlan-net'/>
          ...
        </interface>
      
        <network>
          <name>trunk-vlan</name>
          <vlan>
            <tag id='42'/>
            <tag id='43'/>
          </vlan>
          ...
        </network>
      
        <network>
          <name>multi</name>
          ...
          <portgroup name='production'/>
            <vlan>
              <tag id='42'/>
            </vlan>
          </portgroup>
          <portgroup name='test'/>
            <vlan>
              <tag id='666'/>
            </vlan>
          </portgroup>
        </network>
      
        <interface type='network'/>
          <source network='multi' portgroup='test'/>
          ...
        </interface>
      
      IMPORTANT NOTE: As of this patch there is no backend support for the
      vlan element for *any* network device type. When support is added in
      later patches, it will only be for those select network types that
      support setting up a vlan on the host side, without the guest's
      involvement. (For example, it will be possible to configure a vlan for
      a guest connected to an openvswitch bridge, but it won't be possible
      to do that for one that is connected to a standard Linux host bridge.)
      3f9274a5
    • L
      util: add virNetDevVlanType · cfbdd005
      Laine Stump 提交于
      To allow for the possibility of vlan "trunks", which have more than
      one vlan tag associated with them, we need a vlan struct. Since it
      will be used by multiple files in src/util, src/conf, src/network, and
      src/qemu, it must be defined in src/util. Unfortunately there isn't
      currently a common file for simple netdev data definitions, so I
      created a new file.
      cfbdd005
  26. 15 8月, 2012 2 次提交
    • E
      random: link with -lm when needed · c606671a
      Eric Blake 提交于
      Use of ldexp() requires -lm on some platforms; use gnulib to determine
      this for our makefile.  Also, optimize virRandomInt() for the case
      of a power-of-two limit (actually rather common, given that Daniel
      has a pending patch to replace virRandomBits(10) with code that will
      default to virRandomInt(1024) on default SELinux settings).
      
      * .gnulib: Update to latest, for ldexp.
      * bootstrap.conf (gnulib_modules): Import ldexp.
      * src/Makefile.am (libvirt_util_la_CFLAGS): Link with -lm when
      needed.
      * src/util/virrandom.c (virRandomInt): Optimize powers of 2.
      c606671a
    • E
      build: fix link error with appArmor · 37f3cd41
      Eric Blake 提交于
      Commit bb705e25 missed that the appArmor helper file also needs to
      resolve the new symbols dragged in by domain_conf.c.
      
      * src/Makefile.am (SECURITY_DRIVER_APPARMOR_HELPER_SOURCES): Pull
      in datatypes.c.
      37f3cd41
  27. 14 8月, 2012 1 次提交
    • O
      Destroy virdomainlist.[ch] · bb705e25
      Osier Yang 提交于
      As the consensus in:
      https://www.redhat.com/archives/libvir-list/2012-July/msg01692.html,
      this patch is to destroy conf/virdomainlist.[ch], folding the
      helpers into conf/domain_conf.[ch].
      
      * src/Makefile.am:
        - Various indention fixes incidentally
        - Add macro DATATYPES_SOURCES (datatypes.[ch])
        - Link datatypes.[ch] for libvirt_lxc
      
      * src/conf/domain_conf.c:
        - Move all the stuffs from virdomainlist.c into it
        - Use virUnrefDomain and virUnrefDomainSnapshot instead of
          virDomainFree and virDomainSnapshotFree, which are defined
          in libvirt.c, and we don't want to link to it.
        - Remove "if" before "free" the object, as virObjectUnref
          is in the list "useless_free_options".
      
      * src/conf/domain_conf.h:
        - Move all the stuffs from virdomainlist.h into it
        - s/LIST_FILTER/LIST_DOMAINS_FILTER/
      
      * src/libxl/libxl_driver.c:
        - s/LIST_FILTER/LIST_DOMAINS_FILTER/
        - no (include "virdomainlist.h")
      
      * src/libxl/libxl_driver.c: Likewise
      
      * src/lxc/lxc_driver.c: Likewise
      
      * src/openvz/openvz_driver.c: Likewise
      
      * src/parallels/parallels_driver.c: Likewise
      
      * src/qemu/qemu_driver.c: Likewise
      
      * src/test/test_driver.c: Likewise
      
      * src/uml/uml_driver.c: Likewise
      
      * src/vbox/vbox_tmpl.c: Likewise
      
      * src/vmware/vmware_driver.c: Likewise
      
      * tools/virsh-domain-monitor.c: Likewise
      
      * tools/virsh.c: Likewise
      bb705e25