-
-
Notifications
You must be signed in to change notification settings - Fork 17.7k
glibc: add "/run/current-system/sw/bin" to the default search path returned by "getconf CS_PATH" #586
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
glibc: add "/run/current-system/sw/bin" to the default search path returned by "getconf CS_PATH" #586
Conversation
…turned by "getconf CS_PATH"
|
@civodul (if that's Ludovic, the nicks sometimes confuse me): why does this work on non-NixOS as well? I would think it also returns "/run/current-system/sw/bin:/bin:/usr/bin" as usually glibc on linux nix is pure, or not? |
|
Vladimír Čunát [email protected] skribis:
It works on non-NixOS because it lists /bin and /usr/bin. Ludo’. |
|
@civodul: Oh, I overlooked that, right then. But IMO we should rather create all the /run/* links on non-NixOS and direct them to the right destinations on the particular distribution. |
|
@vcunat How do you propose to do that? We don't have control over /run on non-NixOS systems. |
|
@edolstra: IMO that's what non-NixOS packages for nix should do (rpms, debs, etc.). |
|
But /run/current-system doesn't make sense on non-NixOS systems. What should it point to? Anyway, /run/current-system is a NixOS-ism that we shouldn't be exporting to other systems. |
|
IMO it should be a directory... containing links to necessary stuff. It depends. /run/current-system/sw/ could be approximated by /usr/ (although we may be missing stuff from /bin, /sbin and /lib). Some parts don't make sense on non-NixOS, but for others like /run/opengl-driver it's clear what it should contain. I can't say I have a wider knowledge about use cases of /run/ paths in nixpkgs. |
|
I use Nix to manage software that's installed on a Linux box on which I don't have super user privileges. On that machine, I cannot create anything in IMHO, it's okay to hack glibc to find executables in |
|
@peti: currently we hardcode the /run/current-system path... but it should probably be a parameter like we don't hardcode /nix/store (in cases like yours one can't get binaries from hydra.nixos.org anyway). These were just thoughts on a more systematic solution of similar problems on non-NixOS nixpkgs (while preserving binary compatibility with the NixOS nixpkgs). I'm certainly not against merging this. And anyway, I personally don't use nix on any non-NixOS machine anymore. |
|
@vcunat, you are right that the path returned by Still, for the time being it seems like hard-coding Since there was no objection to this patch being merged, I'll close the pull request now. |
glibc: add "/run/current-system/sw/bin" to the default search path returned by "getconf CS_PATH"
|
Well, currently we hardcode the /run/ paths everywhere, but we could agree on a different solution (e.g. globally configurable). |
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/limited-interface-to-system-nix-external-dependencies/25825/1 |
This patch changes glibc, so it goes into
stdenv-updates.See http://thread.gmane.org/gmane.linux.distributions.nixos/10967 for a discussion of the issue that this patch addresses.