karalabe / hid

Gopher Interface Devices (USB HID)
Other
263 stars 131 forks source link

Compile error on ubuntu18 #27

Closed edulop91 closed 7 months ago

edulop91 commented 4 years ago
# github.com/karalabe/hid
vendor/github.com/karalabe/hid/hid_enabled.go:23:11: fatal error: os/threads_posix.c: No such file or directory
  #include "os/threads_posix.c"
           ^~~~~~~~~~~~~~~~~~~~

Have been getting this on ubuntu18. CGO_ENABLED=1. libusb 1.0.0 + libusb1.0.0-dev installed.

Wondering what I'm missing

filinvadim commented 4 years ago

Vendoring does not hook C files.

devfacet commented 4 years ago

It is related to https://github.com/golang/go/issues/26366 . Any chance you could add dummy files into hidapi and libusb directories. Here are examples:

Thanks

dolmen commented 2 years ago

~#31 should fix that.~

Edit: it doesn't.

dolmen commented 2 years ago

I have a fix for this issue on my fork: github.com/dolmen-go/hid.

holiman commented 7 months ago

Fixed with hidapi upgrade