-
Notifications
You must be signed in to change notification settings - Fork 711
avoid PATH_MAX limitations on windows #3430
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
Comments
I believe thats one of the resons why nix uses hash-clampedname format |
Nix did same as you do. And I'm not sure they clamp name anymore, at least not on my new nixos machine. And I guess you should have used base32 after all. nix uses hash first so it's easier to find store path by 2-4 letter prefix FAQ |
Thanks, interesting reference. |
Try using smaller package ids on Windows (see #3430)
Fixed by #3431, I believe. |
Reopening because I want to backport this into 1.24.0.1. |
Backported to 1.24 in #3954, closing. |
When using nix style package ids, we get very long paths, e.g.
This is 258 chars long. The Windows max path is 260 (including the driver letter etc).
While it's certainly possible to use the Windows APIs to get long file name support, all the programs that work with these files have to support that, this includes not just cabal but ghc, gcc, linker utils etc. So it is impractical to take that approach. The only workable approach is to keep the lengths down.
Given that we are using a nix style store, there is no reason to include the full package id into the paths within each store entry. While we can link multiple versions of a package into one exe, we cannot link multiple instances of the same package (right @ezyang) in which case we don't need to duplicate the id into the
.a
library name.When did this change incidentally? We used to only use the package name + version for the lib name.
The text was updated successfully, but these errors were encountered: