1. Jérôme Vuarand
  2. luausb

Commits

Jérôme Vuarand  committed 7fc3396

Fixed win32 compilation.

  • Participants
  • Parent commits 5815123
  • Branches default

Comments (0)

Files changed (2)

File usb.blake

View file
  • Ignore whitespace
 		"compat.c",
 	},
 	dependencies = {'usb'},
+	define = { LUAUSB_API='LUAMOD_API' },
 }
 
 -- vi: ft=lua

File usb.c

View file
  • Ignore whitespace
 #include <lauxlib.h>
 #include <libusb.h>
 #include <string.h>
+#ifndef _WIN32
 #include <poll.h>
+#endif
 #include <stdlib.h>
 #include <math.h>
 #include "compat.h"
 }
 
 static struct int_name_t poll_events[] = {
+#ifndef _WIN32
 	{"POLLIN", POLLIN},
 	{"POLLRDNORM", POLLRDNORM},
 	{"POLLRDBAND", POLLRDBAND},
 	{"POLLERR", POLLERR},
 	{"POLLHUP", POLLHUP},
 	{"POLLNVAL", POLLNVAL},
+#endif
 	{0, 0},
 };