Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Compile OSX app on Windows with Xamarin

I have a Xamarin Mac app I've been handed to make some changes. I've got everything working correctly as far as Windows Visual Studio Xamarin connecting to Mac Xamarin -- the Mac ssh agent works and whatnot.

However, how do I compile the app? When I build it on Windows, it generates an .exe file. Is something supposed to be generated on the Mac side, too? Or do I take that .exe file and somehow package it into an OSX app?

I was trying to stay in my Windows environment to do the coding and building as much as possible.

Thank you.

like image 331
Chris Avatar asked Apr 08 '17 17:04

Chris


People also ask

Can I build iOS app on Windows with Xamarin?

Currently it is not possible to develop for iOS using Xamarin Studio on Windows. If you want to use Windows, you can use Visual Studio. If you want to use Xamarin Studio, you can do so on a Mac. Note that you will always need a Mac around, even if you're using Visual Studio.

Can you make macOS apps with C#?

Mac allows for the development of fully native Mac apps in C# and . NET using the same macOS APIs that are used when developing in Objective-C or Swift.

Does Xamarin support macOS?

Xamarin. Mac exposes the complete macOS SDK for . NET developers to build native Mac applications using C#.

Can Xamarin run on Windows?

Xamarin. Forms no longer supports Windows 8.1, Windows Phone 8.1, or Windows 10 Mobile, but Xamarin. Forms applications do run on the Windows 10 desktop. There is also preview support for the Mac, WPF, GTK#, and Tizen platforms.


1 Answers

You will need to compile/package/debug it on macOS.

The build process is performed locally on Windows, generating IL assemblies that cannot be used for running or debugging apps, and it doesn't create application bundles.

re: https://developer.xamarin.com/releases/vs/xamarin.vs_4/xamarin.vs_4.2/#Xamarin.Mac_minimum_support.

macOS Apps Mac apps can be opened and compiled in Visual Studio to check for errors, however to debug or create a working executable the project must currently be built on a Mac. This limited support for Mac projects allows for easier code sharing in Visual Studio between iOS, Android, Windows, and Mac apps.

re: https://developer.xamarin.com/guides/cross-platform/windows/visual-studio/#macOS_Apps

like image 158
SushiHangover Avatar answered Sep 21 '22 18:09

SushiHangover