On Sat, Sep 11, 2010 at 2:44 PM, Ozkan Sezer <[email protected]> wrote:
>> I will carry out more tests but it seems there are performance issues
>> when using the MinGW-w64 build of libusb0.sys compared to the WDK
>> build, especially when using as a filter driver. I am wondering if this can
>> be the consequences of linking to libmingwex. And linking to libmingwex
>> is anyway a hack right now.
>
> Try adding the attached inlines to your wdm.h (I think around line 242 just
> before the #endif /* defined(__GNUC__) */ ) and remove the -lmingwex
> from your makefile.  These are the Interlocked* inlines from winnt.h made
> into static inlines.  let's see if that makes a difference.
>

It will still producing the following linking errors. Take note the underscore.

windres  -I./src ./src/driver/libusb_driver_rc.rc -o libusb_driver_rc.o
gcc -static -o libusb0.sys abort_endpoint.o claim_interface.o clear_feature.o di
spatch.o get_configuration.o get_descriptor.o get_interface.o get_status.o ioctl
.o libusb_driver.o pnp.o release_interface.o reset_device.o reset_endpoint.o set
_configuration.o set_descriptor.o set_feature.o set_interface.o transfer.o vendo
r_request.o power.o driver_registry.o error.o libusb_driver_rc.o  libusb0_drv.de
f -s -shared -Wl,--entry,DriverEntry -nostartfiles -nostdlib -L. -lusbd -lntoskr
nl -lhal
libusb_driver.o:libusb_driver.c:(.text+0x6a9): undefined reference to `_Interloc
kedIncrement'
libusb_driver.o:libusb_driver.c:(.text+0x6d4): undefined reference to `_Interloc
kedDecrement'
libusb_driver.o:libusb_driver.c:(.text+0x70d): undefined reference to `_Interloc
kedDecrement'
transfer.o:transfer.c:(.text+0x149): undefined reference to `_InterlockedIncreme
nt'
transfer.o:transfer.c:(.text+0x19a): undefined reference to `_InterlockedDecreme
nt'
transfer.o:transfer.c:(.text+0x1cd): undefined reference to `_InterlockedDecreme
nt'
transfer.o:transfer.c:(.text+0x324): undefined reference to `_InterlockedDecreme
nt'
transfer.o:transfer.c:(.text+0x457): undefined reference to `_InterlockedExchang
ePointer'
transfer.o:transfer.c:(.text+0x4ed): undefined reference to `_InterlockedExchang
ePointer'
transfer.o:transfer.c:(.text+0x66d): undefined reference to `_InterlockedIncreme
nt'
transfer.o:transfer.c:(.text+0xe3f): undefined reference to `_InterlockedExchang
ePointer'
transfer.o:transfer.c:(.text+0xf76): undefined reference to `_InterlockedIncreme
nt'
collect2: ld returned 1 exit status
make: *** [libusb0.sys] Error 1


-- 
Xiaofan

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to