-
Notifications
You must be signed in to change notification settings - Fork 175
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
Two stage builds and ThinLTO #4
Comments
It looks like a version mismatch between clang and the plugin. Make sure that |
Correct. My system's |
Ah! Sorry about that. You may need to modify the |
I think I figured it out. Apparently, the command that first causes that spew is:
which I got from |
I am currently implementing the two stage build style that @stephenhines mentioned in #2, building a smaller
clang
+ld.lld
and using those to build the full toolchain. I have added the ability to use ThinLTO in the second stage to provide a little bit of speed up.However, the issue I am running into is there are points in the build where GNU ld is used and my system symlinks
/usr/lib/LLVMgold.so
to/usr/lib/bfd-plugins
, which is then used instead of theLLVMgold.so
that is built as a part of stage 1, resulting in really ugly errors:Has anyone ever run into this and overcome it? I can't find anything on overriding bfd-plugins. I've tried to add
-L <stage1_lib>
to the linker flags via cmake variables but that doesn't help.At this point, the only viable workaround I can think of is just building a copy of
ld
andld.gold
standalone to ensure that everything works properly regardless of host setup.The text was updated successfully, but these errors were encountered: