-
-
Notifications
You must be signed in to change notification settings - Fork 264
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
ldc shouldn't install LLVMgold.so #1897
Comments
Relevant line: https://github.com/ldc-developers/ldc/blob/master/CMakeLists.txt#L737 |
Ah, I completely overlooked that LDC is not installed as a package in some arbitrary dir... |
Why is it even needed externally? And should/must it be part of the redistributable package? |
Because otherwise you cannot use LTO without installing LLVM. |
More technical please ;) - can't we link it in statically? |
It is a plugin library for the linker. |
Alright (and somehow found automatically if in the right directory). What does that mean for the package? I guess the users have to install LLVM then if they wanna play with LTO. |
I will just rename the file, easy :) |
Ah perfect. :) |
I've just had a look at the relevant code. So there's 3 hardcoded default locations Edit: Maybe not install()ing |
Note: cmake "install()" is used to create a standalone LDC package, it doesn't necessarily mean "install on my system"; I don't mind about the |
The way I see it, it is primarily used to install it locally from source, but secondarily also used as base for the redistributable packages. We already copy DLLs over specifically for the packages (libcurl on Windows, libconfig, both in bin) but don't install() them.
It can sit anywhere, with its libraries, incl. |
Note that the plugin is version locked to LDC... The only reason I copy it from LLVM is that I don't have to put in the build logic to build it ourselves. |
Copying instead of building manually is fine, and assuming a self-installed LDC was built using the currently installed LLVM (and so the currently installed |
@kinke Please let's stop debating this. Your idea will not work, and I am getting angry over having to debate this. In the only two use cases of LTO at the moment that I know of: there is no "currently installed" LLVM, the CMake script must install LLVMgold.so because there is no packing script run, etc, etc. |
So for the OP, you rather prefer getting angry over thinking about how to avoid littering his 32-bit lib dir with the 64-bit |
Isn't the obvious choice the |
That suffix is unknown at compile-time, and I think we all agree that parsing the config file and checking for the default lib path at runtime or adding a hardcoded #define for it isn't worth it. |
There is already a config switch for the library path; we could just set that from the config file. |
I was building ldc 1.1.0 beta4 for Fedora and noticed that it installs a /usr/lib/LLVMgold.so file which it clearly shouldn't as it's part of llvm. This only seems to be happening on 64 bit architectures for some reason -- llvm's LLVMgold.so is already in /usr/lib64/ and then ldc tries to install it to /usr/lib/ (note the lib64 vs lib).
https://kojipkgs.fedoraproject.org//work/tasks/7209/16647209/build.log has the full build log (short lived link)
The text was updated successfully, but these errors were encountered: