]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
Implement virVMOperationType{To|From}String independent from WITH_MACVTAP
authorMatthias Bolte <matthias.bolte@googlemail.com>
Fri, 3 Dec 2010 17:02:59 +0000 (18:02 +0100)
committerMatthias Bolte <matthias.bolte@googlemail.com>
Fri, 3 Dec 2010 17:06:42 +0000 (18:06 +0100)
As this symbols are exported independent from WITH_MACVTAP.

src/util/macvtap.c

index 2aa319c7e2d5b0b2154a6d3ce153478fe9798bef..4345d978e6e3601d1e1a06b6abe1c4edfa1ec9a5 100644 (file)
 
 #include <config.h>
 
+#include <stdint.h>
+
 #if WITH_MACVTAP || WITH_VIRTUALPORT
 
 # include <stdio.h>
 # include <errno.h>
 # include <fcntl.h>
-# include <stdint.h>
 # include <c-ctype.h>
 # include <sys/socket.h>
 # include <sys/ioctl.h>
 
 # include <netlink/msg.h>
 
-# include "util.h"
+#endif /* WITH_MACVTAP || WITH_VIRTUALPORT */
+
+#include "util.h"
+#include "macvtap.h"
+
+#if WITH_MACVTAP || WITH_VIRTUALPORT
+
 # include "memory.h"
 # include "logging.h"
-# include "macvtap.h"
 # include "interface.h"
 # include "conf/domain_conf.h"
 # include "virterror_internal.h"
 # define LLDPAD_PID_FILE  "/var/run/lldpad.pid"
 
 
-VIR_ENUM_IMPL(virVMOperation, VIR_VM_OP_LAST,
-    "create",
-    "save",
-    "restore",
-    "destroy",
-    "migrate out",
-    "migrate in start",
-    "migrate in finish",
-    "no-op")
-
-
 enum virVirtualPortOp {
     ASSOCIATE = 0x1,
     DISASSOCIATE = 0x2,
@@ -1609,3 +1604,13 @@ vpDisassociatePortProfileId(const char *macvtap_ifname,
 }
 
 #endif /* WITH_MACVTAP || WITH_VIRTUALPORT */
+
+VIR_ENUM_IMPL(virVMOperation, VIR_VM_OP_LAST,
+    "create",
+    "save",
+    "restore",
+    "destroy",
+    "migrate out",
+    "migrate in start",
+    "migrate in finish",
+    "no-op")