Skip to content

Commit

Permalink
memento: init at v1.1.0
Browse files Browse the repository at this point in the history
a reader with kanji reading

There is an optional manga-ocr dependency that I would like to support
but in a second time see ripose-jp/Memento#159
  • Loading branch information
teto committed May 24, 2023
1 parent 897876e commit 1f00859
Show file tree
Hide file tree
Showing 2 changed files with 65 additions and 0 deletions.
63 changes: 63 additions & 0 deletions 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;
};
})

2 changes: 2 additions & 0 deletions pkgs/top-level/all-packages.nix
Expand Up @@ -32402,6 +32402,8 @@ with pkgs;

mailspring = callPackage ../applications/networking/mailreaders/mailspring { };

memento = libsForQt5.callPackage ../applications/video/memento { };

mm = callPackage ../applications/networking/instant-messengers/mm { };

mm-common = callPackage ../development/libraries/mm-common { };
Expand Down

0 comments on commit 1f00859

Please sign in to comment.