Hacker News new | ask | show | jobs
by Emore 5443 days ago
For me, Xcode 4.1 removed gcc-4.0 (needed by brew for example). If you had Xcode 3.x it's still in /Developer-old, and can be re-added with ln -s /Developer-old/usr/bin/gcc-4.0 /usr/bin/gcc-4.0.
3 comments

FWIW, Homebrew only needs gcc 4.0 for a select few formula. The vast majority of them build with more modern compilers (gcc 4.2, llvm-gcc, and clang are supported; and I use a non-Apple gcc 4.6 to compile things occasionally).
Are you saying that the gcc no longer ships with Xcode, or that it, for some reason, moved the gcc binary to a different directory (or both)?

If the gcc no longer comes with Xcode, how might one get gcc for OSX Lion?

They just removed GCC 4.0.

GCC 4.2.1 is avaiable as /usr/bin/gcc-4.2, and /usr/bin/gcc is actually LLVM-GCC 4.2

I just installed xcode and I no longer have any versions of gcc in /usr/bin

edit: you actually have to run the xcode installer

You just saved me another few hours of figuring out wtf was going on. Thank you.

Apple, seriously? Is this what pro's can expect from the App Store? It's half assed at best.

I wouldn't trust that that will work; Lion provides different libraries and that gcc-4.0 is probably not compiled properly for Lion compatibility.