2022-01-22 01:22:15 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, SDL2, cmake, makeWrapper }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "OttoMatic";
|
|
|
|
version = "4.0.0";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "jorio";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2022-06-16 17:23:12 +00:00
|
|
|
sha256 = "sha256-eHy5yED5qrgHqKuqq1dXhmuR2PQBE5aMhSLPoydlpPk=";
|
2022-01-22 01:22:15 +00:00
|
|
|
fetchSubmodules = true;
|
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
SDL2
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
makeWrapper
|
|
|
|
];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
mkdir -p $out/share/OttoMatic
|
|
|
|
mv Data $out/share/OttoMatic
|
|
|
|
install -Dm755 {.,$out/bin}/OttoMatic
|
2022-04-27 09:35:20 +00:00
|
|
|
wrapProgram $out/bin/OttoMatic --chdir "$out/share/OttoMatic"
|
2022-01-22 01:22:15 +00:00
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A port of Otto Matic, a 2001 Macintosh game by Pangea Software, for modern operating systems";
|
|
|
|
homepage = "https://github.com/jorio/OttoMatic";
|
|
|
|
license = with licenses; [
|
|
|
|
cc-by-sa-40
|
|
|
|
];
|
|
|
|
maintainers = with maintainers; [ lux ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|