Jan Tojnar
2022-01-09 02:17:11 +01:00
parent d53d2147ef
commit 3ace1a91ec
+8 -24
View File
@@ -1,8 +1,8 @@
{ lib, stdenv
{ stdenv
, lib
, substituteAll
, pkg-config
, fetchurl
, fetchpatch
, python3Packages
, gettext
, itstool
@@ -27,24 +27,13 @@
let
inherit (lib) optional optionals;
inherit (python3Packages) python pyxdg wrapPython;
# speechd hard-codes espeak, even when built without support for it.
selectedDefaultModule =
if withEspeak then
"espeak-ng"
else if withPico then
"pico"
else if withFlite then
"flite"
else
throw "You need to enable at least one output module.";
in stdenv.mkDerivation rec {
pname = "speech-dispatcher";
version = "0.10.2";
version = "0.11.1";
src = fetchurl {
url = "https://github.com/brailcom/speechd/releases/download/${version}/${pname}-${version}.tar.gz";
sha256 = "sha256-sGMZ8gHhXlbGKWZTr1vPwwDLNI6XLVF9+LBurHfq4tw=";
sha256 = "sha256-0doS7T2shPE3mbai7Dm6LTyiGoST9E3BhVvQupbC3cY=";
};
patches = [
@@ -52,13 +41,6 @@ in stdenv.mkDerivation rec {
src = ./fix-paths.patch;
utillinux = util-linux;
})
# Fix build with Glib 2.68
# https://github.com/brailcom/speechd/pull/462
(fetchpatch {
url = "https://github.com/brailcom/speechd/commit/a2faab416e42cbdf3d73f98578a89eb7a235e25a.patch";
sha256 = "8Q7tUdKKBBtgXZZnj59OcJOkrCNeBR9gkBjhKlpW0hQ=";
})
];
nativeBuildInputs = [
@@ -108,7 +90,6 @@ in stdenv.mkDerivation rec {
;
postPatch = ''
substituteInPlace config/speechd.conf --replace "DefaultModule espeak" "DefaultModule ${selectedDefaultModule}"
substituteInPlace src/modules/pico.c --replace "/usr/share/pico/lang" "${svox}/share/pico/lang"
'';
@@ -122,7 +103,10 @@ in stdenv.mkDerivation rec {
description = "Common interface to speech synthesis";
homepage = "https://devel.freebsoft.org/speechd";
license = licenses.gpl2Plus;
maintainers = with maintainers; [ berce ];
maintainers = with maintainers; [
berce
jtojnar
];
platforms = platforms.linux;
};
}