Skip to content
talpachen edited this page Dec 20, 2020 · 12 revisions

分支说明:

构建Windows程序

  1. 安装msys2-x86_64
  2. MSYS2 MinGW 32-bit
  3. 参考清华Mirror修改软件源
  4. pacman -Syuu
  5. pacman -S autoconf automake pkg-config libtool binutils gcc git make mingw-w64-i686-toolchain mingw-w64-i686-libusb mingw-w64-i686-hidapi mingw-w64-i686-libftdi -y
  6. git clone https://github.com/vllogic/openocd_cmsis-dap_v2.git && cd openocd_cmsis-dap_v2
  7. ./bootstrap
  8. ./configure --host=i686-w64-mingw32
  9. make -j8

若mingw-w64-i686-hidapi为0.10.0版本,可能出现HID相关错误,可以移除mingw-w64-i686-hidapi,或编译安装0.10.1版本:https://github.com/libusb/hidapi

异常情况:error: "__USE_MINGW_ANSI_STDIO" redefined [-Werror]

参考:https://github.com/kendryte/openocd-kendryte/wiki/Build-on-Windows#3-run-the-following-command-in-the-project-root-directory