-
Notifications
You must be signed in to change notification settings - Fork 698
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
Installed executables take precedence over build-tool-depends
#8951
Comments
Underlying reasons
Footnotes |
Possible solutions I see two ways to address this issue. Note that they are not mutually exclusive. We could (and probably should) do both:
(1) Is a trivial change. This is why I would do that first. (2) Is more involved due to the split responsibilities between Footnotes
|
(when initially creating it)
Thanks for the reproducer. This is a regression in 3.10 likely induced by #8506 -- the code is very gnarly around how this stuff works, so need to think carefully on best way to fix it. |
Reverting the specific change to Configure.hs here resolves this issue, but then breaks the other behavior that 8506 intended to introduce: The deeper diagnosis is that My proposed, janky-as-heck, solution is to have the path from extra-prog-path eagerly added at the end of the We would then also need to still revert the above, so it also gets added at the end (in the case we're not in a -v2 build). This means that the usefulness of 8506 is lost in the non v2-build case, but I suppose its the least bad thing I can imagine. Ugh! |
(when initially creating it)
(when initially creating it)
Don't add `extra-prog-path` to `~/.config/cabal/config` (#8951)
(when initially creating it) (cherry picked from commit ea55955) # Conflicts: # cabal-install/src/Distribution/Client/Config.hs
Describe the bug
Executables from
~/.local/bin
1 shadow executables that are specified viabuild-tool-depends
.Why is this a problem? How can this corrupt your builds in non-obvious ways? How much effort is it to debug this? I'm not going into rant mode now, please use your own judgment.
Instead, I will describe the underlying reasons for this bug and possible solutions in a follow-up comment.
To Reproduce
A minimal skeleton that can be used to reproduce the issue is at https://github.com/sol/cabal-bug/tree/build-tools
You may need to adapt this according to your OS and whether you have an existing
~/.cabal
or not. So make sure that you fully understand what it is doing before you run it.System information
Operating system: Linux
cabal: 3.10.1.0
ghc: 9.6.1
Footnotes
Note that this may be
~/.cabal/bin
on your system. ↩The text was updated successfully, but these errors were encountered: