Merge pull request #189886 from sikmir/crow-translate
crow-translate: 2.9.12 → 2.10.0
This commit is contained in:
commit
81e8d08ce7
|
@ -12,15 +12,18 @@
|
|||
, qtx11extras
|
||||
, qttranslations
|
||||
, wrapQtAppsHook
|
||||
, gst_all_1
|
||||
, testers
|
||||
, crow-translate
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "crow-translate";
|
||||
version = "2.9.12";
|
||||
version = "2.10.0";
|
||||
|
||||
src = fetchzip {
|
||||
url = "https://github.com/${pname}/${pname}/releases/download/${version}/${pname}-${version}-source.tar.gz";
|
||||
hash = "sha256-JkAykc5j5HMkK48qAm876A2zBD095CG/yR4TyXAdevM=";
|
||||
hash = "sha256-ayEt4PI15NjlmFrDEa6Ipbn94nN9Ga7jThnIVBWPgKw=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
|
@ -31,6 +34,11 @@ stdenv.mkDerivation rec {
|
|||
})
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace data/io.crow_translate.CrowTranslate.desktop \
|
||||
--replace "Exec=qdbus" "Exec=${lib.getBin qttools}/bin/qdbus"
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
extra-cmake-modules
|
||||
|
@ -44,18 +52,27 @@ stdenv.mkDerivation rec {
|
|||
tesseract4
|
||||
qtmultimedia
|
||||
qtx11extras
|
||||
];
|
||||
] ++ (with gst_all_1; [
|
||||
gstreamer
|
||||
gst-plugins-base
|
||||
gst-plugins-good
|
||||
gst-plugins-bad
|
||||
]);
|
||||
|
||||
postInstall = ''
|
||||
substituteInPlace $out/share/applications/io.crow_translate.CrowTranslate.desktop \
|
||||
--replace "Exec=qdbus" "Exec=${lib.getBin qttools}/bin/qdbus"
|
||||
preFixup = ''
|
||||
qtWrapperArgs+=(--prefix GST_PLUGIN_SYSTEM_PATH_1_0 : "$GST_PLUGIN_SYSTEM_PATH_1_0")
|
||||
'';
|
||||
|
||||
passthru.tests.version = testers.testVersion {
|
||||
package = crow-translate;
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "A simple and lightweight translator that allows to translate and speak text using Google, Yandex and Bing";
|
||||
homepage = "https://crow-translate.github.io/";
|
||||
license = licenses.gpl3Plus;
|
||||
maintainers = with maintainers; [ sikmir ];
|
||||
platforms = platforms.linux;
|
||||
mainProgram = "crow";
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue