Terry
Terry

Reputation: 1232

Keep getting Exec format error while trying mono-4.2.2 for Windows

I've just downloaded and installed mono-4.2.2.30 for Windows on my Windows XP SP3 Laptop (The installation file name: mono-4.2.2.30-gtksharp-2.12.30-win32-0.msi) It installed itself into C:\Program Files\Mono directory. I've defined the Mono's bin folder in my ~/.bashrc

When I run any command such as mcs or mono from Mono bin directory it always gives this error:

sh: /c/Program Files/Mono/bin/mono: binary file cannot be executed: Exec format error

It gives this error on the ConEmu terminal emulator using MSYS but if I try it on other shells such as cmd.exe or git bash the same or similar error comes up.

The reason I want to use Mono for Windows is because I'd like to use .NET 4.6 apps on my Windows XP Laptop. I have installed Mono on my Mac OSX, too and I have successfully run .NET apps on it.

Inspecting the Mono commands by ldd gives the same error in short form: "Exec format error" However, inspecting the same commands by file returns:

$ file /c/Program\ Files/Mono/bin/mcs
/c/Program Files/Mono/bin/mcs: POSIX shell script, ASCII text executable
$ file /c/Program\ Files/Mono/bin/mono
/c/Program Files/Mono/bin/mono: PE32 executable (console) Intel 80386, for MS Windows

I'm not sure what's wrong here. Can someone help me? Thanks.

Upvotes: 2

Views: 536

Answers (1)

knocte
knocte

Reputation: 17939

Mono is not compatible with WindowsXP.

Upvotes: 1

Related Questions