anarch: init at 1.0-unstable-2023-09-08 (#380714)

authored by Gaétan Lepage and committed by GitHub cb6f8782 44d39eaa

+55
+55
pkgs/by-name/an/anarch/package.nix
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchFromGitLab, 5 + SDL2, 6 + xorg, 7 + }: 8 + 9 + stdenv.mkDerivation (finalAttrs: { 10 + pname = "anarch"; 11 + version = "1.0-unstable-2023-09-08"; 12 + 13 + src = fetchFromGitLab { 14 + owner = "drummyfish"; 15 + repo = "anarch"; 16 + rev = "6f90562161200682459e772f1dacb747f23c5f95"; 17 + hash = "sha256-KmuJruzQRFunhwUGz3bHhXgtD2m4+5Vk0n7xhzVBMWs="; 18 + }; 19 + 20 + buildInputs = [ 21 + SDL2 22 + xorg.libXcursor 23 + xorg.libXrandr 24 + xorg.libXfixes 25 + xorg.libXext 26 + xorg.libXi 27 + xorg.libXScrnSaver 28 + ]; 29 + 30 + # upstream is an error-prone make/build script 31 + buildPhase = '' 32 + runHook preBuild 33 + 34 + $CC -O3 -o anarch main_sdl.c $(sdl2-config --cflags --libs) 35 + 36 + runHook postBuild 37 + ''; 38 + 39 + installPhase = '' 40 + runHook preInstall 41 + 42 + install -Dm755 anarch $out/bin/anarch 43 + 44 + runHook postInstall 45 + ''; 46 + 47 + meta = { 48 + homepage = "https://drummyfish.gitlab.io/anarch/"; 49 + description = "Suckless FPS game"; 50 + maintainers = with lib.maintainers; [ ethancedwards8 ]; 51 + license = lib.licenses.cc0; 52 + platforms = lib.platforms.unix; 53 + mainProgram = "anarch"; 54 + }; 55 + })