[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[patch] espeak server should not install .so file in /usr/share/emacs



Hello Raman,

because of the way the makefiles are set up now for emacspeak, it is
possible for us on gentoo to automatically build the tclespeak.so module
if the user requests that when they install emacspeak.  However, the
default location where the .so is installed is not correct according to
bug http://bugs.gentoo.org/298012.

The same issue will also apply to the dtk-soft and outloud servers.

I have patches for the dtk-soft and espeak servers below.  But I haven't
written one for the outloud server yet since it uses the $tclTTS
variable not only for the .so path, but for the path to eci.ini as well.

These patches install the .so files in /usr/lib/emacspeak.  What do you
think about putting them there?  Also, where should we put eci.ini?
Maybe /etc/emacspeak?

William

Index: servers/dtk-soft
===================================================================
--- servers/dtk-soft	(revision 6424)
+++ servers/dtk-soft	(working copy)
@@ -292,7 +292,7 @@
 set tts(speech_rate)  225
 set tts(say_rate) [round \
                            [expr $tts(speech_rate) * $tts(char_factor)]]
-set tclTTS $env(EMACSPEAK_DIR)/servers/software-dtk
+set tclTTS /usr/lib/emacspeak
 if [file exists /usr/lib/libaoss.so] {
     set env(LD_PRELOAD) /usr/lib/libaoss.so
 }
Index: servers/software-dtk/Makefile
===================================================================
--- servers/software-dtk/Makefile	(revision 6424)
+++ servers/software-dtk/Makefile	(working copy)
@@ -7,7 +7,10 @@
 CPPFLAGS+=-DSTDC_HEADERS=1 -Dclock_t=long -DRETSIGTYPE=void 
 INSTALL=install
 LIBS=-ltts -ltts_us -ltcl$(TCL_VERSION)
-SERVER_DIR=/usr/share/emacs/site-lisp/emacspeak/servers/software-dtk
+PREFIX = /usr
+LIBDIR = $(PREFIX)/lib
+PKGLIBDIR = $(LIBDIR)/emacspeak
+
 FILES=tcldtk.c tcldtk.so tcldtk.o Makefile
 
 tcldtk.so: tcldtk.o
@@ -24,9 +27,9 @@
 clean:
 	rm tcldtk.so tcldtk.o
 
-install:
-	$(INSTALL) -d $(DESTDIR)$(SERVER_DIR)
-	cp  $(FILES) $(DESTDIR)$(SERVER_DIR)
+install: tcldtk.so
+	$(INSTALL) -d $(DESTDIR)$(PKGLIBDIR)
+	$(INSTALL)  $< $(DESTDIR)$(PKGLIBDIR)
 
 rpm: software-dtk.spec software-dtk.tar.gz
 	@cp software-dtk.tar.gz /usr/src/redhat/SOURCES/
Index: servers/linux-espeak/Makefile
===================================================================
--- servers/linux-espeak/Makefile	(revision 6424)
+++ servers/linux-espeak/Makefile	(working copy)
@@ -2,8 +2,8 @@
 
 INSTALL = install
 PREFIX = /usr
-LIBPARENTDIR = ${PREFIX}/share/emacs/site-lisp
-LIBDIR =$(LIBPARENTDIR)/emacspeak/servers/linux-espeak
+LIBDIR = ${PREFIX}/lib
+PKGLIBDIR = ${LIBDIR}/emacspeak
 TCL_VERSION = 8.4
 TCL_INCLUDE= /usr/include/tcl$(TCL_VERSION)
 CXXFLAGS+= -g    -O2 -fPIC  -DPIC  -pedantic -ansi -Wall -Wno-long-long -I$(TCL_INCLUDE)
@@ -21,6 +21,6 @@
 	rm -f *.so *.o
 
 install: $(TTS)
-	$(INSTALL) -d $(DESTDIR)$(LIBDIR)
-	$(INSTALL) $< $(DESTDIR)$(LIBDIR)
+	$(INSTALL) -d $(DESTDIR)$(PKGLIBDIR)
+	$(INSTALL) $< $(DESTDIR)$(PKGLIBDIR)
 
Index: servers/espeak
===================================================================
--- servers/espeak	(revision 6424)
+++ servers/espeak	(working copy)
@@ -510,7 +510,7 @@
     set tts(input) sock0
 }
 set servers [file dirname $argv0]
-set tclTTS $servers/linux-espeak
+set tclTTS /usr/lib/emacspeak
 load $tclTTS/tclespeak.so
 if {[file exists /proc/asound]} {
     set tts(play) /usr/bin/aplay

Attachment: pgpXaBe5LjkQq.pgp
Description: PGP signature



If you have questions about this archive or had problems using it, please send mail to:

priestdo@cs.vassar.edu No Soliciting!

Emacspeak List Archive | 2007 | 2006 | 2005 | 2004 | 2003 | 2002 | 2001 | 2000 | 1999 | 1998 | Pre 1998

Emacspeak Files | Emacspeak Blog | Search the archive