error: no acceptable C compiler found in $PATH

If you have this error when you try to compile something in the Command Line Interface on a Mac, there’s a super simple solution. It requires installaing XCode from Apple for free, then installing the Command Line Tools for free from within XCode. There is some download time involved, but how can you complain when it’s free!?

Apple App Store IconFind the App Icon in your Applications folder or perhaps your dock and launch the app. Once launched, the interface is rather intuitive, but look for the search field in the upper right corner and do a search for “xcode” to find the app.

Find XCode In App Store Click the FREE button to the right of the XCode product, then install it. It’ll take awhile to download, since you’re requesting the sledge hammer to push a tack into a styrofoam! Who the heck knows why Apple decided not to ship Macs without a C Compiler!?

Once installed, Find the preferences under the XCode menu option in the upper left, in the menubar, and then click to the Downloads tab. There will be some items listed already, and you want to Install Command Line Tools. With that completed, you should be able t proceed with CLI compilations and Configure/Make/Make Install processes without rebooting your Mac.

xcode-command-line-tools-install