-
Notifications
You must be signed in to change notification settings - Fork 36
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
ldconfig breaks when installing as user without permissions on /etc/ld.so.cache
#113
Comments
/etc/ld.so.cache
Does putting |
What would the symptoms of failure to find the dynamic libraries at runtime be? It worked fine when I tested it with a hello world type program; is there a particular type of more serious test that should break it? Although some versions of ldconfig claim to have an option that disables caching entirely, my ldconfig 2.9 on Ubuntu 14.04 does not appear to have any way to disable caching. |
If dynamic linking is broken then the compiler won't even run. |
Oh, actually that's not true, multirust will configure the environment correctly even if ldconfig fails. Running the compiler manually should fail with a linker error. |
Correct, my rustc won't work when invoked directly. And yet...
Clearly I'm missing something about the relationship between rustc and cargo in this case. |
The difference is that cargo is statically linked, so doesn't depend on any libraries, while rustc is dynamically linked. |
If the user running multirust does not have write permissions on
/etc/ld.so.cache
, multirust will fail to runldconfig
with an error (in verbose mode) likeI assume that all non-root users trying to install Multirust will be using a custom prefix, though not all installations with a custom prefix are missing permissions in
/etc/
in the way that'll cause this error.Changing the ldconfig command in
maybe_configure_ld()
in the output installation script tomakes it run successfully for me. I checked the ld.so and ldconfig man pages and didn't find any environment variables that can be used to override the default cache location.
Should we...
--no-root
option that sets the ldconfig cache to somewhere local? (either in theCFG_DESTDIR
or the current directory of the install script seem like safe bets)The text was updated successfully, but these errors were encountered: