User avatar
davef21370
Posts: 897
Joined: Fri Sep 21, 2012 4:13 pm
Location: Earth But Not Grounded

libusb problem

Sat Apr 13, 2013 12:44 pm

I'm doing a little USB project but keep getting "undefined reference" errors from Geany on anything to do with the USB functions.
I've done apt-get libusb-dev which installed fine but I can't find the library (I do now have the usb.h file so I assume everything is good).
In the build commands in Geany I've put g++ -Wall -llibusb -o "%e" "%f" but it says it can't find libusb so I'm a bit stuck.

Any help would be great.
Dave.
Apple say... Monkey do !!

User avatar
davef21370
Posts: 897
Joined: Fri Sep 21, 2012 4:13 pm
Location: Earth But Not Grounded

Re: libusb problem

Sat Apr 13, 2013 1:11 pm

Sorted, had to put -L/usr/lib/ -lusb in the build command.

Dave.
Apple say... Monkey do !!

Return to “C/C++”