Unverified Commit a841820e authored by misuzu's avatar misuzu Committed by GitHub
Browse files

vangers: init at 2.0-unstable-2024-09-30 (#378824)

parents 743152dc 830a2ca7
Loading
Loading
Loading
Loading
+31 −0
Original line number Diff line number Diff line
{
  lib,
  fetchFromGitHub,
  stdenv,
  cmake,
  SDL2,
}:

stdenv.mkDerivation {
  pname = "clunk";
  version = "1.0-unstable-2020-06-25";

  src = fetchFromGitHub {
    owner = "stalkerg";
    repo = "clunk";
    rev = "6d4cbbe1b6f1e202b9945d20073952b254e8d530";
    hash = "sha256-cz6v7rQYIoLf53Od7THmDPmBfhn8DBP7+uOIZRF0gc8=";
  };

  buildInputs = [ SDL2 ];
  nativeBuildInputs = [ cmake ];

  meta = {
    description = "Clunk - real-time binaural sound generation library. Versions for Vangers game. Porting to SDL2 and fix some errors";
    homepage = "https://github.com/stalkerg/clunk";
    platforms = lib.platforms.all;
    license = with lib.licenses; [ lgpl21Plus ];
    maintainers = with lib.maintainers; [ _3JlOy-PYCCKUi ];
  };

}
+55 −0
Original line number Diff line number Diff line
{
  lib,
  fetchFromGitHub,
  callPackage,
  stdenv,
  cmake,
  SDL2,
  SDL2_net,
  libogg,
  libvorbis,
  ffmpeg,
  zlib,
}:

let
  clunk = callPackage ./clunk.nix { };
in
stdenv.mkDerivation {
  pname = "vangers";
  version = "2.0-unstable-2024-09-30";

  src = fetchFromGitHub {
    owner = "KranX";
    repo = "Vangers";
    rev = "72145feed605856c6711bbbcb4f9db99db3434fd";
    hash = "sha256-IhCQh60wBzaRsj72Y8NUHrv9lvss0fmgHjzrO/subOI=";
  };

  buildInputs = [
    SDL2
    SDL2_net
    libogg
    libvorbis
    ffmpeg
    clunk
    zlib
  ];
  nativeBuildInputs = [ cmake ];

  installPhase = ''
    mkdir -p $out/bin
    install -T -m755 server/vangers_server $out/bin/vangers_server
    install -T -m755 src/vangers $out/bin/vangers
    install -T -m755 surmap/surmap $out/bin/surmap
  '';

  meta = {
    description = "The video game that combines elements of the racing and role-playing genres";
    homepage = "https://github.com/KranX/Vangers";
    mainProgram = "vangers";
    platforms = lib.platforms.all;
    license = with lib.licenses; [ gpl3Only ];
    maintainers = with lib.maintainers; [ _3JlOy-PYCCKUi ];
  };
}