PDA

View Full Version : Configuring Xcode for C++




nothvice
Jul 8, 2009, 12:44 PM
Hello. I am currently learning C++ and need to now how to configure Xcode to run very simple C++ programs. I'm not doing any GUI stuff right now, just command line stuff. I have tried to configure it myself, but every time I create a new project it adds all these extra files that I assume is for GUI stuff. When it adds all the extra files, I can't get my simple programs to work.

Thanks.



lee1210
Jul 8, 2009, 12:53 PM
file
new project
Command line utility
->C++ tool

should do it.

-Lee

jinksys
Jul 8, 2009, 02:33 PM
If you are developing a program that doesn't have a gui, it might be helpful to go into preferences->debugging and set "On Start:" to "Show Console."

larkost
Jul 8, 2009, 04:02 PM
Hello. I am currently learning C++ and need to now how to configure Xcode to run very simple C++ programs. I'm not doing any GUI stuff right now, just command line stuff. I have tried to configure it myself, but every time I create a new project it adds all these extra files that I assume is for GUI stuff. When it adds all the extra files, I can't get my simple programs to work.

Thanks.

What template are you using? If you choose the command line tool for C++ then it will give you what you need. I only have the seeding version in front of me, so I can't give you the exact name of the template you need, but it is there.

nothvice
Jul 8, 2009, 07:30 PM
Thanks for all the tips! I'm where I need to be. BTW, I was using the Carbon C++ template before.

A quick question though. Is there a way to define custom code snippets? I have a comment header that needs to be in the top of each of my programs, but the ones Xcode has built-in are exactly what I need.

Thanks