Hi guys! Thank for your job! I successfully used your project on linux ubuntu and arch linux, but now I want to use it on windows. I installed latest mingw, cloned the repo and executed:
But configure crashes with:
./configure: line 4357: syntax error near unexpected token `USB,'
./configure: line 4357: `PKG_CHECK_MODULES(USB, libusb-1.0 >= 1.0.0,,'
What I do wrong? Do I need to install libusb to mingw? Where can I find it? Is there some manual for compiling texane/stlink on windows? You have alredy done a great job, and it should be some approximate instruction for compiling on windows or pre-compiled binarys.
I also tried:
Thanks in advance
Here's a step by step from a clean install to successfully setup MinGW and build libusb-1.0 and stlink for MS Windows. Hopefully this helps someone.
Install MinGW and MSYS to C:\MinGW with the graphical installer from http://sourceforge.net/projects/mingw/files/Installer/mingw-get-setup.exe/download and add these packages:
Add C:\MinGW\bin to your path.
Create an C:\MinGW\msys\1.0\etc\fstab file to mount C:\MinGW as /mingw as per http://www.mingw.org/wiki/MSYS
Download these three glib, pkg-config, pkg-config-dev archives and extract contents to C:\MinGW
Download latest libusb-1.0 source from git://git.libusb.org/libusb.git and build (prefix as per http://www.mingw.org/wiki/MSYS)
Thank you very much for tutorial! I also can add, that at stage 2 I add path also to c:\MinGW\msys\1.0\bin(becouse I used MSYS bash to run build). So I had done "Win+R, cmd, enter, bash, enter" and there I executed ./autogen.sh .
All works for me!
FYI, if you want to connect your stlink/v2 to a USB 3.0 hub (as in most modern PCs and laptops), you must use the more recent libusb repository. Under step 5, use https://github.com/libusb/libusb instead. I have issued a pull request to update the instructions.
Hi, I never use mingw before. When I come to build the application, I obtain the following error:
Have you any suggestion?
I recall mingw once having problems with long/odd path names (STLINK~1). I may remember wrong.
Did you try looking at (the end of) config.log like it suggests? You should be able to spot the way the compiler test failed.
the problem is due to the proxy: after disabling the proxy and installing again mingw, I can now successfully build the software.