2023-07-15 17:15:38 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
2024-07-01 15:47:52 +00:00
|
|
|
, qt6
|
2023-07-15 17:15:38 +00:00
|
|
|
, wrapQtAppsHook
|
|
|
|
|
|
|
|
# before that => zeal
|
|
|
|
, sqlite
|
|
|
|
, json_c
|
|
|
|
, mecab
|
|
|
|
, libzip
|
|
|
|
, mpv
|
|
|
|
, yt-dlp
|
|
|
|
# optional
|
|
|
|
, makeWrapper}:
|
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
|
|
pname = "memento";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "1.4.1";
|
2023-07-15 17:15:38 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ripose-jp";
|
|
|
|
repo = "Memento";
|
2023-08-22 20:05:09 +00:00
|
|
|
rev = "v${finalAttrs.version}";
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-3WOtf7cgYxAMlNPSBmTzaQF1HN9mU61giLp2woBAidY=";
|
2023-07-15 17:15:38 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
makeWrapper
|
|
|
|
wrapQtAppsHook
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
2024-07-01 15:47:52 +00:00
|
|
|
qt6.qtbase
|
|
|
|
qt6.qtsvg
|
|
|
|
qt6.qtwayland
|
2023-07-15 17:15:38 +00:00
|
|
|
sqlite
|
|
|
|
json_c
|
|
|
|
libzip
|
|
|
|
mecab
|
2024-07-01 15:47:52 +00:00
|
|
|
];
|
2023-07-15 17:15:38 +00:00
|
|
|
|
2024-07-01 15:47:52 +00:00
|
|
|
propagatedBuildInputs = [ mpv ];
|
2023-07-15 17:15:38 +00:00
|
|
|
|
|
|
|
preFixup = ''
|
|
|
|
wrapProgram "$out/bin/memento" \
|
|
|
|
--prefix PATH : "${yt-dlp}/bin" \
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Mpv-based video player for studying Japanese";
|
2023-07-15 17:15:38 +00:00
|
|
|
homepage = "https://ripose-jp.github.io/Memento/";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ teto ];
|
|
|
|
platforms = platforms.linux;
|
2024-01-02 11:29:13 +00:00
|
|
|
mainProgram = "memento";
|
2023-07-15 17:15:38 +00:00
|
|
|
};
|
|
|
|
})
|
|
|
|
|