2021-07-03 03:11:41 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, qtbase
|
|
|
|
, qtdeclarative
|
|
|
|
, cmake
|
|
|
|
, texlive
|
|
|
|
, ninja
|
2024-04-21 15:54:59 +00:00
|
|
|
, version ? "42.1.5"
|
|
|
|
, hash ? "sha256-aUakfUjnIZWNDhCkG3A6u7BaaCG8kPMV/Fu2S73CoDg="
|
2021-07-03 03:11:41 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "dwarf-therapist";
|
2024-04-21 15:54:59 +00:00
|
|
|
|
|
|
|
inherit version;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Dwarf-Therapist";
|
|
|
|
repo = "Dwarf-Therapist";
|
|
|
|
rev = "v${version}";
|
2024-04-21 15:54:59 +00:00
|
|
|
inherit hash;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ texlive cmake ninja ];
|
|
|
|
buildInputs = [ qtbase qtdeclarative ];
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
cmakeFlags = [ "-GNinja" ];
|
|
|
|
|
2021-07-03 03:11:41 +00:00
|
|
|
installPhase =
|
|
|
|
if stdenv.isDarwin then ''
|
|
|
|
mkdir -p $out/Applications
|
|
|
|
cp -r DwarfTherapist.app $out/Applications
|
|
|
|
'' else null;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-19 19:06:45 +00:00
|
|
|
dontWrapQtApps = true;
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "dwarftherapist";
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Tool to manage dwarves in a running game of Dwarf Fortress";
|
2020-05-15 21:57:56 +00:00
|
|
|
maintainers = with maintainers; [ abbradar bendlas numinit jonringer ];
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.mit;
|
2022-11-21 17:40:18 +00:00
|
|
|
platforms = platforms.x86;
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/Dwarf-Therapist/Dwarf-Therapist";
|
|
|
|
};
|
|
|
|
}
|