clang:错误:“-mmacosx-version-min=11.2"中的版本号无效 [英] clang: error: invalid version number in '-mmacosx-version-min=11.2'

查看:60
本文介绍了clang:错误:“-mmacosx-version-min=11.2"中的版本号无效的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前使用的是 Mac OSX Big Sur 11.2.3.每当我运行命令时:

I am currently on Mac OSX Big Sur 11.2.3. Whenever I run the command:

g++-10 -o project0 project0.cpp -lm -fopenmp

我收到以下错误:

clang: error: invalid version number in '-mmacosx-version-min=11.2'

我意识到这可能是因为我使用的是 Big Sur 11.2.3,但我被告知这应该不是问题.我已经尝试了很多事情,例如重新安装 gcc 做 brew install gcc 等等都无济于事.在这一点上,我非常不确定该怎么做.任何帮助将不胜感激!

I realized that this may be due to the fact that I'm on Big Sur 11.2.3 but I was told that this should not be an issue. I've tried many things already such as reinstalling gcc doing brew install gcc and so forth to no avail. At this point, I'm very unsure on what to do. Any help would be very much appreciated!

推荐答案

我在尝试安装 fiona 时遇到了同样的问题.你是对的,这是由于 Big Sur,正如你在这个 文章

I ran into the same problem while trying to install fiona. You are correct it is due to Big Sur, as you can see in this article

关注它,它应该可以解决问题.请注意,我必须卸载命令行工具并按照此中所述重新安装它回答.

Follow it and it should sort out the issue. Note, I had to uninstall Command Line tools and re-install it as outlined in this answer.

这篇关于clang:错误:“-mmacosx-version-min=11.2"中的版本号无效的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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