-
-
Notifications
You must be signed in to change notification settings - Fork 22k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some improvements for MinGW and LLVM build on Windows #94747
Some improvements for MinGW and LLVM build on Windows #94747
Conversation
ed9f580
to
346a8b8
Compare
I'd say it's fine to require a recent (still |
Oh sorry, LLVM 14 was actually early 2022. I mis-wrote. Regardless, trying to use a distro build of LLVM together with a distro build of mingw-w64 runtime to cross-compile is not quite straightforward, so I honestly would not expect many people (if any at all) to do it with Godot. (Not to mention that GCC is still the usual compiler people use to target MinGW.) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested locally, it works as expected (Windows 11 23H2, LLVM 17.0.6 from https://github.com/mstorsjo/llvm-mingw/releases/tag/20231128). The resulting binary runs correctly.
346a8b8
to
38e47f5
Compare
methods.py
Outdated
# got built correctly regardless the invocation strategy. | ||
# Furthermore, since SCons will rebuild the library from scratch when an object file | ||
# changes, no multiple versions of the same object file will be present. | ||
self.Replace(ARFLAGS="q") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure how this is related to PR and why it's removed., nothing seems to fix the mentioned issue, so it's likely still relevant.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, let me remove this commit from the PR. I will check again some time and handle it in another PR.
38e47f5
to
c7a7a5a
Compare
Thanks! |
This PR aims to improve the MinGW developer experience, especially for llvm-mingw on Windows:
x86_64-w64-mingw-gcc.exe
) that helps using the toolchain as a drop-in replacement of GCC, but because the Godot build has some special logic for LLVM based on theuse_llvm
option, it will be better if the build script detects this situation and automatically setuse_llvm=True
.--thin
flag is only supported forllvm-ar
since LLVM 14 from 2022 (binutilsar
has had it for ages). Do we need to support older LLVM versions? Adding a check for this would be annoying though.