The MSDK includes Makefile targets for flashing via a flash.mk file. This target depends on a rule for creating a .hex file. The .hex file is added as an explicit dependency of the flashing targets so that it's built before attempting the flash. On Windows + MSYS2 the file path was mal-formed. cygpath is required to correct the path, but the code that detected the availability of cygpath was not working correctly.
This PR fixes the OS auto-detection in flash.mk, which fixes make flash.openocd on Windows.
Fixes #872
Checklist Before Requesting Review
[ ] PR Title follows correct guidelines.
[ ] Description of changes and all other relevant information.
[ ] (Optional) Link any related GitHub issues using a keyword
[ ] (Optional) Provide info on any relevant functional testing/validation. For API changes or significant features, this is not optional.
Description
The MSDK includes Makefile targets for flashing via a
flash.mk
file. This target depends on a rule for creating a .hex file. The .hex file is added as an explicit dependency of the flashing targets so that it's built before attempting the flash. On Windows + MSYS2 the file path was mal-formed.cygpath
is required to correct the path, but the code that detected the availability ofcygpath
was not working correctly.This PR fixes the OS auto-detection in
flash.mk
, which fixesmake flash.openocd
on Windows.Fixes #872
Checklist Before Requesting Review