nixpkgs/pkgs/games/vassal/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

57 lines
1.2 KiB
Nix
Raw Normal View History

{ lib
, stdenv
, fetchzip
, glib
, jre
, makeWrapper
, wrapGAppsHook
}:
2016-01-23 02:42:51 +01:00
stdenv.mkDerivation rec {
pname = "VASSAL";
2023-11-15 07:12:21 +01:00
version = "3.7.5";
2016-01-23 02:42:51 +01:00
src = fetchzip {
url = "https://github.com/vassalengine/vassal/releases/download/${version}/${pname}-${version}-linux.tar.bz2";
2023-11-15 07:12:21 +01:00
sha256 = "sha256-6TXpUsQBzhZ02SCbCqZW2LZfQ370Ma57bsblmpgZmoc=";
2016-01-23 02:42:51 +01:00
};
buildInputs = [
glib
];
nativeBuildInputs = [
makeWrapper
wrapGAppsHook
];
2016-01-23 02:42:51 +01:00
installPhase = ''
runHook preInstall
2016-01-23 02:42:51 +01:00
mkdir -p $out/bin $out/share/vassal $out/doc
cp CHANGES LICENSE README.md $out
2016-01-23 02:42:51 +01:00
cp -R lib/* $out/share/vassal
cp -R doc/* $out/doc
makeWrapper ${jre}/bin/java $out/bin/vassal \
--add-flags "-Duser.dir=$out -cp $out/share/vassal/Vengine.jar \
VASSAL.launch.ModuleManager"
runHook postInstall
2016-01-23 02:42:51 +01:00
'';
# Don't move doc to share/, VASSAL expects it to be in the root
forceShare = [ "man" "info" ];
meta = with lib; {
2016-02-01 14:00:45 +01:00
description = "A free, open-source boardgame engine";
homepage = "https://vassalengine.org/";
sourceProvenance = with sourceTypes; [ binaryBytecode ];
license = licenses.lgpl21Only;
2016-01-23 02:42:51 +01:00
maintainers = with maintainers; [ tvestelind ];
2021-03-12 06:21:42 +01:00
platforms = platforms.unix;
2023-01-25 12:28:27 +01:00
mainProgram = "vassal";
2016-01-23 02:42:51 +01:00
};
}