views:

250

answers:

10

Hello

I was reading today question on IDEs fo C++, and there are very good ones like Netbeans.

My question is about creating a software in C++ on Windows Environment, but let users install and run my software also on Linux and OSX.

Does netbeans has a compiler to do the job, or is there any good IDE which has a compiler for targeting my c++ code to these other environments?

thank you

A: 

Without a doubt VisualStudio with gnu make.

sadboy
indeed you just have to change the compiler. Gnu is for linux?
Junior Mayhé
+1  A: 

Many people like Code::Blocks and it is cross-platform, with integrated debugging, code completion, etc. Qt Creator is also good and at least still very minimalistic.

Tronic
I found this tutorial on QT Creator http://doc.trolltech.com/4.5/tutorials-addressbook-part1.html
Junior Mayhé
I Also use QtCreator, it runs fast and use GDB and GCC as its backend
dzen
+2  A: 

QtCreator. It's awesome, slick and everything.

While it is not as feature rich as some competitors, it does many things just right that others don't.

I would say it is the one truly cross-platform IDE that is competitive to single-platform solutions. And it comes with tight integration of a very powerful and clean cross-platform toolkit. Something that you need for most cross-platform applications by itself.

ypnos
Thank you, I'll take a look! http://sector.ynet.sk/qt4-tutorial/my-first-qt-gui-application.html
Junior Mayhé
Did you have a chance to use also Code::Blocks?
Junior Mayhé
Yes and I don't like it. The main problem is that it is centered around wxWidgets which has a deprecated API design (basically MFC-alike) and does not work as well as advertised on other platforms.
ypnos
A: 

I've found Visual Studio to have the best IDE for C++. In addition, it's debugger and the way it handles multi-threaded applications is excellent.

And you can tweak the properties for your project to use different compilers and compiler flags of your choice, so it can build to any target.

Shayan
yes Shayan, where to download compilers for each OS?
Junior Mayhé
Well for most platforms gcc works great, http://gcc.gnu.org/. You can specify the appropriate target flags, and it will compile to that.
Shayan
Use Msys/mingw on Windows: http://sourceforge.net/projects/mingw/files/ - this is gcc/g++ for Win32. Use gcc/g++ "from" Apple on Mac OSX, use gcc/g++ on linux.
Ninefingers
+2  A: 

I use Eclipse CDT and have had some degree of success. But I'm a Java programmer, so it's what I'm used to. It's worth checking out, and the extensions are quite cool.

larley
A: 

You're talking about cross-compiling as GMan said, that's a compiler job, not IDE's and itu's kind of hard to make C++ software that runs well on Linux/Windows/MacOSX, C++ isn't a cross plataform language beacuse of its ABI, so you should try to use C++ standart code. If you're making a consloe application there's no much problem just be care not to use system interface, but if you're planning to do some kind of graphics app then C++ it not the better choice for your purpose. Try some design that split the view from the controller/model of the app.

erick2red
A: 

You can use QtCreator or NetBeans. First on C++ secord on Java. Both use MinGW g++.

den bardadym
A: 

Just a thought: you don't need to use a single IDE for all platforms. It is very common, for example, to use Visual Studio on Windows and Xcode on Mac OS X for cross-platform projects. I'm not familiar with Linux IDEs thought so couldn't recommend anything there.

Frederik Slijkerman
A: 

Write makefiles for each OS? Simple enough seems to me.

Paul Nathan
A: 

Concerning cross plattform development it doesn't make a difference which IDE you use. Just make sure you use a cross platform (and possibly IDE independent) build system like SCons or cmake.

mabr