-
-
Notifications
You must be signed in to change notification settings - Fork 820
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
自动识别 clang 的 target #6077
Comments
Title: Automatically identify clang’s target In what scenario do you need this function?Since 830e65800, using llvm-mingw must manually #6059 also mentions this issue. Describe possible solutionsA simple but not necessarily good enough implementation is to run
Start extracting Describe your alternativesNo response Other informationNo response |
@star-hengxing 话说当初显式指定 target 是解决啥问题?不设置 直接走默认 target 不行么 |
@star-hengxing What problem was solved by explicitly specifying the target? Isn’t it okay to just use the default target without setting it? |
target 名已经修了 #5973
clang 本身是交叉编译工具链,如果默认 target 是 |
既然修了,直接用最新的 dev 版本就行了。 |
Now that it has been fixed, just use the latest dev version. |
你在什么场景下需要该功能?
自从 830e65800 起,使用 llvm-mingw 必须手动
xmake f -p mingw
或 xmake.lua 中写上set_plat("mingw")
,否则一律会将--target=x86_64-windows-msvc
传递给 clang,然而期待的是--target=x86_64-w64-windows-gnu
。#6059 也提到了这个问题。
描述可能的解决方案
一个简单但未必足够好的实现方式是,编译前先运行
clang -v
,可能的输出:从第二行的
Target:
之后开始提取出x86_64-w64-windows-gnu
,然后再视情况做后续处理。描述你认为的候选方案
No response
其他信息
No response
The text was updated successfully, but these errors were encountered: