diff --git a/src/node_device/node_device_udev.c b/src/node_device/node_device_udev.c index 4c37ec3189..960f3fd942 100644 --- a/src/node_device/node_device_udev.c +++ b/src/node_device/node_device_udev.c @@ -22,7 +22,9 @@ #include #include #include -#include +#ifdef __linux__ +# include +#endif #include "node_device_conf.h" #include "node_device_event.h" @@ -678,6 +680,8 @@ udevGetSCSIType(virNodeDeviceDef *def G_GNUC_UNUSED, *typestring = NULL; +#ifdef __linux__ + /* These values are Linux specific. */ switch (type) { case TYPE_DISK: *typestring = g_strdup("disk"); @@ -714,6 +718,10 @@ udevGetSCSIType(virNodeDeviceDef *def G_GNUC_UNUSED, foundtype = 0; break; } +#else + /* Implement me. */ + foundtype = 0; +#endif if (*typestring == NULL) { if (foundtype == 1) {