From a242ed08eee813e57f2f24bbc1c9b2b2f8c1bfe9 Mon Sep 17 00:00:00 2001 From: Tom McLaughlin Date: Fri, 24 Nov 2023 14:49:02 -0700 Subject: [PATCH] Fix GHC 9.6 kernel (closes #51) --- languages/haskell/kernel.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/languages/haskell/kernel.nix b/languages/haskell/kernel.nix index 696261f1..c2addcee 100644 --- a/languages/haskell/kernel.nix +++ b/languages/haskell/kernel.nix @@ -26,6 +26,10 @@ let proc = "${ghc.out}/bin/ghci"; }]; + libDir = if builtins.compareVersions ghc.version "9.6" < 0 + then "${ghc.out}/lib/${ghc.meta.name}" + else "${ghc.out}/lib/${ghc.meta.name}/lib"; + in common.makeJupyterKernelInner metaOnly ( @@ -37,7 +41,7 @@ common.makeJupyterKernelInner metaOnly ( "${ihaskell}/bin/ihaskell" "kernel" "{connection_file}" - "-l" "${ghc.out}/lib/${ghc.meta.name}" + "-l" libDir "--html-code-wrapper-class" "cm-s-hite" "--html-code-token-prefix" "" "+RTS" "-M3g" "-N2" "-RTS"