Skip to content

Commit

Permalink
anki: Use fetchpatch for python compatibilty patch
Browse files Browse the repository at this point in the history
  • Loading branch information
binarin committed Dec 1, 2018
1 parent 8d61b9d commit 19bffee
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 24 deletions.
12 changes: 11 additions & 1 deletion pkgs/games/anki/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
, lib
, python
, fetchurl
, fetchpatch
, lame
, mplayer
, libpulseaudio
Expand Down Expand Up @@ -53,7 +54,16 @@ buildPythonApplication rec {
patches = [
# Disable updated version check.
./no-version-check.patch
./python-3.7-compat.patch

# This is needed to fix python 3.7 compatibilty, where the
# behaviour of `re.escape()` was changed in a way that it no
# longer escapes `%`. This patch detects this difference at
# runtime and makes anki work with any python version.
# Upstream PR: https://github.com/dae/anki/pull/266
(fetchpatch {
url = "https://github.com/dae/anki/commit/3d69aa9ce454a151ba75deafd7de117af2c7307d.patch";
sha256 = "0kf9gajhy0wcajp24xfia71z6gn1mc4vl37svvq4sqbhj3gigd0h";
})
];

buildPhase = ''
Expand Down
23 changes: 0 additions & 23 deletions pkgs/games/anki/python-3.7-compat.patch

This file was deleted.

0 comments on commit 19bffee

Please sign in to comment.