summaryrefslogtreecommitdiff
path: root/app-accessibility/freetts
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-07-07 12:24:47 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-07-07 12:24:47 +0100
commit5d8ffbc273ca664e15618d557ced3e02de1a884b (patch)
treebc22fbc6a07790fd70dc8b5148de3089a1c4db3e /app-accessibility/freetts
parent4187bba080530c5ca1c7dae9c233e88f3fc8f535 (diff)
gentoo auto-resync : 07:07:2024 - 12:24:46
Diffstat (limited to 'app-accessibility/freetts')
-rw-r--r--app-accessibility/freetts/Manifest2
-rw-r--r--app-accessibility/freetts/files/freetts-1.2.2-source-target.patch34
-rw-r--r--app-accessibility/freetts/freetts-1.2.2-r3.ebuild96
3 files changed, 132 insertions, 0 deletions
diff --git a/app-accessibility/freetts/Manifest b/app-accessibility/freetts/Manifest
index 9c3fd5b4de0a..194bc8605456 100644
--- a/app-accessibility/freetts/Manifest
+++ b/app-accessibility/freetts/Manifest
@@ -1,4 +1,6 @@
+AUX freetts-1.2.2-source-target.patch 1243 BLAKE2B 7d840d67ecdab9aa25ac323d28395919b5bb59594722631d2d2346ead8706d5e27aaf3d06258b1fb688ce6b5af120fd256dbd0ab805434f2751d17ceb8718a7a SHA512 e7f485d3ca5eab047cf03b56708abca646b13b64183b28bd58c1f9fb38eb518f82a0b9548524ac58a703622903fc17e360975949269a4550a3879e15aeec9da1
AUX jsapi-gentoo.diff 10456 BLAKE2B c0de49a34fe6e5240f4a1c895b99593a169a3a14fe7c3b98cc62723d34b31935735e9632f599b90748a760a448860ae81d2a1e48de6f1074633d33e19c5158d3 SHA512 62acd90cb064db176ee7a0950857c173f2ace4de6a6319fce3273bcbb222f8fd309bc6939eaba00a00cd7217871dca60cfa33d5ee1396b86333b9dedbf8f3034
DIST freetts-1.2.2-src.zip 14111416 BLAKE2B fd3ac79ffe3ca031d40a6523a4ae900200c1b1eea0369fd1eec3233f852af8edffd81ca6c0bba628132221346d283d2138794e1f9697074fc1044944ad852e5b SHA512 a2cce0b1fd2267cc8dbd3e2ad3ec1f99526de3988443c0937405cc7b2eab9ef517001ef0b4b387e8721d3c33610cd642c6b7cf83217996a83481830de9713de7
EBUILD freetts-1.2.2-r2.ebuild 1912 BLAKE2B 6a6991cfa8fe2501bb42c24900c1d2428fc5c03870f71882c16e985118be03b74a2848b3f31acc18356b6836bd32dca0d5249fbdc947bdcd01c276d3627b0b0d SHA512 3c7cffa08290d6a022b23c0606e61aa7949ab4c81b41e21f83e74b7104b291e36cd2374b82f66c2ce15e99e3bcddb4e18ed3b6db8de79acf3cad439c9942df10
+EBUILD freetts-1.2.2-r3.ebuild 2142 BLAKE2B 60fa356d6ebb94a4d469c05b2679cf635be77749aaddebdc3d705dc6eb2c187a0c90e58d376b6209dc6564f4f0d3d277365a7d7df4d98e3a58abe5e1c6b9f892 SHA512 e2079ced82cbed9554e235af1bb0183cbd4d15a30542de202a8e44246f30fffd23f1b816ed42556903d2690f776d6ee64d6b1a625f9de59a02ade97ac58d33b8
MISC metadata.xml 577 BLAKE2B f7cfecae90f4d576518ffdfeefadfe143bd292cdf0dbc7742fdc3ff02b829e3625de02c6e88eca1e93cbfd4266f0bd64a787a609c939cfc22e37627542374bdb SHA512 75d441047de45d4747911f2a2c09dd52599b84805e79ce540df206bda354aec9da3005328f379a49562ff107afd02ed72555522c556410dc92d69a3e9408689d
diff --git a/app-accessibility/freetts/files/freetts-1.2.2-source-target.patch b/app-accessibility/freetts/files/freetts-1.2.2-source-target.patch
new file mode 100644
index 000000000000..0d7f6afe134b
--- /dev/null
+++ b/app-accessibility/freetts/files/freetts-1.2.2-source-target.patch
@@ -0,0 +1,34 @@
+We want to get rid of rewrite-xml provided by javatoolkit.
+
+--- a/build.xml
++++ b/build.xml
+@@ -124,7 +124,8 @@ jsapi.exe from the lib directory.
+ description="Build just the srcs">
+ <mkdir dir="${classes_dir}" />
+ <javac debug="true"
+- source="1.4"
++ source="8"
++ target="8"
+ deprecation="true"
+ srcdir="${src_dir}"
+ excludes="tests/**"
+@@ -145,7 +146,8 @@ jsapi.exe from the lib directory.
+ description="Build just the tests">
+ <mkdir dir="${classes_dir}" />
+ <javac debug="true"
+- source="1.4"
++ source="8"
++ target="8"
+ deprecation="true"
+ srcdir="${src_dir}"
+ includes="tests/**"
+@@ -904,7 +906,8 @@ jsapi.exe from the lib directory.
+ <target name="javadoc" description="Generate javadoc">
+ <mkdir dir="${javadoc_dir}" />
+ <javadoc sourcepath="${src_dir}"
+- source="1.4"
++ source="8"
++ target="8"
+ additionalparam="-breakiterator"
+ destdir="${javadoc_dir}"
+ packagenames="${javadoc_pkgs}"
diff --git a/app-accessibility/freetts/freetts-1.2.2-r3.ebuild b/app-accessibility/freetts/freetts-1.2.2-r3.ebuild
new file mode 100644
index 000000000000..b0585d04836c
--- /dev/null
+++ b/app-accessibility/freetts/freetts-1.2.2-r3.ebuild
@@ -0,0 +1,96 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+JAVA_PKG_IUSE="doc examples source"
+
+inherit java-pkg-2
+
+DESCRIPTION="A speech synthesis system written entirely in Java"
+HOMEPAGE="https://freetts.sourceforge.io/"
+SRC_URI="https://downloads.sourceforge.net/project/freetts/FreeTTS/FreeTTS%20${PV}/${P}-src.zip"
+
+LICENSE="jsapi? ( sun-bcla-jsapi ) freetts"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86"
+IUSE="jsapi mbrola"
+
+BDEPEND="app-arch/unzip"
+
+DEPEND="virtual/jdk:1.8
+ >=dev-java/ant-1.10.14-r3:0
+ jsapi? ( app-arch/sharutils )
+ mbrola? ( >=app-accessibility/mbrola-3.0.1h-r6 ) "
+
+# Exception in thread "main" java.lang.ClassCastException
+RDEPEND="virtual/jre:1.8
+ mbrola? ( >=app-accessibility/mbrola-3.0.1h-r6 ) "
+
+# Tests aren't present.
+RESTRICT="test"
+
+PATCHES=(
+ "${FILESDIR}"/jsapi-gentoo.diff
+ "${FILESDIR}/freetts-1.2.2-source-target.patch"
+)
+
+DOCS=( ANNOUNCE.txt README.txt RELEASE_NOTES )
+
+src_prepare() {
+ default #780585
+ java-pkg-2_src_prepare
+
+ # Prepare source directory.
+ mkdir src || die "Failed to create source directory."
+ mv com de src/ || die "Failed to move files to source directory."
+
+ # Prepare library directory.
+ cd lib || die "Lib directory not present."
+ chmod 0755 jsapi.sh || die "jsapi.sh not present or can't change permissions."
+
+ use mbrola && echo "mbrola.base=/usr/share/mbrola/" >> "${S}"/speech.properties
+}
+
+src_compile() {
+ if use jsapi; then
+ pushd lib
+ ./jsapi.sh || die "jsapi.sh failed"
+ popd
+ fi
+
+ eant jars
+}
+
+# Tests aren't present.
+# http://freetts.sourceforge.net/docs/index.php#how_test
+#src_test() {
+# ANT_TASKS="ant-junit" eant junit
+#}
+
+src_install() {
+ default
+ java-pkg_dojar lib/*.jar mbrola/*.jar
+
+ use mbrola && local jflags="--java_args -Dmbrola.base=/usr/share/mbrola"
+
+ java-pkg_dolauncher ${PN} --main com.sun.speech.freetts.FreeTTS ${jflags}
+
+ insinto /usr/share/${PN}
+ doins speech.properties
+ doins -r tools
+
+ if use doc ; then
+ docinto html
+ dodoc -r docs/*
+ java-pkg_dojavadoc javadoc
+ fi
+
+ if use examples ; then
+ java-pkg_doexamples demo
+ fi
+
+ if use source ; then
+ java-pkg_dosrc src/*
+ fi
+}