[ update ] INSTALL.mingw using Vanya comments
[fw/stlink] / INSTALL.mingw
1 from dandev37:
2
3 Here's a step by step from a clean install to successfully setup MinGW and build
4 libusb-1.0 and stlink for MS Windows. Hopefully this helps someone.
5
6 1. Install MinGW and MSYS to C:\MinGW with the graphical installer from
7 http://sourceforge.net/projects/mingw/files/Installer/mingw-get-setup.exe/download
8 and add these packages:
9 mingw32-base
10 mingw-developer-toolkit
11
12 2. Add C:\MinGW\bin to your path.
13 Note: a user reports she had to use c:\MinGW\msys\1.0\bin
14
15 3. Create the C:\MinGW\msys\1.0\etc\fstab file to mount C:\MinGW as /mingw as per
16 http://www.mingw.org/wiki/MSYS:
17
18 #Win32_Path     Mount_Point
19 c:/mingw        /mingw
20
21 4. Download these three glib, pkg-config, pkg-config-dev archives and extract
22 contents to C:\MinGW
23 http://win32builder.gnome.org/packages/3.6/glib_2.34.3-1_win32.zip
24 http://win32builder.gnome.org/packages/3.6/pkg-config_0.28-1_win32.zip
25 http://win32builder.gnome.org/packages/3.6/pkg-config-dev_0.28-1_win32.zip
26
27 5. Download latest libusb-1.0 source from git://git.libusb.org/libusb.git and
28 build (prefix as per http://www.mingw.org/wiki/MSYS)
29
30 ./autogen.sh
31 ./configure --prefix=/mingw
32 make
33 make install
34
35 6. Repeat for stlink source from https://github.com/texane/stlink
36
37 ./autogen.sh
38 ./configure --prefix=/mingw
39 make
40 make install
41
42 7. Enjoy the fruits of the stlink developers.