• Advertisement
Sign in to follow this  

[.net] OS X and C#

This topic is 3330 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am on a Mac OS X (Leopard) machine. I love C# and would like to use it for my next project. I just installed Mono and MonoDevelop. However, even just by opening up the editor I can see it's no Visual Studio. In fact, it looks like a Linux program ported to Mac instead of a native Mac program. So anyways, I was wondering if anyone is developing C# programs on a Mac. If so, what do you use? MonoDevelop or something else? I also have VMWareFusion and VS2008, so I can use that, but I would rather find a native Mac solution so that I don't have to run Windows virtually. Thanks, Yaroslav

Share this post


Link to post
Share on other sites
Advertisement
Personally I have found using Fusion or Boot Camp and VS is the best way to go when working with C#. Although the projects I am using C# for are Windows specific. If you are using C# to develop you solutions for Windows I suggest you stick with Fusion or go the boot camp route. You will not find an equivalent environment in OS-X.

Share this post


Link to post
Share on other sites
FWIW I would second the last posters view..

I have been developing several Windows applications in parallel with OS X applications over the last few years, all involving hardware accelerated OpenGL. For these projects I have found Visual Studio running in Parallels to be totally suited to the task.

The best setup is to use 'Full Screen' mode for Parallels and dedicate one monitor to it (if you have two). In this mode both the window updating in windows itself, and the OpenGL windows all render really fast, and accurately.

It is possible to work in Coherence mode, but do expect some weirdness then...

Overall I prefer XCode to Visual Studio, but both have their good and bad points.
Thinking out-loud.. I wonder if it would be possible to interface a C# compiler into XCode?

Share this post


Link to post
Share on other sites
On a similar situation (C#/OpenGL from Linux), I use Visual Studio inside VirtualBox (free and more feature-complete compared to Parallels, also available on Macs). Set up seamless mode (integrates guest windows with the host), add a shared folder, compile on VS and run on your host. Works perfectly.

The latest version of VirtualBox can also accelerate OpenGL applications *within* the guest, so you can test on Windows and MacOS without rebooting.

Share this post


Link to post
Share on other sites
Quote:
Original post by Fiddler
On a similar situation (C#/OpenGL from Linux), I use Visual Studio inside VirtualBox (free and more feature-complete compared to Parallels, also available on Macs). Set up seamless mode (integrates guest windows with the host), add a shared folder, compile on VS and run on your host. Works perfectly.

The latest version of VirtualBox can also accelerate OpenGL applications *within* the guest, so you can test on Windows and MacOS without rebooting.


You make it sound like Parallels (and VMWare) haven't been supporting host-integrated windows ("Coherence" view on Parallels) and OpenGL acceleration since forever. 3D acceleration in VirtualBox has only just been implemented if the changelog is anything to go by.

XCode is good though.

Share this post


Link to post
Share on other sites
Quote:
Original post by scratt
FWIW I would second the last posters view..

I have been developing several Windows applications in parallel with OS X applications over the last few years, all involving hardware accelerated OpenGL. For these projects I have found Visual Studio running in Parallels to be totally suited to the task.

The best setup is to use 'Full Screen' mode for Parallels and dedicate one monitor to it (if you have two). In this mode both the window updating in windows itself, and the OpenGL windows all render really fast, and accurately.

It is possible to work in Coherence mode, but do expect some weirdness then...

Overall I prefer XCode to Visual Studio, but both have their good and bad points.
Thinking out-loud.. I wonder if it would be possible to interface a C# compiler into XCode?


I've never used it, but this page: http://code.google.com/p/cocoa-sharp-dev/wiki/CSharpPlugin has some discussion about it. I'm planning on making the move from an old PC to a mac pro and am getting my ducks in a row - programming in C# on OSX is one of those ducks I need to sort out. At last resort I'll use fusion or something to develop in MSDEV and run under OSX with a mapped drive.

Share this post


Link to post
Share on other sites
Quote:
Original post by Sphet
I'm planning on making the move from an old PC to a mac pro and am getting my ducks in a row - programming in C# on OSX is one of those ducks I need to sort out.

Why? If you do professional C# development - Windows Forms, ASP.NET - or serious hobby development - XNA, maybe - then you should maintain a dedicated Windows box, not least because those environments are very barely functional on OS X.

Why C# specifically? If you're moving to OS X, embrace the OS X tools and development approaches. If you can't, maybe you shouldn't be moving to OS X.

Share this post


Link to post
Share on other sites
Yeah, I think you are right. I just started up a project in XNA. I thought it'd be cool to make something for the IPhone, but Objective-C looks like a pain in the ass. Unfortunately, I can't run my code via VMWare Fusion since it can't find my graphics card, so it looks like I'll have to reboot in Bootcamp. And I would never thinking of switching out of OS X for anything but game development - it's just so much nicer than Windows.

Share this post


Link to post
Share on other sites
Quote:
Original post by Oluseyi
It's not. You just have to learn it. It's simpler and richer than C++ in a number of ways. *shrug*


what isn't simpler and richer than c++? :) *shrug*

but he's used to c# which is simpler and richer than c++, too. so it's a different base.

i'm not sure how well mono works on osx, but i can understand him to want to continue to use it after switching from windows. still, learning the new environment (objective c, xcode) should be done, too. just for being able to say "yes, i know it".

Share this post


Link to post
Share on other sites
Quote:
Original post by Oluseyi
Quote:
Original post by Sphet
I'm planning on making the move from an old PC to a mac pro and am getting my ducks in a row - programming in C# on OSX is one of those ducks I need to sort out.

Why? If you do professional C# development - Windows Forms, ASP.NET - or serious hobby development - XNA, maybe - then you should maintain a dedicated Windows box, not least because those environments are very barely functional on OS X.

Why C# specifically? If you're moving to OS X, embrace the OS X tools and development approaches. If you can't, maybe you shouldn't be moving to OS X.


Well, I've been working in C/C++ under x86/windows for the best part of 15 years now. Maybe it's just time for a new set of personal challenges.

At work I have recently moved to C# for a specific tool set we're developing, and would like to have an environment at home I can fool around on to knock together some ideas if they strike me. When working on small sample programs or developing different subsystem interfaces, or the like, I believe that C# is a great language. Of course there is the right language for each problem, be it C++, Objective-C or C#, among countless others.

I'm moving to a Mac platform because of some other work I want to do that is unrelated to programming both for myself and my wife. I still need to run some PC software, so while a second computer would be an option, I have neither the desk space, nor the money for a decent rig. As such, a Mac with dual boot and virtualization is a good enough solution.

Obviously, some of the the time I spend there will include learning Objective-C and the native API, as well as the XCode IDE. For quick projects that involve just simple data manipulation I think I'll use C#. Of course, python is also an option. I'm looking forward to new things to learn, whatever happens.

Share this post


Link to post
Share on other sites
Quote:
Original post by Sphet
At work I have recently moved to C# for a specific tool set we're developing, and would like to have an environment at home I can fool around on to knock together some ideas if they strike me. When working on small sample programs or developing different subsystem interfaces, or the like, I believe that C# is a great language. Of course there is the right language for each problem, be it C++, Objective-C or C#, among countless others.

The solution, then, is obvious and simple: Visual Studio on Windows in a virtualized guest (Parallels, VMWare Fusion, VirtualBox, whatever).

C# on OS X languishes because there is no real demand for it. OS X programmers don't need or want it; they're quite happy with Objective-C/Cocoa/Cocoa Touch and bindings like PyObjC and RubyCocoa. Windows programmers don't need it; they're on Windows, after all! And rare is the OS X programmer who attempts to develop ASP.NET solutions natively - why bother?

I moved my personal computing to OS X primarily for Final Cut Pro. (Ironically, I haven't even fired it up yet.) I did the research before making the move to ensure I could still dabble in programming using Python, C, C++ and other languages. I've since picked up Objective-C and found it quite enjoyable, too. I evaluated the possibilities for C# on OS X, and decided it wasn't worth the hassle - Mono + SharpDevelop + Gtk#? I'll pass. Unlike you, I have no great affection for C# or .NET, and consider it purely a work tool.

YMMV, but OS X simply isn't a great platform for C# as yet (which undermines the "C# is portable" hype considerably).

Share this post


Link to post
Share on other sites
Quote:
Original post by Oluseyi
I moved my personal computing to OS X primarily for Final Cut Pro. (Ironically, I haven't even fired it up yet.)


Glad I'm not the only one driven by this need. That's ultimately the reason for my move.

It may well be that Objective-C is the right place to spend my time, but until I've got my hands on the machine I won't know where to spend my time. Plus, Gtk# sounds like a terrible idea, and I would go with one of the C# bindings to native UI.

Interesting to hear someone else's experience - thanks for that.

S.

Share this post


Link to post
Share on other sites
Quote:
Original post by Sphet
Quote:
Original post by Oluseyi
I moved my personal computing to OS X primarily for Final Cut Pro. (Ironically, I haven't even fired it up yet.)

Glad I'm not the only one driven by this need. That's ultimately the reason for my move.

I'm supposed to be doing a bunch of animation and video editing, but somehow I'm picking up OpenGL and have a renewed interest in game programming... Curses! [smile]

Quote:
It may well be that Objective-C is the right place to spend my time, but until I've got my hands on the machine I won't know where to spend my time. Plus, Gtk# sounds like a terrible idea, and I would go with one of the C# bindings to native UI.

Cocoa#?

Quote:
Interesting to hear someone else's experience - thanks for that.

Any time. I had the fortune of already being a Python programmer, so I was ready to go from day one as soon as I got my Mac. I could then learn Objective-C leisurely. I was employed doing ASP.NET and Adobe Flex at the time, but I actually liked the fact that I couldn't bring work home.

Good luck with everything.

Share this post


Link to post
Share on other sites
Quote:
Original post by Fiddler
On a similar situation (C#/OpenGL from Linux), I use Visual Studio inside VirtualBox (free and more feature-complete compared to Parallels, also available on Macs). Set up seamless mode (integrates guest windows with the host), add a shared folder, compile on VS and run on your host. Works perfectly.

The latest version of VirtualBox can also accelerate OpenGL applications *within* the guest, so you can test on Windows and MacOS without rebooting.


I was using the MonoDevelop 2.0 alpha 1 on MacOS, but after seeing this comment I had to try it out. VirtualBox works quite well on MacOS with Windows XP as a client running in seamless mode with VS 2008. This is probably what I will use from now on for OS X C# development.

Share this post


Link to post
Share on other sites
Quote:
Original post by Oluseyi
Quote:
It may well be that Objective-C is the right place to spend my time, but until I've got my hands on the machine I won't know where to spend my time. Plus, Gtk# sounds like a terrible idea, and I would go with one of the C# bindings to native UI.

Cocoa#?


Please no :-P. There are much better alternatives than Cocoa#... http://www.monobjc.net/ is much better (there are other objective-c <--> C# wrappers that are faster, but I don't think anything compares to Monobjc's API coverage).

Share this post


Link to post
Share on other sites
Quote:
Original post by yaroslavd
Interesting. Do either of these allow development for the IPhone?

No, because there is neither Mono nor .NET for iPhone, so the resulting assemblies wouldn't run. Also, Cocoa Touch is different than Cocoa.

Share this post


Link to post
Share on other sites
Quote:
Original post by bronxbomber92
Quote:
Original post by Oluseyi
Quote:
It may well be that Objective-C is the right place to spend my time, but until I've got my hands on the machine I won't know where to spend my time. Plus, Gtk# sounds like a terrible idea, and I would go with one of the C# bindings to native UI.

Cocoa#?


Please no :-P. There are much better alternatives than Cocoa#... http://www.monobjc.net/ is much better (there are other objective-c <--> C# wrappers that are faster, but I don't think anything compares to Monobjc's API coverage).


Thanks for the tip.

Share this post


Link to post
Share on other sites
http://unity3d.com/

From what I recall, Unity lets you do iPhone development and also is Mono-friendly (at least, I remember people talking on #mono about it).

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement