与其他GCC一起使用自制软件 [英] Using Homebrew with alternate GCC

查看:138
本文介绍了与其他GCC一起使用自制软件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经使用 homebrew-alternatives gcc 公式安装了 gcc-4.6 ,但我无法让它使用GCC来安装其他公式。特别是Open-MPI和boost。

有人知道如何让Homebrew使用这个新的编译器吗?

谢谢!

解决方案

现在这些答案都已经很老了。看来最近的自制软件版本有一个'-cc'选项,可以让你选择c编译器来使用。例如

  brew install --cc = gcc-6< package-name> 

将使用gcc的brew版本进行安装


I've installed gcc-4.6 using the homebrew-alternatives gcc formula, but I can't seem to get it to use that GCC to install other formulas. Specifically Open-MPI and boost.

Does anyone know how to make Homebrew use this new compiler?

Thanks!

解决方案

These answers are all fairly old now. It seems that recent versions of homebrew have a '--cc' option that enables you to select the c compiler to use. For example

brew install --cc=gcc-6 <package-name>

will install using the brew version of gcc

这篇关于与其他GCC一起使用自制软件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆