SecBSD's official ports repository
This commit is contained in:
commit
2c0afcbbf3
64331 changed files with 5339189 additions and 0 deletions
21
comms/libhidapi/patches/patch-hidtest_test_c
Normal file
21
comms/libhidapi/patches/patch-hidtest_test_c
Normal file
|
@ -0,0 +1,21 @@
|
|||
rename hid_init() to hidapi_hid_init() to avoid collision with usbhid
|
||||
|
||||
Index: hidtest/test.c
|
||||
--- hidtest/test.c.orig
|
||||
+++ hidtest/test.c
|
||||
@@ -93,12 +93,12 @@ int main(int argc, char* argv[])
|
||||
printf("Compile-time version is different than runtime version of hidapi.\n]n");
|
||||
}
|
||||
|
||||
- if (hid_init())
|
||||
+ if (hidapi_hid_init())
|
||||
return -1;
|
||||
|
||||
#if defined(__APPLE__) && HID_API_VERSION >= HID_API_MAKE_VERSION(0, 12, 0)
|
||||
- // To work properly needs to be called before hid_open/hid_open_path after hid_init.
|
||||
- // Best/recommended option - call it right after hid_init.
|
||||
+ // To work properly needs to be called before hid_open/hid_open_path after hidapi_hid_init.
|
||||
+ // Best/recommended option - call it right after hidapi_hid_init.
|
||||
hid_darwin_set_open_exclusive(0);
|
||||
#endif
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue