C++ Compiler for mac.

Started by
26 comments, last by igni ferroque 18 years, 10 months ago
Hey all. I am looking for a C++ Compiler for mac. I have googled, C++ Compiler Mac, and the only ones that came up you have to pay for. I also have the Developer set for which came on my mac, it has Xtools/code in it which I believe can Compile for C++, the problem is it is amazainly confusing and I have no clue what to do with it. If any one can explain how to use Xtools/code to compile C++, or has a tutorial for xtools/code could you please let me know. Also if anyone knows of a free mac compiler could you tell me.
Advertisement
I believe OSX distributions come with GCC (which is what Xcode uses under the surface). You should be able to use a terminal window and autotools to do a *nix-style build setup, but that's arguably not any less confusing than Xcode [wink]

A good way to get started with Xcode is to create a new "C++ Tool" project. It will at least show you how the IDE expects things to be layed out. All of the compiler settings (well, in theory all of them, but I suspect many are missing) can be found by double-clicking the name of a target in the Targets area on the project viewer.

Unfortunately I don't know of any good documentation for Xcode. It's a steaming pile of crap and easily one of the worst-designed IDEs I've ever had the misfortune of using. Apple's developer site has some handy reference material and mailing lists, though.

Wielder of the Sacred Wands
[Work - ArenaNet] [Epoch Language] [Scribblings]

Quote:Original post by ApochPiQ
I believe OSX distributions come with GCC (which is what Xcode uses under the surface). You should be able to use a terminal window and autotools to do a *nix-style build setup, but that's arguably not any less confusing than Xcode [wink]

A good way to get started with Xcode is to create a new "C++ Tool" project. It will at least show you how the IDE expects things to be layed out. All of the compiler settings (well, in theory all of them, but I suspect many are missing) can be found by double-clicking the name of a target in the Targets area on the project viewer.

Unfortunately I don't know of any good documentation for Xcode. It's a steaming pile of crap and easily one of the worst-designed IDEs I've ever had the misfortune of using. Apple's developer site has some handy reference material and mailing lists, though.


Heres what I did.
Open up xcode
File
New Project
C++ Tool
Project Name C++ Tool
Finish
Targets
Double Click C++Test.1
Short Sample of what came up:
Build Build and Go Tasks Fix Groups Project Editing Mode
.\"Modified from man(1) of FreeBSD, the NetBSD mdoc.template, and mdoc.samples.
.\"See Also:
.\"man mdoc.samples for a complete listing of options
.\"man mdoc for the short list of editing options
.\"/usr/share/misc/mdoc.template





Nothing about compile settings.
Are you giving up on Pygame?
Quote:Original post by Boder
Are you giving up on Pygame?


No, I am looking for multiple paths. If both I can get pygame to work, I will use that, if I can get xcode to work, I will use that, if both work I will use pygame.
I use XCode personally.
Here is how to set up a simple C++ project:

1) File, New Project, C++ Tool

This will create a basic C++ program that uses the stdc++ library

2) Name it, and put it in a directory.

If you "Build and Go" now, it should work, and a terminal window with "Hello, World!" should come up.


If you follow these directions, and it doesn't work, post what goes wrong.
Quote:Original post by visage
I use XCode personally.
Here is how to set up a simple C++ project:

1) File, New Project, C++ Tool

This will create a basic C++ program that uses the stdc++ library

2) Name it, and put it in a directory.

If you "Build and Go" now, it should work, and a terminal window with "Hello, World!" should come up.


If you follow these directions, and it doesn't work, post what goes wrong.


So lets say I make a Hello World Code, but in stead, it Says Hello Houston, should the terminal then come up "Hello, World!" "Hello HOuston"?.
Computers don't like to single groups out. They would much rather say hello to the entire world, instead of simply Houston.
Quote:Original post by RDragon1
Computers don't like to single groups out. They would much rather say hello to the entire world, instead of simply Houston.


lol
----------------------------------------------------------No matter how eloquently you state your argument, the fact remains that the toilet seat is a bistable device. Therefore it's natural position is no more down than it is up.[SDL Smooth Tile Scrolling]
Well, you will have a final called "projectname.cpp" where projectname is replaced by your project name. It contains the main() method within it, and that is where the "Hello World" code is defined. Change that file, or erase it and add a new file with a main method to make your own program.

This topic is closed to new replies.

Advertisement