Skip to content

haskellPackages.Agda: unbreak the build by dropping a (by now) unnecessary patch#113396

Closed
iblech wants to merge 1 commit intoNixOS:masterfrom
iblech:patch-agda-2.6.1.3
Closed

haskellPackages.Agda: unbreak the build by dropping a (by now) unnecessary patch#113396
iblech wants to merge 1 commit intoNixOS:masterfrom
iblech:patch-agda-2.6.1.3

Conversation

@iblech
Copy link
Contributor

@iblech iblech commented Feb 17, 2021

Motivation for this change

Without this commit, building Agda fails as follows:

$ nix-shell -p agda
these derivations will be built:
  /nix/store/j13y12xa4g6dkn60k6y0ypp3rs62r7zn-Agda-2.6.1.3.drv
  /nix/store/xcvdw97bglp440pr0ad0xqqlk8lvxagc-agdaWithPackages-2.6.1.3.drv
building '/nix/store/j13y12xa4g6dkn60k6y0ypp3rs62r7zn-Agda-2.6.1.3.drv'...
[...]
applying patch /nix/store/38bnrnh7sbfawsyll5hlzijzvf9x09q2-76278c23d447b49f59fac581ca4ac605792aabbc.patch
patching file Agda.cabal
Hunk #1 FAILED at 249.
1 out of 1 hunk FAILED -- saving rejects to file Agda.cabal.rej
builder for '/nix/store/j13y12xa4g6dkn60k6y0ypp3rs62r7zn-Agda-2.6.1.3.drv' failed with exit code 1
cannot build derivation '/nix/store/xcvdw97bglp440pr0ad0xqqlk8lvxagc-agdaWithPackages-2.6.1.3.drv': 1 dependencies couldn't be built
error: build of '/nix/store/xcvdw97bglp440pr0ad0xqqlk8lvxagc-agdaWithPackages-2.6.1.3.drv' failed

The patch the build is complaining about was necessary for Agda 2.6.1.2, fixing a version bound in the Cabal file. Meanwhile this patch has found its way into upstream Agda 2.6.1.3 and is hence no longer required.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@iblech iblech requested a review from cdepillabout as a code owner February 17, 2021 12:13
@sternenseemann
Copy link
Member

This is already fixed on haskell-updates: 3868c09 Thus the fix will land in master on friday when the haskellPackages set is updated (see #112936). Unfortunately due to the way the haskellPackages set is maintained, there is up to a week of delay between a fix and it landing in master (which then takes time to propagates to nixos-unstable).

You might also find this video explaining the fixing process for haskellPackages interesting.

@ofborg ofborg bot added the 6.topic: haskell General-purpose, statically typed, purely functional programming language label Feb 17, 2021
@iblech
Copy link
Contributor Author

iblech commented Feb 17, 2021

Ah, I see. Thank you very much for the detailed explanation and the many pointers. I'll have a look at the video, right now the Haskell update process is still a bit of a mystery to me. :-) I'll close this. (Nice to meet over NixOS pull request discussions, @sternenseemann! :-))

@iblech iblech closed this Feb 17, 2021
@ofborg ofborg bot added 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Feb 17, 2021
@sternenseemann
Copy link
Member

If you need agda urgently, nix-shell -p agda -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/haskell-updates.tar.gz should work.

@iblech
Copy link
Contributor Author

iblech commented Feb 17, 2021 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: haskell General-purpose, statically typed, purely functional programming language 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants