diff options
author | Matthieu Coudron <mcoudron@hotmail.com> | 2023-05-09 02:13:33 +0200 |
---|---|---|
committer | Matthieu Coudron <teto@users.noreply.github.com> | 2023-05-25 21:32:33 +0200 |
commit | ef1e697b5509d0e78e922bfa8401ba953ae5152b (patch) | |
tree | c0530a611c7a73d731d941a427a354157dcabf2e /pkgs/applications/video/memento | |
parent | a9cf9a909f2b2ca445e73382a4f63f5a7bd46832 (diff) |
memento: init at v1.1.0
a reader with kanji reading There is an optional manga-ocr dependency that I would like to support but in a second time see https://github.com/ripose-jp/Memento/issues/159
Diffstat (limited to 'pkgs/applications/video/memento')
-rw-r--r-- | pkgs/applications/video/memento/default.nix | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/pkgs/applications/video/memento/default.nix b/pkgs/applications/video/memento/default.nix new file mode 100644 index 0000000000000..fabcc84fef3ad --- /dev/null +++ b/pkgs/applications/video/memento/default.nix @@ -0,0 +1,63 @@ +{ lib +, stdenv +, fetchFromGitHub +, cmake +, qtbase +, qtx11extras ? null # qt5 only +, wrapQtAppsHook + +# before that => zeal +, sqlite +, json_c +, mecab +, libzip +, mpv +, yt-dlp +# optional +, makeWrapper}: + +let + isQt5 = lib.versions.major qtbase.version == "5"; + +in +stdenv.mkDerivation (finalAttrs: { + pname = "memento"; + version = "v1.1.0"; + + src = fetchFromGitHub { + owner = "ripose-jp"; + repo = "Memento"; + rev = finalAttrs.version; + hash = "sha256-29AzQ+Z2PNs65Tvmt2Z5Ra2G3Yhm4LVBpAqvnSsnE0Y="; + }; + + nativeBuildInputs = [ + cmake + makeWrapper + wrapQtAppsHook + ]; + + buildInputs = [ + qtbase + sqlite + json_c + libzip + mecab + ] ++ lib.optionals isQt5 [ qtx11extras ]; + + propagatedBuildInputs = [ mpv ]; + + preFixup = '' + wrapProgram "$out/bin/memento" \ + --prefix PATH : "${yt-dlp}/bin" \ + ''; + + meta = with lib; { + description = "An mpv-based video player for studying Japanese"; + homepage = "https://ripose-jp.github.io/Memento/"; + license = licenses.gpl2; + maintainers = with maintainers; [ teto ]; + platforms = platforms.linux; + }; +}) + |