Brad, The main problem was in environment when build tool is running from inside of QNX SDK 'make' or 'sh' commands. Those tools completely screw up the environment simulating Unix, so Ninja cannot process generated *.ninja scripts normally anymore.
As soon as *.ninja scripts generated in the same way as on Unix (use sh.exe, forward slashes, proper escaping, etc) regular Windows Ninja executable runs normally under that QNX SDK shell. I did not try Cygwin CMake, but expect it might produce similar output. Maybe with exceptions to Windows drive letters. I predict that QNX SDK might conflict with Cygwin environment, but did not check that actually. I should also note that one of my goals was to keep using standard Windows shell for both generation and build stages. This allows to continue using native IDEs. For instance, when I work in QtCreator I simply override 'make' executable with 'ninja' and it keeps working normally. Thanks, Daniel On Thu, Jan 15, 2015 at 8:44 AM, Brad King <brad.k...@kitware.com> wrote: > On 01/14/2015 04:11 AM, Daniel Levin wrote: > > we need Ninja generator running on Windows with Unix environment. > [snip] > > is the only way to use Ninja with QNX toolchain on Windows. > > Thanks for working on this. > > Each generator corresponds to a specific build tool. Users should > select a generator based on the build tool and environment in which > they want to run, not the toolchain they want to use. Unless there > is a separate "ninja" tool for this environment that is distinct > from the Windows "ninja", this should not need a separate generator. > From your patch it looks like you're still using a normal ninja tool > but wrapping all command lines inside 'sh.exe'. > > Perhaps the main Ninja generator can be taught how to generate the > command lines for this toolchain. Much of your work on the patch > so far could probably be re-used for this approach. It may need > to be integrated differently, though. > > Side note: Have you tried running the Cygwin versions of CMake and > Ninja to drive this toolchain? > > -Brad > >
-- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers