Skip to content

Conversation

alt-romes
Copy link
Collaborator

Matching the install instructions (on website) which suggest setting program-suffix:

cabal install ghc-debugger:ghc-debug-adapter --program-suffix="-$(ghc --numeric-version)"

@alt-romes
Copy link
Collaborator Author

I suspect this may be at odds with #25 ...

I thought it would be good to have the versions of the debugger be installed suffixed by the ghc version they were compiled with. We'd look up the debugger executable by the version of the GHC in PATH. This would help avoid using the wrong version of the debugger.

But if the debugger should not look at the GHC in PATH, it's harder to do this kind of validation.

@alt-romes
Copy link
Collaborator Author

Perhaps it ought to be a property of the launch.json file which GHC version to use?
In that case, every launch would use the predefined GHC version to suffix the debugger executable to spawn. By default the variable could be configured to something like $GHC_IN_PATH.

@mpickering thoughts?

@fendor
Copy link
Collaborator

fendor commented Aug 19, 2025

HLS uses a wrapper binary which looks at the GHC version and then looks for the binary hls-<ghc-version>, perhaps this would be feasible as well?

@alt-romes alt-romes added the question Further information is requested label Sep 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants