2022-10-14 11:56:16 +03:00
|
|
|
{ fetchFromGitHub, fetchpatch, ncurses, lib, stdenv
|
|
|
|
, updateAutotoolsGnuConfigScriptsHook, installShellFiles }:
|
2017-11-24 03:24:19 +03:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 15:41:18 +03:00
|
|
|
pname = "freesweep";
|
2022-06-29 16:20:35 +03:00
|
|
|
version = "1.0.2";
|
2017-11-24 03:24:19 +03:00
|
|
|
|
2018-11-15 09:48:39 +03:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "rwestlund";
|
|
|
|
repo = "freesweep";
|
|
|
|
rev = "v${version}";
|
2022-06-29 16:20:35 +03:00
|
|
|
hash = "sha256-iuu81yHbNrjdPsimBrPK58PJ0d8i3ySM7rFUG/d8NJM";
|
2017-11-24 03:24:19 +03:00
|
|
|
};
|
|
|
|
|
2022-10-14 11:56:16 +03:00
|
|
|
nativeBuildInputs = [ updateAutotoolsGnuConfigScriptsHook installShellFiles ];
|
2017-11-24 03:24:19 +03:00
|
|
|
buildInputs = [ ncurses ];
|
|
|
|
|
2022-10-14 11:56:16 +03:00
|
|
|
configureFlags = [ "--with-prefsdir=$out/share" ];
|
2017-11-24 03:24:19 +03:00
|
|
|
|
2022-06-29 16:35:07 +03:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2017-11-24 03:24:19 +03:00
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
install -D -m 0555 freesweep $out/bin/freesweep
|
|
|
|
install -D -m 0444 sweeprc $out/share/sweeprc
|
2022-10-14 11:56:16 +03:00
|
|
|
installManPage freesweep.6
|
2017-11-24 03:24:19 +03:00
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
2021-01-11 10:54:33 +03:00
|
|
|
meta = with lib; {
|
2017-11-24 03:24:19 +03:00
|
|
|
description = "A console minesweeper-style game written in C for Unix-like systems";
|
2020-04-01 04:11:51 +03:00
|
|
|
homepage = "https://github.com/rwestlund/freesweep";
|
2017-11-24 03:24:19 +03:00
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ kierdavis ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|