1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-21 04:06:46 +00:00

Fix support for RealPeopleTTS

Use xdg-open instead of firefox
This commit is contained in:
Max Brazhnikov 2011-06-17 21:10:38 +00:00
parent a6958267e4
commit 274e261b1b
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=275745
2 changed files with 23 additions and 0 deletions

View File

@ -7,6 +7,7 @@
PORTNAME= stardict
PORTVERSION= 3.0.2
PORTREVISION= 1
CATEGORIES= textproc
MASTER_SITES= SF
DIST_SUBDIR= stardict
@ -16,6 +17,7 @@ COMMENT= A cross-platform and international dictionary written in Gtk2
LIB_DEPENDS= sigc-2.0.0:${PORTSDIR}/devel/libsigc++20 \
enchant.1:${PORTSDIR}/textproc/enchant
RUN_DEPENDS= xdg-open:${PORTSDIR}/devel/xdg-utils
GNU_CONFIGURE= yes
CONFIGURE_ENV= LIBS="-L${LOCALBASE}/lib"
@ -55,6 +57,7 @@ post-patch:
${REINPLACE_CMD} -e '/^GNOME_DOC_INIT/d' ${WRKSRC}/configure.ac
.endif
${REINPLACE_CMD} -e 's,/usr/share,${PREFIX}/share,g' \
-e 's,firefox,xdg-open,' \
${WRKSRC}/src/conf.cpp
post-install:

View File

@ -0,0 +1,20 @@
--- ./src/readword.cpp.orig 2010-12-17 19:58:59.000000000 +0300
+++ ./src/readword.cpp 2011-06-18 00:38:15.560473773 +0400
@@ -78,7 +78,7 @@
std::string filename;
std::list<std::string>::const_iterator it;
for (it=ttspath.begin(); it!=ttspath.end(); ++it) {
- filename = build_path(*it, lowerword[0] + G_DIR_SEPARATOR_S + lowerword + ".wav");
+ filename = build_path(*it, std::string(1,lowerword[0]) + G_DIR_SEPARATOR_S + lowerword + ".wav");
return_val = g_file_test(filename.c_str(), G_FILE_TEST_EXISTS);
if (return_val)
break;
@@ -109,7 +109,7 @@
std::string filename;
std::list<std::string>::const_iterator it;
for (it=ttspath.begin(); it!=ttspath.end(); ++it) {
- filename = build_path(*it, lowerword[0] + G_DIR_SEPARATOR_S + lowerword + ".wav");
+ filename = build_path(*it, std::string(1,lowerword[0]) + G_DIR_SEPARATOR_S + lowerword + ".wav");
if (g_file_test(filename.c_str(), G_FILE_TEST_EXISTS)) {
play_sound_file(filename);
break;