22 Jun 2025 |
ners | I don't see any version checks. | 19:55:25 |
ners | Here's what the cabal wants:
pkgconfig-depends: libavutil, libavformat, libavcodec, libswscale, libavdevice,
libswresample
Here's what ffmpeg-full.dev has:
/nix/store/7v77gvdjk8410qzrpkhymihgijf5s990-ffmpeg-full-7.1.1-dev/lib
└── pkgconfig
├── libavcodec.pc
├── libavdevice.pc
├── libavfilter.pc
├── libavformat.pc
├── libavutil.pc
├── libpostproc.pc
├── libswresample.pc
└── libswscale.pc
| 19:56:37 |
ners | * I don't see any version checks or reasons why a newer version wouldn't work. | 19:57:03 |
emily | not sure. other than the missing lib prefixes in the error maybe. | 19:57:54 |
| Sashanoraa.gay (she/her, ze/zir) joined the room. | 20:27:10 |
Sashanoraa.gay (she/her, ze/zir) | Heya, a while ago I wrote a program that uses the punycode package, which is marked as broken in nixpkgs. I'm trying to figure out why but have gotten nowhere, any suggestions? | 20:28:32 |
Sashanoraa.gay (she/her, ze/zir) | * Heya, a while ago I wrote a program that uses the punycode Haskell package, which is marked as broken in nixpkgs. I'm trying to figure out why but have gotten nowhere, any suggestions? | 20:29:43 |
maralorn | In reply to @sasha:the-apothecary.club Heya, a while ago I wrote a program that uses the punycode package, which is marked as broken in nixpkgs. I'm trying to figure out why but have gotten nowhere, any suggestions? Have you looked for a "broken.yaml" file in nixpkgs and read the line in the corresponding comment? | 20:47:48 |
maralorn | Also have you tried just building it by overriding/ignoring the broken flag? | 20:48:25 |
Sashanoraa.gay (she/her, ze/zir) | In reply to @maralorn:maralorn.de Have you looked for a "broken.yaml" file in nixpkgs and read the line in the corresponding comment? I did not because I didn't know that existed. Thx! | 20:49:58 |
23 Jun 2025 |
Artem | Hey all! I'm routinely getting strange "missing dependencies" errors when trying to build with cabal on my NixOS machine. Never happens on non-NixOS. I must be missing something? E.g.:
Failed to build unix-2.8.6.0. The failure occurred during the configure step.
Build log (
/home/artem/.cache/cabal/logs/ghc-9.10.1/unix-2.8.6.0-7e70e93a018fa3cd3eeee6c9345819b76e60434f053c8d02acdb7ab743ba3a2a.log
):
Configuring unix-2.8.6.0...
Error: [Cabal-8010]
Encountered missing or private dependencies:
tasty, tasty-hunit, tasty-quickcheck
happens to various dependencies when building various packages...
| 17:51:06 |
Artem | I saw reports like that on Discourse but none of the suggestions looked particularly relevant... | 17:51:35 |
Alex | In reply to @artem.types:matrix.org
Hey all! I'm routinely getting strange "missing dependencies" errors when trying to build with cabal on my NixOS machine. Never happens on non-NixOS. I must be missing something? E.g.:
Failed to build unix-2.8.6.0. The failure occurred during the configure step.
Build log (
/home/artem/.cache/cabal/logs/ghc-9.10.1/unix-2.8.6.0-7e70e93a018fa3cd3eeee6c9345819b76e60434f053c8d02acdb7ab743ba3a2a.log
):
Configuring unix-2.8.6.0...
Error: [Cabal-8010]
Encountered missing or private dependencies:
tasty, tasty-hunit, tasty-quickcheck
happens to various dependencies when building various packages...
Are you trying to override the unix package?
Boot libraries have special handling and cannot be overridden in the usual way.
For example:
nix-repl> haskellPackages.unix
null
| 18:52:14 |
Artem | @alex:tunstall.xyz: I'm building with cabal, not nix, so, I'm not sure I understand your question but no, I'm not doing anything special I just do `cabal build` | 19:53:48 |
maralorn | @artem.types:matrix.org 1. Did you run cabal update? 2. Try reseting by removing dist-newstyle. | 19:58:09 |
Alex | In reply to @artem.types:matrix.org @alex:tunstall.xyz: I'm building with cabal, not nix, so, I'm not sure I understand your question but no, I'm not doing anything special I just do `cabal build` If you don't understand the question, the answer is "probably not".
Then you might have version constraints in your package that cause Cabal to reject the version installed with the GHC provided by Nix.
Can you try deleting the local copy of the package index? (I can't remember where in ~ cabal puts it.) | 19:58:31 |
Alex | Running cabal update produces a local package index that Cabal may try to use to build packages.
When using Nix, you typically don't want the file to exist. | 20:00:14 |
maralorn | Redacted or Malformed Event | 20:18:43 |
maralorn | Well with cabal update it should work, even though it is not a very typical workflow. | 20:20:48 |
Alex | Ah, that's not a workflow I'm familiar with and I vaguely recall it being a problem in the past...
Let's see whether any of our ideas help. | 20:22:41 |
maralorn | Alex: It has the advantage of not needing overrides as long as there is any valid build plan cabal can find on hackage. It has the disadvantage that you get no caching for dependencies and the problem that you get no automatic installation of system dependencies. So traditionally this breaks when you have e.g. zlib in your closure. | 20:24:53 |
maralorn | (I guess you know that, but that is probably the problem you remember.) | 20:25:22 |
Alex | Given that GHC 9.10 is being used, cabal update may be easier than jailbreaking and patching various packages.
I haven't tried upgrading beyond the default GHC lately, but when I do it has always involved Nix overrides... | 20:28:34 |
maralorn | I mean for building unix there shouldn’t be any problems either way, tbh. | 20:36:37 |
maralorn | I assume only problem is that test dependencies of boot packages are not boot packages themselves. | 20:37:10 |
Alex | True, but it's rare for a project to only need boot libraries.
It's hard to say what the easiest approach is without a better understanding of Artem's use case. | 20:38:49 |
Artem | In reply to @maralorn:maralorn.de @artem.types:matrix.org 1. Did you run cabal update? 2. Try reseting by removing dist-newstyle. I tried these, yes. I've been having this issue a while, so I've tried many simple things like that | 20:54:04 |
maralorn | Artem: I see. If you would like more help then maybe you can share the Haskell relevant part of the nix configuration (e.g. the nix- shell or your system config) which installed ghc, etc and also the full log of the failing command? | 20:58:38 |
Artem | @maralorn:maralorn.de: thank you, I'll do that tonight. | 21:06:52 |
24 Jun 2025 |
Artem | here's one way it fails for me (other version of GHC because it's another project that's easier to set up). I'm trying to build cabal from source, and I'm using very basic nix shell to get simple things like zlib into scope.
❯ git clone git@github.com:haskell/cabal
...
❯ git clone git@github.com:ulysses4ever/cabal.nix
...
❯ cd cabal
❯ nix develop ../cabal.nix
$ cabal build cabal
Build profile: -w ghc-9.6.6 -O1
In order, the following will be built (use -v for more details):
... long list...
Downloading unix-2.8.7.0
Starting base64-bytestring-1.2.1.0 (lib)
Starting cryptohash-sha256-0.11.102.1 (lib)
Starting regex-base-0.94.0.3 (lib)
Starting os-string-2.0.7 (lib)
Starting safe-exceptions-0.1.7.4 (lib)
Starting th-compat-0.1.6 (lib)
Starting splitmix-0.1.1 (lib)
Starting atomic-counter-0.1.2.3 (lib)
Starting base16-bytestring-1.0.2.0 (lib)
Starting ed25519-0.0.5.0 (lib)
Downloaded unix-2.8.7.0
Downloading process-1.6.26.1
Starting unix-2.8.7.0 (all, legacy fallback: build-type is Configure)
Downloaded process-1.6.26.1
Downloading semaphore-compat-1.0.0
Building base64-bytestring-1.2.1.0 (lib)
Building cryptohash-sha256-0.11.102.1 (lib)
Building regex-base-0.94.0.3 (lib)
Building os-string-2.0.7 (lib)
Building safe-exceptions-0.1.7.4 (lib)
Building splitmix-0.1.1 (lib)
Building th-compat-0.1.6 (lib)
Downloaded semaphore-compat-1.0.0
Building base16-bytestring-1.0.2.0 (lib)
Building atomic-counter-0.1.2.3 (lib)
Building ed25519-0.0.5.0 (lib)
Installing th-compat-0.1.6 (lib)
Installing atomic-counter-0.1.2.3 (lib)
Installing base16-bytestring-1.0.2.0 (lib)
Completed th-compat-0.1.6 (lib)
Completed base16-bytestring-1.0.2.0 (lib)
Installing safe-exceptions-0.1.7.4 (lib)
Completed atomic-counter-0.1.2.3 (lib)
Installing base64-bytestring-1.2.1.0 (lib)
Installing splitmix-0.1.1 (lib)
Completed safe-exceptions-0.1.7.4 (lib)
Installing regex-base-0.94.0.3 (lib)
Installing cryptohash-sha256-0.11.102.1 (lib)
Completed base64-bytestring-1.2.1.0 (lib)
Completed splitmix-0.1.1 (lib)
Completed regex-base-0.94.0.3 (lib)
Completed cryptohash-sha256-0.11.102.1 (lib)
Installing ed25519-0.0.5.0 (lib)
Completed ed25519-0.0.5.0 (lib)
Installing os-string-2.0.7 (lib)
Completed os-string-2.0.7 (lib)
Failed to build unix-2.8.7.0. The failure occurred during the configure step.
Build log (
/home/artem/.cache/cabal/logs/ghc-9.6.6/unix-2.8.7.0-f12ffa080428729a9cad2c9d340f8a2e41259c127db9b0b6e0d00096ef0bef24.log
):
Configuring unix-2.8.7.0...
Error: [Cabal-8010]
Encountered missing or private dependencies:
tasty, tasty-hunit, tasty-quickcheck
Error: [Cabal-7125]
Failed to build unix-2.8.7.0 (which is required by exe:cabal from cabal-install-3.15.0.0). See the build log above for details.
Build log isn't very useful:
❯ cat /home/artem/.cache/cabal/logs/ghc-9.6.6/unix-2.8.7.0-f12ffa080428729a9cad2c9d340f8a2e41259c127db9b0b6e0d00096ef0bef24.log
Configuring unix-2.8.7.0...
Error: [Cabal-8010]
Encountered missing or private dependencies:
tasty, tasty-hunit, tasty-quickcheck
| 03:30:29 |