User forums > Embedded development
AVR GCC .... Hot to start C++ project
(1/1)
mbruck:
In eclipse there where option to chose C or C++ project wizard.... How to do that in C::B ?
scarphin:
There is no implemented option as far as I know but u can save ur c++ file with the extension '.cpp' and customize the compiling properties as described here:
http://wiki.codeblocks.org/index.php?title=Adding_support_for_non_C/C%2B%2B_files_to_the_build_system
oBFusCATed:
scarphin: have you tried it? Your solution looks brutal.
mbruck: the project templates are simple squirrel scripts, you can modify them with right click -> edit script...
scarphin:
--- Quote from: oBFusCATed on January 05, 2011, 01:00:34 pm ---scarphin: have you tried it? Your solution looks brutal.
--- End quote ---
Well, no! ;) I haven't because of 2 reasons, 1st I have no experience in C++ and 2nd it is utopia to program the AVR's in C++ without the stdlib++ support (regarding AVRGCC) in my opinion. I proposed this solution because I am not sure if the 'avr-gcc' launches the C++ compiler for '.cpp' extension (as it launches the assembler for the '.S' extension) or if CodeBlocks launches the C++ compiler for '.cpp' extension.
It might be brutal but I guess it's guaranteed to work out. ;) I also would like to know if there is a better way apart from those or if the C++ compiler gets launched in any of the cases above.
Navigation
[0] Message Index
Go to full version