Open ghost opened 1 month ago
i can build muon with the Visual Studio command prompt. I've not tried with gcc on Windows in cmd. That's a bug.
i can build muon with the Visual Studio command prompt. I've not tried with gcc on Windows in cmd. That's a bug.
Do you use the same command as Stage 2? Because if using a standalone ninja I can also build muon. The bug is of samu.
i've not tried samu yet, too young imho. I have other stuff to do on Windows, like the vs backend.
And i would also like to add cross compilation
The issue here is similar to #41. muon's samu uses the same platform detection code to determine if it is running on windows. It seems like in this case it is erroneously deciding that it is running on a unix-like OS and therefore attempting to wrap commands in /bin/sh
(this is the same as ninja's behavior on unix-like systems). I think this issue at least could be resolved by switching the samu code to use a compile time check for WIN32
or similar rather than relying on runtime information. I don't think there's ever a case where muon built on windows would want to behave like this, except maybe under Cygwin? But there I don't think WIN32 is defined?
_WIN32
is not defined by cygwin compilers
btw, i wonder why you decided that we are on windows (machines.c line 354) if we are also in cygwin environment
@vtorri is that wrong? Should it just be build_machine.sys == machine_system_windows
?
@vtorri is that wrong? Should it just be
build_machine.sys == machine_system_windows
?
I modified machines.c so it's now only build_machine.sys == machine_system_windows
. I can confirm that it's still calling /bin/sh
.
@annacrombie Please close this issue. The problem suddenly gone when I built against a newly cloned muon repository. The previous one I'm working with is from my own fork (not this repository). I don't know why it's this way because I have not modified anything in my fork. Maybe that github account is corrupted (I deleted it anyway).
I'm on Windows 7 (without MSYS2) so I'm using a standalone MinGW-w64 distro with Windows Command Prompt. It seems the developer doesn't have this setup in mind. I don't know if his support for MSVC is any better, too.
Please note that I have managed to have muon bootstrapped successfully (see: #37).
I have to change
build/muon
intobuild\muon.exe
for the command to be able to run.build\muon.exe setup build
worked. Butbuild\muon.exe -C build samu
failed. I inserted-v
and this is the error message:Why muon is trying to invoke sh on a pure Windows environment?