有没有办法在OSX中安装gcc而不安装Xcode? [英] Is there a way to install gcc in OSX without installing Xcode?
问题描述
我已经googled的地狱了,似乎没有办法安装gcc在OS X,而不安装Xcode(这需要占用1.5GB的空间)。所有我需要的是gcc,没有其他垃圾与Xcode。在这一点上,我将采取任何其他类型的C编译器。
I've googled the hell out of it, and it seems like there is no way to install gcc on OS X without installing Xcode (which takes at leats 1.5GB of space). All I need is gcc and none of the other junk that comes with Xcode. And at this point, I'll take any other kind of C compiler.
我知道我可以简单地安装Xcode,但这是除了,因为我没有我的原始安装光盘或快速互联网连接。
I know I could simply install Xcode, but that is beside the point since I neither have my original installation disc nor a quick internet connection.
因此...有任何建议吗?
So... does anyone have any suggestions?
:对不起,如果我不清楚,但我需要标题以及。我目前正在通过fink安装gcc4,它也下载共享库。我会更新进度。
Sorry if I was unclear, but I need the headers as well. I'm currently installing gcc4 via fink and it's downloading the shared libraries as well. I'll update on the progress.
编辑2:好的,所以我成功地安装gcc使用fink。但是,它几乎无用:错误:C编译器不能创建可执行文件。在googling之后,我发现没有安装苹果的开发工具是错误的原因。
EDIT 2: Ok, so I successfully installed gcc using fink. BUT, it's pretty much useless: "error: C compiler cannot create executables". After googling around, I found that not having Apple's Developer Tools installed is the cause of the error. Probably because I need all the libraries, headers, etc that are only available through Xcode.
推荐答案
尝试 github上的osx-gcc-installer 。
这篇关于有没有办法在OSX中安装gcc而不安装Xcode?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!