about summary refs log tree commit diff
path: root/pkgs/by-name/gu
diff options
context:
space:
mode:
authorAnderson Torres <torres.anderson.85@protonmail.com>2024-05-10 20:18:10 -0300
committerAnderson Torres <torres.anderson.85@protonmail.com>2024-06-04 08:19:10 -0300
commit7acf24e0932b2320234ef932658b06f5df6c0e0e (patch)
tree0a4e2562bd68ad75e7ba55f548900589d87ca44d /pkgs/by-name/gu
parenta5ca567c5e9cb44dc4b867e9f9dfa9bee6e42efc (diff)
guile-sdl: refactor and fixup
- finalAttrs
- Call getDev for all SDL-related build inputs
Diffstat (limited to 'pkgs/by-name/gu')
-rw-r--r--pkgs/by-name/gu/guile-sdl/package.nix54
1 files changed, 28 insertions, 26 deletions
diff --git a/pkgs/by-name/gu/guile-sdl/package.nix b/pkgs/by-name/gu/guile-sdl/package.nix
index 75ca3d8e4aa4d..27adc43a67aa9 100644
--- a/pkgs/by-name/gu/guile-sdl/package.nix
+++ b/pkgs/by-name/gu/guile-sdl/package.nix
@@ -1,60 +1,62 @@
-{ lib
-, stdenv
-, fetchurl
-, guile
-, lzip
-, pkg-config
-, SDL
-, SDL_image
-, SDL_mixer
-, SDL_ttf
-, buildEnv
+{
+  lib,
+  SDL,
+  SDL_image,
+  SDL_mixer,
+  SDL_ttf,
+  buildEnv,
+  fetchurl,
+  guile,
+  lzip,
+  pkg-config,
+  stdenv,
 }:
 
-stdenv.mkDerivation rec {
+stdenv.mkDerivation (finalAttrs: {
   pname = "guile-sdl";
   version = "0.6.1";
 
   src = fetchurl {
-    url = "mirror://gnu/${pname}/${pname}-${version}.tar.lz";
+    url = "mirror://gnu/guile-sdl/guile-sdl-${finalAttrs.version}.tar.lz";
     hash = "sha256-/9sTTvntkRXck3FoRalROjqUQC8hkePtLTnHNZotKOE=";
   };
 
-  strictDeps = true;
-
   nativeBuildInputs = [
+    SDL
     guile
     lzip
     pkg-config
-    SDL
   ];
 
   buildInputs = [
-    guile
     (lib.getDev SDL)
-    SDL_image
-    SDL_mixer
-    SDL_ttf
+    (lib.getDev SDL_image)
+    (lib.getDev SDL_mixer)
+    (lib.getDev SDL_ttf)
+    guile
   ];
 
   makeFlags =
     let
       sdl-env = buildEnv {
         name = "sdl-env";
-        paths = buildInputs;
+        paths = finalAttrs.buildInputs;
       };
     in
     [
       "SDLMINUSI=-I${sdl-env}/include/SDL"
     ];
 
-  meta = with lib; {
+  strictDeps = true;
+
+  meta = {
     homepage = "https://www.gnu.org/software/guile-sdl/";
     description = "Guile bindings for SDL";
-    license = licenses.gpl3Plus;
-    maintainers = with maintainers; [ vyp ];
-    platforms = guile.meta.platforms;
     # configure: error: *** SDL version  not found!
     broken = stdenv.isDarwin;
+    license = lib.licenses.gpl3Plus;
+    maintainers = lib.teams.sdl.members
+                  ++ (with lib.maintainers; [ vyp ]);
+    inherit (guile.meta) platforms;
   };
-}
+})