vrpn 07.35
Virtual Reality Peripheral Network
 
Loading...
Searching...
No Matches
vrpn_Local_HIDAPI.C
Go to the documentation of this file.
1#include "vrpn_Configure.h"
2#ifdef VRPN_USE_HID
3#ifdef VRPN_USE_LOCAL_HIDAPI
4
5#if defined(_WIN32) || defined(__CYGWIN__)
6
7// I had to include this definition to get the hid.c file to compile
8// under Visual Studio 2005. Hopefully this won't conflict with the environments
9// of others. In future versions, if NTSTATUS is located by
10// the compiler then we can remove this definition.
11
12#include "submodules/hidapi/windows/hid.c"
13
14#pragma comment( lib, "Setupapi.lib" )
15
16#elif defined(linux)
17// On linux, we need to compile this code as C code rather than C++ code
18// because otherwise the lack of casts from void* keeps it from compiling.
19// Hopefully this will be fixed in a future version. If so, we can then remove
20// the special "compile this as C" line from the Makefile and the following
21// check.
22#ifdef __cplusplus
23#error This code must be compiled as C code, rather than C++. Use the '-x c' option to the compiler.
24#endif
25
26#include "submodules/hidapi/libusb/hid.c"
27
28#elif defined(__APPLE__)
29// On the mac, we need to compile this code as C code rather than C++ code
30// because otherwise the lack of casts from void* keeps it from compiling.
31// The inclusion of this file is handled in CMake.
32//#include "submodules/hidapi/mac/hid.c"
33
34#else
35#error HIDAPI is not configured for this architecture. If the current version works on this architecture, describe how to find it in this file.
36
37#endif
38
39#endif // VRPN_USE_LOCAL_HIDAPI
40#endif // VRPN_USE_HID