about summary refs log tree commit diff
path: root/pkgs/games/mar1d/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/games/mar1d/default.nix')
-rw-r--r--pkgs/games/mar1d/default.nix16
1 files changed, 13 insertions, 3 deletions
diff --git a/pkgs/games/mar1d/default.nix b/pkgs/games/mar1d/default.nix
index b069e3fecc46a..0bd6026e32d68 100644
--- a/pkgs/games/mar1d/default.nix
+++ b/pkgs/games/mar1d/default.nix
@@ -8,15 +8,16 @@
 , ninja
 , pkg-config
 , fetchFromGitHub
+, fetchpatch
 }:
 
 stdenv.mkDerivation rec {
   pname = "MAR1D";
-  version = "0.3.1";
+  version = "unstable-2023-02-02";
 
   src = fetchFromGitHub {
-    sha256 = "sha256-c48azBGdnzhEQGUeRJWlNLJhtrYjnpiORuWvowcQK5Y=";
-    rev = "v${version}";
+    hash = "sha256-kZERhwnTpBhjx6MLdf1bYCWMjtTiId/5a69kRt+/6oY=";
+    rev = "fa5dc36e1819a15539ced339ad01672e5a498c5c";
     repo = "MAR1D";
     owner = "Radvendii";
   };
@@ -30,6 +31,15 @@ stdenv.mkDerivation rec {
     libGLU
   ];
 
+  patches = [
+    # Fix the build on Darwin.
+    # https://github.com/Radvendii/MAR1D/pull/4
+    (fetchpatch {
+      url = "https://github.com/Radvendii/MAR1D/commit/baf3269e90eca69f154a43c4c1ef14677a6300fd.patch";
+      hash = "sha256-ybdLA2sO8e0J7w4roSdMWn72OkttD3y+cJ3ScuGiHCI=";
+    })
+  ];
+
   meta = with lib; {
     description = "First person Super Mario Bros";
     mainProgram = "MAR1D";