tags:

views:

3244

answers:

10
+7  Q: 

C++ IDE for Macs

I teach a C++ course using Visual Studio. One of my students has a Mac, and was looking for an IDE to use on his machine. What would be good to recommend?

+21  A: 

Xcode which is part of the MacOS Developer Tools is a great IDE. There's also NetBeans and Eclipse that can be configured to build and compile C++ projects.

Grant Limberg
(rhetorical) how can you beat Xcode as the answer to JohnMcG's question? you can't! Xcode is FREE (to mac owners), and while it simplifies and streamlines what gcc and gdb are doing for you, it **is** built on gnu, so you can easily "drop down a level" to straight gcc and gdb at any time!
que que
Xcode doesn't have refactoring support on OSX. Or at least it was disabled on my system.. so I use eclipse for now.
Nils
I also have to say that I like the fonts in Xcode much more, they look kinda wired in eclipse..
Nils
+2  A: 

XCode is free and good, which is lucky because it's pretty much the only option on the Mac.

Menkboy
Eclipse is also an option but XCode is also good.
JR Lawhorne
+3  A: 

Emacs! Eclipse might work too.

Terry Lorber
+2  A: 

It's not really an IDE per se, but I really like TextMate, and with the C++ bundle that ships with it, it can do a lot of the things you'd find in an IDE (without all the bloat!).

mipadi
I agree, unlike XCode, emacs etc. it's not free though...
Pieter
+2  A: 

Code::Blocks is cross-platform, using the wxWidgets library. It's the one I use.

Head Geek
A: 

I'm going to agree with the crowd and suggest XCode. Take note that if he's still running MacOS 10.4, he won't be able to get the newest version of XCode.

Brian
A: 

Another (albeit non-free) option is to install VMware Fusion or Parallels Desktop on the Mac and run Windows with Visual Studio in a VM.

This works really pretty well. The downsides are:

  • it'll cost money for the virtual machine software and Windows (the school may have some academic licensing that may help here)
  • the Mac needs to be an x86 Mac with a fair bit of memory

The upside is that you and the student don't need to hassle with differences in the IDE that may not be accounted for in your instruction materials.

Michael Burr
Worth mentioning that with your method he will be building Windows binaries, and he _may_ want to build MacOS binaries instead.
Petruza
He could use virtual box which is free.
Dean
+3  A: 

If you are looking for a full-fledged IDE like Visual Studio, I think Eclipse might be your best bet.

Eclipse is also highly extensible and configurable.

See here: http://www.eclipse.org/downloads/

nkr1pt
A: 

Avoid Eclipse for C/C++ development for now on Mac OS X 10.6 (Snow Leopard). There are serious problems which make debugging problematic or nearly impossible on it currently due to GDB incompatibility problems and the like. See: Trouble debugging C++ using Eclipse Galileo on Mac.

Joel Hoff
A: 

i'm facing the same problem now. my lecturer is teaching using visual studio, however im using a mac. is there any alternative that i can use? i dont want to be left behind in the subject.

vincent
If your teacher is teaching platform-neutral stuff, then you can do the exact same things in Xcode. The difficulty you'll have is that when say the teach shows how to add a library, the steps for doing that on Xcode will be completely different and your teacher will be unable to help you. That's not a big problem when you're experienced and know how to do the same things in Xcode, but it will be tough for someone just starting out.
Wade Williams
Learn how to use cmake (cmake.org). Writing cmake files is easier then GNU Makefile (they don't have such an awkward syntax) and cmake can produce Xcode, eclipse and VS projects out of your code :)
Nils