User forums > General (but related to Code::Blocks)

Day 0 Newbie:- Trying to get anything to work ! Help !

<< < (3/3)

timmoore46:
Many thanks !  G++ installed a treat !

I have now installed C::B  v 12.11 on a diiderent computer running Ubuntu 13.04  and its seems a lot more friendly.

However I can't seem to copy the code from the Editors window or the 'Logs and others'  So can't easily post what I've achieved.

log hand the source is:

#include <stdio.h>

int main()
{
        printf(Hello world!\n");
        return 0;
}

and the 'Logs and others'

---Build: R0.01 in Test01 (compiler:- GNU GCC Compiler)----

Linking stage skipped (build target has no object files to link)
Nothing to be done (all items are up-to-date).

______

Which is a big improvement  *~LOL*~ But as I'm falling down every hole, I've missed something obvious...

Update:-   It now compiles fine after G++ was installed.  and produces a ./hello executable also a '.o' file.

(still find it weird that it only worked on G++ and GCC was ignored)

Many thanks for your very patient support !

:  )))

Tim

BlueHazzard:

--- Quote from: timmoore46 on September 05, 2013, 10:37:09 am ---(still find it weird that it only worked on G++ and GCC was ignored)

--- End quote ---

gcc is the "GNU Compiler Collection". g++ is a part of gcc. The "gcc" executable is the c compiler, the g++ is the c++-compiler.
If your file ends with cpp then you use the c++ compiler, so you need the g++ executable.
If your file ends with c then you are using the c compiler and you need the gcc executable.

greetings

timmoore46:

--- Quote from: BlueHazzard on September 05, 2013, 11:58:24 am ---
--- Quote from: timmoore46 on September 05, 2013, 10:37:09 am ---(still find it weird that it only worked on G++ and GCC was ignored)

--- End quote ---

gcc is the "GNU Compiler Collection". g++ is a part of gcc. The "gcc" executable is the c compiler, the g++ is the c++-compiler.
If your file ends with cpp then you use the c++ compiler, so you need the g++ executable.
If your file ends with c then you are using the c compiler and you need the gcc executable.

greetings

--- End quote ---

You have put your finger on the problem.   Running CB  10.05 on my Linux box  GCC works fine under bash but under CB IDE a something.c source file get an error message and does not compile.  CDb 12.11 behaves differently.

Many thanks for responding.   How do you get on with CB's Editor ? can you cut and paste into it ok ?

: )))

Tim

BlueHazzard:

--- Quote from: timmoore46 on September 05, 2013, 12:07:54 pm ---can you cut and paste into it ok ?

--- End quote ---

Can't you c&p in your Editor, or only in the log window? Does it work with right-click -> Edit -> cut ?
In the log window ctrl+c isn't working (as i remember) but in the editor it should work. If not, you may have trouble with the short-cuts. you can search the forum to resolve the error, i think this was reported many times...

greetings

timmoore46:

--- Quote from: BlueHazzard on September 05, 2013, 12:13:27 pm ---
--- Quote from: timmoore46 on September 05, 2013, 12:07:54 pm ---can you cut and paste into it ok ?

--- End quote ---

Can't you c&p in your Editor, or only in the log window? Does it work with right-click -> Edit -> cut ?
In the log window ctrl+c isn't working (as i remember) but in the editor it should work. If not, you may have trouble with the short-cuts. you can search the forum to resolve the error, i think this was reported many times...

greetings

--- End quote ---

The Edit> cut paste works fine !   Many many many thanks !

On the Log report thing on I think there might be an option that works.  I'll get back on that one.

:  )))

Tim

Navigation

[0] Message Index

[*] Previous page

Go to full version