]> xenbits.xensource.com Git - libvirt.git/commitdiff
nodeinfo: fix build on non-Linux
authorRoman Bogorodskiy <bogorodskiy@gmail.com>
Sun, 12 Jun 2016 07:33:17 +0000 (10:33 +0300)
committerRoman Bogorodskiy <bogorodskiy@gmail.com>
Sun, 12 Jun 2016 07:33:17 +0000 (10:33 +0300)
SYSFS_SYSTEM_PATH is only defined for Linux, however it's used outside
of #ifdef __linux__ code, e.g. as the first argument to
nodeCapsInitNUMAFake().

But as this argument's value is used on Linux only, it's safe to define
SYSFS_SYSTEM_PATH to "fake" to get things built on FreeBSD.

src/nodeinfo.c

index 4e344bb8c82264dc602fc1901a9778efc3985e1e..b02c29489b5a1849334a86508f655ec463096b1a 100644 (file)
@@ -129,6 +129,8 @@ virNodeGetSiblingsListLinux(const char *dir, int cpu_id)
     VIR_FREE(path);
     return ret;
 }
+#else
+# define SYSFS_SYSTEM_PATH "fake"
 #endif