This is either a problem with the LEDE libusb-compat package, or user error.
I installed the libusb-compat-0.1 package but it did not put the usb.h file on the system.
Some distros, put usb.h in a separate devel package, but I did not see one for LEDE, so I expect it to be in libusb-compat.
GL-AR300M ext with 2.27 nand firmware. Goal to connect and program a Teensy 3.2 via usb. Doing that first requires compiling from source a small loader program at https://www.pjrc.com/teensy/loader_cli.html. I decided to do that right on the GL-AR300M.
Added packages libudev, yunbridge, nano, usbutils, binutils, gcc, libusb-1.0, libusb-compat-0.1
Hello World compiled fine. Compiling the loader failed with fatal error: usb.h: No such file or directory. Further details here.
find -name “usb.h” returned only the usb.h file intended for the teensy target inside rebootor directory. Not the one I need.
I think you missed the point in the title. I installed the libusb-compat package via luci. Among other things, that package should have installed a file called usb.h (somewhere in /usr ) which my project requires at runtime as well as during compilation. I believe it cross compiled because the development machine has its own architecture dependent usb.h. I require a usb.h path on the target, the AR-300M, which will later become a host, used to reprogram microcontrollers in the field.
I am a first time user of this library, so I may have misconceptions, but others have run up against the same roadblock and been unable to proceed for this same reason. Any guidance here could help serve as missing user documentation. I would appreciate any input from someone familiar with the use of the library.
are you trying to run teensy_loader_cli on AR300M?
If yes, then it is what I have told you to do. To compile the program, you should have a cross compile toolchain rather than compile it directly on the router.
But as you have done this I hope it can work. You can just download the usb.h from libusb-compat and put it in /usr/include, but I cannot confirm it will work. The reason that there is no usb.h in the firmware is that, the router is a lightweight linux. It is used to run program but not compile program.