user2328999
user2328999

Reputation: 91

How to compile C code in Mac OS x Lion

I'm trying to compile C code on Mac OS X Lion. I use Eclipse with the CDT plugin.

I always get an error:

Launch failed Binary not found

If I do whereis gcc I get no result. And if I write gcc if the Terminal, I have a command not found error.

Upvotes: 0

Views: 2955

Answers (1)

woz
woz

Reputation: 11004

You need to install Xcode to use gcc. Be sure to manually install the command line tools:

enter image description here

You could also download the command line tools here: https://developer.apple.com/downloads/index.action?=Command%20Line%20Tools%20%28OS%20X%20Mountain%20Lion%29

Upvotes: 2

Related Questions