lol
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

at 23.11-beta 61 lines 1.4 kB view raw
1{ lib, stdenv, fetchFromGitHub, raylib, darwin }: 2 3let 4 inherit (darwin.apple_sdk.frameworks) Cocoa; 5in 6stdenv.mkDerivation rec { 7 pname = "raylib-games"; 8 version = "2022-10-24"; 9 10 src = fetchFromGitHub { 11 owner = "raysan5"; 12 repo = pname; 13 rev = "e00d77cf96ba63472e8316ae95a23c624045dcbe"; 14 hash = "sha256-N9ip8yFUqXmNMKcvQuOyxDI4yF/w1YaoIh0prvS4Xr4="; 15 }; 16 17 buildInputs = [ raylib ] 18 ++ lib.optionals stdenv.isDarwin [ Cocoa ]; 19 20 configurePhase = '' 21 runHook preConfigure 22 for d in *; do 23 if [ -d $d/src/resources ]; then 24 for f in $d/src/*.c $d/src/*.h; do 25 sed "s|\"resources/|\"$out/resources/$d/|g" -i $f 26 done 27 fi 28 done 29 runHook postConfigure 30 ''; 31 32 buildPhase = '' 33 runHook preBuild 34 for d in *; do 35 if [ -f $d/src/Makefile ]; then 36 make -C $d/src 37 fi 38 done 39 runHook postBuild 40 ''; 41 42 installPhase = '' 43 runHook preBuild 44 mkdir -p $out/bin $out/resources 45 find . -type f -executable -exec cp {} $out/bin \; 46 for d in *; do 47 if [ -d "$d/src/resources" ]; then 48 cp -ar "$d/src/resources" "$out/resources/$d" 49 fi 50 done 51 runHook postBuild 52 ''; 53 54 meta = with lib; { 55 description = "A collection of games made with raylib "; 56 homepage = "https://www.raylib.com/games.html"; 57 license = licenses.zlib; 58 maintainers = with maintainers; [ ehmry ]; 59 inherit (raylib.meta) platforms; 60 }; 61}