Closed rpavlik closed 8 years ago
Thank you for noticing this. I am sadly not familiar with ninja, but MSYS_PROCESS_USE_SH cannot be defined unless you have a MSYS2-like system on Windows with the sh command.
By the way, the MSYS variable is empty when using ninja under MSYS2? Maybe there is a better way to identify a MSYS2 system?
The issue is here: https://github.com/eidheim/tiny-process-library/blob/master/CMakeLists.txt#L12
It errors out trying to build
process_unix.cpp
The CMake variable
MSYS
must presumably only be set under the MSYS makefile generator, and not under the ninja generator when used in the MSYS environment. (I don't recall seeing it before, so I don't know how standard/common/reliable of a variable it is to use)If you assume that the user must use MSYS2 and cannot use MinGW on its own, then you could generalize the check to
if(WIN32)
- this is probably the simplest, best solution at least in the short term.