xavdid
xavdid

Reputation: 5264

Can I use gcc 4.7 (and C++11) on Mountain Lion without installing XCode?

I've been using command line tools and a text editor to compile class projects, which has worked great. Unfortunately, they've become sticklers about us using 4.7. Xcode (and thus OSX) only has llvm-gcc 4.2, so I was looking to upgrade.

I've got macports installed and have found instructions for installing gcc 4.7, but it says that I need xcode installed. I was hoping to be able to just use command line tools and not have xcode (I don't need any of the iOS or graphics stuff, I just want gcc.

Anyway, if it's not possible, it's no big deal, but I'd be appreciative if anyone could point me in the right direction. Thanks!

To clarify, I have command line tools, but not the version of gcc I'd like. Running macports results in this:

$ sudo port install gcc47
Error: 
Error: No Xcode installation was found.
Error: Please install Xcode and/or run xcode-select to specify its location.
Error: 
Error: The installed version of Xcode (2.0orlower) is too old to use on the installed OS version. 
Version 4.1 or later is recommended on Mac OS X 10.8.

Upvotes: 0

Views: 296

Answers (0)

Related Questions