!RbXGJhHMsnQcNIDFWN:nixos.org

Haskell in Nixpkgs/NixOS

711 Members
For discussions and questions about Haskell with Nix, cabal2nix and haskellPackages in nixpkgs | Current Docs: https://nixos.org/manual/nixpkgs/unstable/#haskell | Current PR: https://github.com/nixos/nixpkgs/pulls?q=is%3Apr+is%3Aopen+head%3Ahaskell-updates | Maintainer Docs: https://github.com/NixOS/nixpkgs/blob/haskell-updates/pkgs/development/haskell-modules/HACKING.md | More Nix: #community:nixos.org | More Haskell: #haskell-space:matrix.org | Merger Schedule: https://cloud.maralorn.de/apps/calendar/p/H6migHmKX7xHoTFa/dayGridMonth/now | Join #haskell.nix:libera.chat for question about the alternative haskell.nix infrastructure141 Servers

Load older messages


SenderMessageTime
1 May 2026
@alexfmpe:matrix.orgalexfmpe I dunno about flakes, but nix-build -A haskellPackages.smtlib-backends-z3 on nixpkgs master works just fine on my macos 15:04:23
@alexfmpe:matrix.orgalexfmpe where hackage-packages.nix shows z3 on librarySystemDepends of smtlib-backends-z3 15:05:11
@alexfmpe:matrix.orgalexfmpe ah, same for haskellPackages.z3 15:06:27
@alexfmpe:matrix.orgalexfmpe huh, isn't packages for executables only? 15:07:47
@alexfmpe:matrix.orgalexfmpehttps://nixos.org/manual/nixpkgs/stable/#sec-pkgs-mkShell15:07:48
@alexfmpe:matrix.orgalexfmpe* https://nixos.org/manual/nixpkgs/stable/#sec-pkgs-mkShell-attributes15:07:56
@alexfmpe:matrix.orgalexfmpe try inputsFrom 15:08:04
@vegowotenks:matrix.orgVegOwOtenksThanks! I will try inputsFrom, I don't have any clue about the differences.15:12:54
@alexfmpe:matrix.orgalexfmpemy link should explain it15:15:50
@alexfmpe:matrix.orgalexfmpe* my link above explains them15:15:59
@alexfmpe:matrix.orgalexfmpeyou probably want the same for libllvm and libclang15:17:55
@alexfmpe:matrix.orgalexfmpe

can we improve the whole security_tool issue for mac builds?

https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/haskell-modules/configuration-darwin.nix is littered with

  • dontCheck that, well, makes us not run tests
  • substituteInPlace System/X509/MacOS.hs --replace-fail security /usr/bin/security that breaks sandbox builds

I also run into it for some packages on darwin pkgsStatic builds somehow due to the iserv-proxy thing

statistics> [33 of 51] Compiling Statistics.Types ( Statistics/Types.hs, dist/build/Statistics/Types.o )
statistics> iserv-proxy: Uncaught exception ghc-internal:GHC.Internal.IO.Exception.IOException:
statistics>
statistics> /homeless-shelter/Library/Frameworks/Security.framework/Security: withBinaryFile: does not exist (No such file or directory)
statistics>
statistics> HasCallStack backtrace:
statistics>   ioError, called at libraries/ghc-internal/src/GHC/Internal/Foreign/C/Error.hs:291:5 in ghc-internal:GHC.Internal.Foreign.C.Error
statistics>
statistics> <no location info>: error: External interpreter terminated (1)
16:45:24
@alexfmpe:matrix.orgalexfmpe *

can we improve the whole security_tool issue for mac builds?

https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/haskell-modules/configuration-darwin.nix is littered with

  • dontCheck that, well, makes us not run tests
  • substituteInPlace System/X509/MacOS.hs --replace-fail security /usr/bin/security that breaks sandbox builds

I also run into it for some packages on darwin pkgsStatic.haskellPackages builds somehow via iserv-proxy

statistics> [33 of 51] Compiling Statistics.Types ( Statistics/Types.hs, dist/build/Statistics/Types.o )
statistics> iserv-proxy: Uncaught exception ghc-internal:GHC.Internal.IO.Exception.IOException:
statistics>
statistics> /homeless-shelter/Library/Frameworks/Security.framework/Security: withBinaryFile: does not exist (No such file or directory)
statistics>
statistics> HasCallStack backtrace:
statistics>   ioError, called at libraries/ghc-internal/src/GHC/Internal/Foreign/C/Error.hs:291:5 in ghc-internal:GHC.Internal.Foreign.C.Error
statistics>
statistics> <no location info>: error: External interpreter terminated (1)
16:45:47
@alexfmpe:matrix.orgalexfmpehuh, wait, maybe that's not the same "security" ? hard to tell with case insensitive system16:47:08
2 May 2026
@sternenseemann:systemli.orgsterni
In reply to @alexfmpe:matrix.org

can we improve the whole security_tool issue for mac builds?

https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/haskell-modules/configuration-darwin.nix is littered with

  • dontCheck that, well, makes us not run tests
  • substituteInPlace System/X509/MacOS.hs --replace-fail security /usr/bin/security that breaks sandbox builds

I also run into it for some packages on darwin pkgsStatic builds somehow due to the iserv-proxy thing

statistics> [33 of 51] Compiling Statistics.Types ( Statistics/Types.hs, dist/build/Statistics/Types.o )
statistics> iserv-proxy: Uncaught exception ghc-internal:GHC.Internal.IO.Exception.IOException:
statistics>
statistics> /homeless-shelter/Library/Frameworks/Security.framework/Security: withBinaryFile: does not exist (No such file or directory)
statistics>
statistics> HasCallStack backtrace:
statistics>   ioError, called at libraries/ghc-internal/src/GHC/Internal/Foreign/C/Error.hs:291:5 in ghc-internal:GHC.Internal.Foreign.C.Error
statistics>
statistics> <no location info>: error: External interpreter terminated (1)
that looks like the internal linker trying to load the Security framework, but I don’t think that’s available as a static archive, so won’t work at all in pkgsStatic?!
07:30:00
@tks_123:matrix.orgtks_123Hi all16:39:50
@tks_123:matrix.orgtks_123Redacted or Malformed Event16:40:28
@tks_123:matrix.orgtks_123 I have this flake.nix: https://pastebox.io/api/paste/3WT3DwMK6KZz 16:41:56
@tks_123:matrix.orgtks_123After doing "nix develop" from top-level dir (same dir as flake.nix dir), I can successfully "cd" into each of the subdirectories, to run "cabal build" on those two individual Haskell projects.16:42:58
@tks_123:matrix.orgtks_123* After doing "nix develop" from top-level dir (same dir as flake.nix dir), I can - if the second project doesn't try to depend on the first project - successfully "cd" into each of the subdirectories, to run "cabal build" on those two individual Haskell projects.16:43:36
@tks_123:matrix.orgtks_123However, if I add "my-haskell-library" (the first project) into the build-depends of the second project, doing "cabal build" on the second project fails, complaining that "my-haskell-library" is not found.16:44:27
@tks_123:matrix.orgtks_123What am I doing wrong?16:44:29
@tks_123:matrix.orgtks_123* However, if I add "my-haskell-library" (the first project) into the build-depends of the second project ("my-haskell-executable"), doing "cabal build" on the second project ("my-haskell-executable") fails, complaining that "my-haskell-library" is not found.16:45:03
@tks_123:matrix.orgtks_123

Hmm after putting this into cabal.project of the second project

packages:
  .
  ../my-haskell-library

everything seems to work.

16:55:44
@tks_123:matrix.orgtks_123Why?16:55:49
@tks_123:matrix.orgtks_123I thought... the haskellPkgs in Nix was supposed to tell cabal about all known Haskell packages?16:56:16
@tks_123:matrix.orgtks_123So why was a cabal.project needed to make this work?16:56:23
@ijouw:matrix.orgijouwI would assume you need two flakes if you want to package them individually, but i am neither very proficient in flakes nor nix so i might be mistaken.17:54:03
@alexfmpe:matrix.orgalexfmpeI think shellFor won't add `packages` to `ghc-pkg list` since you're asking for a shell for iterating on them19:18:29
@alexfmpe:matrix.orgalexfmpeSo you need cabal.project to tell cabal about the other project19:18:56

Show newer messages


Back to Room ListRoom Version: 6