evmar / n2

n2 ("into"), a ninja compatible build system

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Commands fail with `CreateProcessA: The parameter is incorrect`

evmar opened this issue · comments

@tru wrote:

Every time n2 tries to execute a subprocess, it exits with CreateProcessA: The parameter is incorrect. this happens already when running cmake, and also when trying to build a small build.ninja without involving cmake.

I have tested a small build.ninja that invokes clang-cl and it worked for me, so I am not sure what's different here.
I checked that in here: https://github.com/evmar/n2/tree/main/tests/manual/clang-cl
@tru could you try running n2 on that dir and let me know if it works?

Some other possibilities:

  • Which version of Windows? Mine is Windows 10.

Next I'm eyeballing n2 code vs similar ninja code

That example works fine on my machine, I have Windows 11, but I doubt that's related. It's probably some stupid argument quoting. Those things always trip me up as well. Can you add similar error handling in n2, and we can get more info on what's going wrong?

Also, can you paste the failing build.ninja you tried that didn't involve cmake?

(In case you missed it, I pushed a change that has more error handling, so please let me know if it helps.)

FWIW, I was seeing that error when I tried the latest main branch a week or so ago, but it seems to be working fine now.

Hi! Sorry for the late reply, but I was on vacation. I downloaded and ran the latest version and this problem seems to have been fixed!