-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
rpath binaries so no LD_LIBRARY_PATH is needed #441
Comments
I started working on this a little, but I will probably switch back to concurrency stuff before long. Here's a patch with my work so far: https://gist.github.com/1031941 It depends on the getcwd and other functions that I added to the library, which will probably land after I make sure they work on all three platforms. |
…s absolute. This will be helpful for rust-lang#441.
It's possible this will only "really" work on linux and osx, and we'll have to ship a .bat file for windows that adds our bin and lib directories to %PATH%. That seems like "the normal way" to do toolchains on windows. I think. |
As part of this, I'd like to make the stageN directories look as much as possibly like the structure a normal-unix distro would want landing in /usr. That is: bin/rustc, lib/libfoo.so for the runtime libs, and lib/rustc/$arch/libfoo.so for the target libs. I have started fiddling the makefiles and configury to build this way, but it is incomplete. Best bet I think is to build everything redundantly in the old-and-new locations for a bit first, then snapshot and switch over to only using the new locations, then snapshot again and start purging the old locations. |
See also #474 |
Done. |
Reopening because it doesn't seem to be working on mac yet |
It looks like mac doesn't support $ORIGIN, so the behavior is going to be different on every platform. |
I believe the dyld equivalent to |
jckarter: Thanks for the tip! I was under the impression @executable_path could only be used as the install_name, but you can also use it in the rpath, like -Wl,-rpath,@executable_path/../lib Fantastic! |
I think this is finally working now. Here's the current scheme:
|
Add setfsgid()/setfsuid() on linux
Document type layout of `str` rust-lang#410
shift_elements_{left,right}
use of rpath and $ORIGIN when linking, and we won't need LD_LIBRARY_PATH settings at all. implement this.
The text was updated successfully, but these errors were encountered: