Skip to content
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

FR: Import external toolchains (e.g., from ghcup, stack, ...) #2240

Closed
jashank opened this issue Sep 9, 2024 · 3 comments
Closed

FR: Import external toolchains (e.g., from ghcup, stack, ...) #2240

jashank opened this issue Sep 9, 2024 · 3 comments

Comments

@jashank
Copy link

jashank commented Sep 9, 2024

(I imagine the answer to this is "why would you want that", but I may as well ask...)

Is your feature request related to a problem? Please describe.
Both GHCup and Stack can manage manage GHC installations (as can system package managers, but I'll ignore those for now). To my eye, it seems wasteful to have another GHC installation on my development machine. I don't particularly want to download (or, worse, compile!) more copies of the same toolchains.

Describe the solution you'd like.
Alongside rules_haskell_toolchains and haskell_register_ghc_nixpkgs, rules_haskell should provide a means to import a toolchain already available on a system. This would be analogous to Stack's system-ghc flag; or to the magic local_jdk toolchain supported for Java. (Bonus points for integration with GHCup or Stack to import toolchains automatically.)

Describe alternatives you've considered.
(I've tried shoehorning this into rules_haskell's innards, and had no joy; and I don't understand Bazel's or rules_haskell's innards well enough to be confident in from scratch. I'd prefer not to end up with Yet Another GHC on my development machine.)

Additional context.
(I have the same objection to other rules_...-defined toolchains which are hermetic-only.)

@aherrmann
Copy link
Member

Thanks for raising this issue! If I understand it correctly, I think this issue asks for the same thing as #1320. See also #1423 (comment) for a discussion around different approaches to importing GHC toolchains.

@jashank
Copy link
Author

jashank commented Sep 9, 2024

Aha! Yes, those issues are what I'm thinking of — I hadn't dug back far enough (and didn't have enough search-keyword-fu) to find them. I'll close this and go follow those instead. Thanks!

@jashank jashank closed this as not planned Won't fix, can't repro, duplicate, stale Sep 9, 2024
@aherrmann
Copy link
Member

No worries, thank you for raising this and for responding so quickly!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants