Skip to content
Snippets Groups Projects
Verified Commit 3f0befe3 authored by Julian Ospald's avatar Julian Ospald :tea:
Browse files

Fix `ghcup whereis ghc` for non-standard versions, fixes #289

parent 76c286f9
No related branches found
No related tags found
1 merge request!227Fix `ghcup whereis ghc` for non-standard versions, fixes #289
Pipeline #44315 passed
...@@ -1141,11 +1141,11 @@ ensureDirectories (Dirs baseDir binDir cacheDir logsDir confDir trashDir) = do ...@@ -1141,11 +1141,11 @@ ensureDirectories (Dirs baseDir binDir cacheDir logsDir confDir trashDir) = do
-- | For ghc without arch triple, this is: -- | For ghc without arch triple, this is:
-- --
-- - ghc-<ver> (e.g. ghc-8.10.4) -- - ghc
-- --
-- For ghc with arch triple: -- For ghc with arch triple:
-- --
-- - <triple>-ghc-<ver> (e.g. arm-linux-gnueabihf-ghc-8.10.4) -- - <triple>-ghc (e.g. arm-linux-gnueabihf-ghc)
ghcBinaryName :: GHCTargetVersion -> String ghcBinaryName :: GHCTargetVersion -> String
ghcBinaryName (GHCTargetVersion (Just t) v') = T.unpack (t <> "-ghc-" <> prettyVer v' <> T.pack exeExt) ghcBinaryName (GHCTargetVersion (Just t) _) = T.unpack (t <> "-ghc" <> T.pack exeExt)
ghcBinaryName (GHCTargetVersion Nothing v') = T.unpack ("ghc-" <> prettyVer v' <> T.pack exeExt) ghcBinaryName (GHCTargetVersion Nothing _) = T.unpack ("ghc" <> T.pack exeExt)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment