2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, SDL2, SDL2_image, SDL2_mixer, SDL2_net, SDL2_ttf
|
2020-04-24 23:36:52 +00:00
|
|
|
, pango, gettext, boost, libvorbis, fribidi, dbus, libpng, pcre, openssl, icu
|
|
|
|
, Cocoa, Foundation
|
|
|
|
, enableTools ? false
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "wesnoth";
|
2021-10-28 06:52:43 +00:00
|
|
|
version = "1.16.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-06-18 07:06:33 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
rev = version;
|
|
|
|
owner = "wesnoth";
|
|
|
|
repo = "wesnoth";
|
2021-10-28 06:52:43 +00:00
|
|
|
sha256 = "sha256-9ZdITKGjCgVy/0CzaPO9+mlGvy/qWXwl4NSGRV7ySb0=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildInputs = [ SDL2 SDL2_image SDL2_mixer SDL2_net SDL2_ttf pango gettext boost
|
|
|
|
libvorbis fribidi dbus libpng pcre openssl icu ]
|
2021-01-15 22:18:51 +00:00
|
|
|
++ lib.optionals stdenv.isDarwin [ Cocoa Foundation];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
cmakeFlags = [ "-DENABLE_TOOLS=${if enableTools then "ON" else "OFF"}" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "The Battle for Wesnoth, a free, turn-based strategy game with a fantasy theme";
|
|
|
|
longDescription = ''
|
|
|
|
The Battle for Wesnoth is a Free, turn-based tactical strategy
|
|
|
|
game with a high fantasy theme, featuring both single-player, and
|
|
|
|
online/hotseat multiplayer combat. Fight a desperate battle to
|
|
|
|
reclaim the throne of Wesnoth, or take hand in any number of other
|
|
|
|
adventures.
|
|
|
|
'';
|
|
|
|
|
2020-06-18 07:06:33 +00:00
|
|
|
homepage = "https://www.wesnoth.org/";
|
2021-09-18 10:52:07 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = with maintainers; [ abbradar ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|