views:

43

answers:

3

I downloaded the c++ version of eclipse from the eclipse website. This installed then when i ran the basic hello world code, it wouldn't compile.

What else do i need to install to get c++ compiling on eclipse? I thought linux already had what it needed for c++ building/running? Ive googled around but the advice is for older versions of eclipse and the screen captures show options not available anymore.

I'm on Ubuntu 64

A: 

Eclipse CDT needs a makefile to build.

burkestar
Ive got a makefile (apparently) as ive chosen to create a C++ file with a makefil?
Tom
it says Launch failed, Binary not found
Tom
A: 

You need:

  • GCC
  • Eclipse

Eclipse has a built-in option to create a "helloworld" app. You simply go to File->New->C++ Project->Hello World C++ Project (Under the executable dropdown)->Enter a project name->Finish

Then you just click the run button and you should see "Hello World!!!" in the terminal at the bottom of the Eclipse window. If you still get this same error you did previously respond to this and I'll show you how to check to see if you have gcc installed.

If that doesn't help visit this blog post from July 2010 detailing how to achieve your goal.

http://max.berger.name/howto/cdt/cdt.jsp

-AHC

Drew
A: 

You should already have gcc but try this just in case:

sudo apt-get install gcc

If that doesn't do anything then you have gcc installed and the problem is probably with eclipse.

Jeff