Ticket #32 (new enhancement)

Opened 7 years ago

Last modified 5 years ago

Make libusb-compat-0.1 easier to build for Windows

Reported by: xiaofan Owned by:
Milestone: Component: libusb-compat-0.1
Keywords: windows Cc:
Blocked By: Blocks:


Right now it is difficult to build libusb-compat-0.1 under Windows. It would be great to provide the right configure scripts for MinGW/Cygwin and Visual C++ projects files. By doing this, libusb 1.0 Windows backends may appeal to more users and this will help the testing of libusb 1.0 Windows backends (WinUSB and HID currently).

Reference thread:

Change History

comment:1 Changed 7 years ago by stuge

  • Summary changed from To make libusb-compat-0.1 easier to be built under Windows to Make libusb-compat-0.1 easier to build for Windows

comment:2 Changed 6 years ago by dsd

It looks like most of your difficulties stem from the fact that you don't have pkg-config installed. I'd imagine its pretty to install that in cygwin/mingw environments.

comment:3 Changed 6 years ago by pbatard

No precompiled packages of pkg-config currently exist for MinGW (AFAIK), so that means installation would have to be from source.

comment:4 Changed 6 years ago by stuge

pkg-config for Windows can be downloaded from http://www.gtk.org/download-windows.html under "Other third party software". Here's the direct download link:


comment:5 Changed 6 years ago by xiaofan

Looking at this now, I do not think it is worth the time to extend libusb-compat-0.1 to support libusb-win32 API which is a superset of libusb-0.1 API. It is better to ask the user of libusb-win32 to switch to libusb-1.0 API. This is especially true now that Peter seems to work to have libusb0.sys integration before 1.09 release.

comment:6 Changed 5 years ago by stuge

  • Keywords windows added; Windows, libusb-compat removed

comment:7 Changed 5 years ago by xiaofan

My comments 19months ago is not correct since 1.0.9 release does not include libusb0.sys support. On the other hand, it is possible to get libusb-compat built under Windows with MinGW. An MSVC solution is also possible.

More interesting will be bring libusb-win32's Windows specific async API to libusb-compat under Linux, Mac OS X and BSDs.

Note: See TracTickets for help on using tickets.