about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/tools/gdtoolkit/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/tools/gdtoolkit/default.nix')
-rw-r--r--nixpkgs/pkgs/development/tools/gdtoolkit/default.nix41
1 files changed, 23 insertions, 18 deletions
diff --git a/nixpkgs/pkgs/development/tools/gdtoolkit/default.nix b/nixpkgs/pkgs/development/tools/gdtoolkit/default.nix
index 479b0b2c3636..ea5e5ec8de9a 100644
--- a/nixpkgs/pkgs/development/tools/gdtoolkit/default.nix
+++ b/nixpkgs/pkgs/development/tools/gdtoolkit/default.nix
@@ -1,23 +1,28 @@
 { lib
-, python3Packages
+, python3
 , fetchFromGitHub
 , godot3-server
 }:
 
-let lark080 = python3Packages.lark.overrideAttrs (old: rec {
-  # gdtoolkit needs exactly this lark version
-  version = "0.8.0";
-  src = fetchFromGitHub {
-    owner = "lark-parser";
-    repo = "lark";
-    rev = version;
-    hash = "sha256-KN9buVlH8hJ8t0ZP5yefeYM5vH5Gg7a7TEDGKJYpozs=";
-    fetchSubmodules = true;
+let
+  python = python3.override {
+    packageOverrides = self: super: {
+      lark = super.lark.overridePythonAttrs (old: rec {
+        # gdtoolkit needs exactly this lark version
+        version = "0.8.0";
+        src = fetchFromGitHub {
+          owner = "lark-parser";
+          repo = "lark";
+          rev = version;
+          hash = "sha256-KN9buVlH8hJ8t0ZP5yefeYM5vH5Gg7a7TEDGKJYpozs=";
+          fetchSubmodules = true;
+        };
+        patches = [ ];
+      });
+    };
   };
-});
-
 in
-python3Packages.buildPythonApplication rec {
+python.pkgs.buildPythonApplication rec {
   pname = "gdtoolkit";
   version = "3.3.1";
 
@@ -29,18 +34,18 @@ python3Packages.buildPythonApplication rec {
     sha256 = "13nnpwy550jf5qnm9ixpxl1bwfnhhbiys8vqfd25g3aim4bm3gnn";
   };
 
-  disabled = python3Packages.pythonOlder "3.7";
+  disabled = python.pythonOlder "3.7";
 
-  propagatedBuildInputs = [ lark080
-  ] ++ (with python3Packages; [
+  propagatedBuildInputs = with python.pkgs; [
     docopt
+    lark
     pyyaml
     setuptools
-  ]);
+  ];
 
   doCheck = true;
 
-  nativeCheckInputs = with python3Packages; [
+  nativeCheckInputs = with python.pkgs; [
     pytestCheckHook
     hypothesis
     godot3-server