This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: 1.5.24-2: libusb-win32
- From: Brian Dessent <brian at dessent dot net>
- To: cygwin at cygwin dot com
- Date: Wed, 11 Apr 2007 12:43:24 -0700
- Subject: Re: 1.5.24-2: libusb-win32
- References: <000101c77c6f$86b98df0$0d01a8c0@MAURITSHULPJE>
- Reply-to: cygwin at cygwin dot com
Maurits Kooiman wrote:
> I used your libusb-win32 (the testlibusb worked).
> mine linker couldn?t find the usb functions.
>
> Do you have any idea where to look?
>
> Regards
> Maurits Kooiman
>
> Result of the make-file:
>
> make -k all
> Building file: ../main.cpp
> Invoking: GCC C++ Compiler
> g++ -O3 -Wall -c -fmessage-length=0 -MMD -MP -MF"main.d" -MT"main.d"
> -o"main.o" "../main.cpp"
> Finished building: ../main.cpp
>
> Building target: NXTinterface.exe
> Invoking: GCC C++ Linker
> g++ -o"NXTinterface.exe" ./main.o
> ./main.o:main.cpp:(.text+0xe1): undefined reference to `_usb_init'
> ./main.o:main.cpp:(.text+0xe6): undefined reference to `_usb_find_busses'
> ./main.o:main.cpp:(.text+0xeb): undefined reference to `_usb_find_devices'
> ./main.o:main.cpp:(.text+0xf0): undefined reference to `_usb_get_busses'
> ./main.o:main.cpp:(.text+0xf5): undefined reference to `_usb_get_busses'
> collect2: ld returned 1 exit status
How do you expect this to ever work? You're not telling to link against
the library. It's not a mind reader, you need to give it -lusb.
Brian
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/