I recently created a Monogame 3.5 DesktopGL project in Visual Studio 2013 on my windows PC. I am now trying to open the same exact solution in Xamarin Studio 5.1 on my Mac.
The solution opened up just fine, everything compiled fine as well, but when I try to run it, nothing happens. No errors, nothing.
I went to the Debug folder for the project and saw this:
No .app file was created, so my Mac wouldn’t be able to run it anyway. In the past, with Mac projects in Monogame, a .app file has been generated and there was no issue.
My understanding was that this DesktopGL project could be opened on either operating system and should function exactly the same way. All of that works except the generation of the executable.
DesktopGL project is not a MonoMac/XamarinMac app, it’s there to provide an exe that can be run from all Desktop OSs, if you want to package it to an .app you need to do it manually.
Thanks for the reply, but Im still confused as to what I would put into the contents of the app package? All in see in my build output are dll files and and .exe, .exe.mdb
Unless you are not using any art/audio content at all in your app there should be a Content directory there as well.
I would try putting all the dll’s, the exe, the .config and the Content directory in there. I think they should be directly in the MacOS folder.
copy all the files from the publish folder that the build script made to YourAppFolder/Contents/MacOS folder (gameprojectfolder/bin/Release/netcoreapp.3.1/osx-x64/publish)
copy the publish/Content folder to the Contents/Resources folder
make an Info.plist file as indicated, customize it
When I copy the Info.plist file from the website(while changing the “YourApp” strings to my game’s name) and then append .app to the parent folder, I keep getting an error saying: “You have macOS 10.14.6. The application requires macOS 10.13 or later.”. Any reason why this might be?
Thanks for the reply, but sadly when I removed both of the lines instead of getting the “You have MacOS 10.14.6” error, I got this…weirder error instead: “You have macOS %@. The application requires macOS %@ or later.”. To make it any easier on you to help me here’s my game’s file(with everything in it): Farming Simulator.app
My first guess is that you built the executable just for one specific version of MacOs. This build command will publish for any 64-bit version of MacOs.
dotnet publish -r osx-x64
If that doesn’t help. Here’s a plist I created in the past. Take a look and see if there are any major differences between this one and yours. The LSMinimumSystemVersion I’m using is 11.0
thank you for trying to assist me in this issue but yet again nothing worked. ive gotten so desperate that i made a 5 minute video showcasing me from building it to creating the plist. heres the link(i hope maybe this will allow you to figure out the issue): monogame help - YouTube
edit: sorry for no audio(oh and i also say “ThisGame.icns” but never add in the icns file in the video but after recording i did add the icns file and it did nothing but add an icon)
Hi. I watched your video. What year is your Mac and what O/S version are you using? I know for a fact that it doesn’t run correctly on Mid-2011 Mac with High Sierra. Other than that, the only thing I would try is to use 11.0 for LSMinimumSystemVersion. If you want, you can send me the .app and I’ll try running it on my machine. I’m using an M1 Mac Mini with Monterey.
Hey! I’m using an early 2014 MacBook Air, running on macOS 10.14.6(10.14.6 is the last version that allows me to play 32-bit games). Here’s the .app: ThisGame.app
It’s not working on my Mac either. The file “ThisGame” in the MacOs folder may be suspect. An exec file should show up with a black icon that says exec. This one does not. My first guess is that the “ThisGame” file you included is a 32-bit app and that’s why finder on my 64-bit system doesn’t recognize it as an exec. When I try to open just the “ThisGame” file it doesn’t execute and instead brings up strange characters in a textedit window.