pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/audio/festival Make this work on NetBSD 1.6 again, by ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/83512e5d095c
branches:  trunk
changeset: 481960:83512e5d095c
user:      kristerw <kristerw%pkgsrc.org@localhost>
date:      Fri Oct 15 16:50:17 2004 +0000

description:
Make this work on NetBSD 1.6 again, by reverting the last change.
(That change was a work-in-progress to get this to build with gcc3,
so no functionality is lost by reverting it. The "correct" way of
fixing this package is to upgrade to a newer version...)

diffstat:

 audio/festival/distinfo         |    4 +-
 audio/festival/patches/patch-ao |   13 -
 audio/festival/patches/patch-ap |  372 ----------------------------------------
 3 files changed, 1 insertions(+), 388 deletions(-)

diffs (truncated from 408 to 300 lines):

diff -r 66e66740a13a -r 83512e5d095c audio/festival/distinfo
--- a/audio/festival/distinfo   Fri Oct 15 16:27:56 2004 +0000
+++ b/audio/festival/distinfo   Fri Oct 15 16:50:17 2004 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.7 2004/09/15 06:20:08 jlam Exp $
+$NetBSD: distinfo,v 1.8 2004/10/15 16:50:17 kristerw Exp $
 
 SHA1 (festival-1.4.1.tar.gz) = d3be7d58b986c37c39444a2dcc044cdc3ee1e774
 Size (festival-1.4.1.tar.gz) = 543335 bytes
@@ -22,5 +22,3 @@
 SHA1 (patch-al) = d8a22c5f509a6d75aa3295037654b594e8db4a4a
 SHA1 (patch-am) = cd6e07df1729fecca5cd9869229701b63ba71d14
 SHA1 (patch-an) = bdd701017c72db315de8fcfb4ac6ce3bf97d4d47
-SHA1 (patch-ao) = 5641ec3df224ff3e0703912c2d706899a6860184
-SHA1 (patch-ap) = e99db4ff827d94d7b121daba7dce656ba45c8057
diff -r 66e66740a13a -r 83512e5d095c audio/festival/patches/patch-ao
--- a/audio/festival/patches/patch-ao   Fri Oct 15 16:27:56 2004 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-$NetBSD: patch-ao,v 1.1 2004/09/13 09:05:25 agc Exp $
-
---- speech_tools/include/EST_iostream.h        2004/01/05 10:37:27     1.1
-+++ speech_tools/include/EST_iostream.h        2004/01/05 10:37:38
-@@ -51,7 +51,7 @@
- #   include <strstrea.h>
- #elif defined(SYSTEM_IS_UNIX)
- #   include <iostream.h>
--#   include <strstream.h>
-+#   include <sstream>
- #elif defined(SYSTEM_IS_WIN32)
- #   include "win32/EST_iostream_win32.h"
- #   include <strstrea.h>
diff -r 66e66740a13a -r 83512e5d095c audio/festival/patches/patch-ap
--- a/audio/festival/patches/patch-ap   Fri Oct 15 16:27:56 2004 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,372 +0,0 @@
-$NetBSD: patch-ap,v 1.1 2004/09/13 09:05:25 agc Exp $
-
---- speech_tools/siod/slib_file.cc     2004/08/12 10:31:50     1.1
-+++ speech_tools/siod/slib_file.cc     2004/08/12 10:33:42
-@@ -13,11 +13,16 @@
- #include "siodp.h"
- #include "EST_Pathname.h"
- 
--static void siod_string_print(LISP exp, ostrstream &sd);
-+#include <sstream>
-+#include <strstream>
-+
-+using namespace std;
-+
-+static int siod_string_print(LISP, char *, int, int);
- 
- LISP open_files = NIL;
- 
--void pprintf(FILE *fd,LISP exp,int indent,int width, int depth,int length)
-+void pprintf(FILE *fd,LISP expression,int indent,int width, int depth,int length)
- {
-     // A pretty printer for expressions
-     // indent is the number of spaces to indent by
-@@ -27,13 +32,13 @@
-     int i,ll;
-     LISP l;
- 
--    if (exp == NIL)
-+    if (expression == NIL)
-       fprintf(fd,"nil");
--    else if (!consp(exp))
--      fprintf(fd,"%s",(const char *)siod_sprint(exp));
-+    else if (!consp(expression))
-+      fprintf(fd,"%s",(const char *)siod_sprint(expression));
-     else 
-     {
--      EST_String p = siod_sprint(exp);
-+      EST_String p = siod_sprint(expression);
-       if (p.length() < width-indent)
-           fprintf(fd,"%s",(const char *)p);
-       else
-@@ -44,8 +49,8 @@
-               fprintf(fd,"...");
-           else
-           {
--              pprintf(fd,car(exp),indent,width,depth-1,length);
--              for (ll=length,l=cdr(exp); l != NIL; l=cdr(l),ll--)
-+              pprintf(fd,car(expression),indent,width,depth-1,length);
-+              for (ll=length,l=cdr(expression); l != NIL; l=cdr(l),ll--)
-               {
-                   fprintf(fd,"\n");
-                   for (i=0; i<indent; i++)
-@@ -70,32 +75,32 @@
-     }    
- }
- 
--void pprint_to_fd(FILE *fd,LISP exp)
-+void pprint_to_fd(FILE *fd,LISP expression)
- {
--    pprintf(fd,exp,0,72,-1,-1);
-+    pprintf(fd,expression,0,72,-1,-1);
-     fprintf(fd,"\n");
- }
- 
--static LISP siod_pprintf(LISP exp, LISP file)
-+static LISP siod_pprintf(LISP expression, LISP file)
- {
-     //  Pretty printer
- 
-     if ((file == NIL) ||
-       (equal(file,rintern("t"))))
--      pprint(exp);
-+      pprint(expression);
-     else
-     {
--      pprintf(get_c_file(file,stdout),exp,0,72,-1,-1);        
-+      pprintf(get_c_file(file,stdout),expression,0,72,-1,-1); 
-       fprintf(get_c_file(file,stdout),"\n");
-     }
-     return NIL;
- }
- 
--void pprint(LISP exp)
-+void pprint(LISP expression)
- {
-     // Pretty print this expression to stdout
- 
--    pprint_to_fd(stdout,exp);
-+    pprint_to_fd(stdout,expression);
- }
- 
- static LISP fflush_l(LISP p)
-@@ -109,55 +114,67 @@
-     return NIL;
- }
- 
--static void siod_string_print(LISP exp, ostrstream &sd)
-+static int
-+siod_string_print(LISP expression, char *buf, int size, int off)
- {
-     LISP tmp;
-+    int oldoff;
-     int i;
- 
--    switch TYPE(exp)
-+    oldoff = off;
-+    switch TYPE(expression)
-     {
-       case tc_nil:
--      sd << "nil";
-+      (void) strlcpy(&buf[off], "nil", size - off);
-+      off += 3;
-       break;
-       case tc_cons:
--      sd << "(";
--      siod_string_print(car(exp),sd);
--      for(tmp=cdr(exp);CONSP(tmp);tmp=cdr(tmp))
-+      (void) strlcpy(&buf[off], "(", size - off);
-+      off += 1;
-+      off += siod_string_print(car(expression), buf, size - 1, off);
-+      for(tmp=cdr(expression);CONSP(tmp);tmp=cdr(tmp))
-       {
--          sd << " ";
--          siod_string_print(car(tmp),sd);
-+          (void) strlcpy(&buf[off], "(", size - off);
-+          off += 1;
-+          off += siod_string_print(car(tmp), buf, size - 1, off);
-       }
-       if NNULLP(tmp) 
-       {
--          sd << " . ";
--          siod_string_print(tmp,sd);
-+          (void) strlcpy(&buf[off], " . ", size - off);
-+          off += 3;
-+          off += siod_string_print(tmp, buf, size - off, off);
-       }
--      sd << ")";
-+      (void) strlcpy(&buf[off], ")", size - off);
-+      off += 1;
-       break;
-       case tc_flonum:
--      if (FLONMPNAME(exp) == NULL)
-+      if (FLONMPNAME(expression) == NULL)
-       {
--          sprintf(tkbuffer,"%.14g",FLONM(exp)); /// MWM Tue Aug  3 12:09:08 PDT 1999
--          FLONMPNAME(exp) = (char *)must_malloc(strlen(tkbuffer)+1);
--          sprintf(FLONMPNAME(exp),"%s",tkbuffer);
-+          sprintf(tkbuffer,"%.14g",FLONM(expression)); /// MWM Tue Aug  3 12:09:08 PDT 1999
-+          FLONMPNAME(expression) = (char *)must_malloc(strlen(tkbuffer)+1);
-+          sprintf(FLONMPNAME(expression),"%s",tkbuffer);
-       }
--      sprintf(tkbuffer,"%s",FLONMPNAME(exp));
--      sd << tkbuffer;
-+      sprintf(tkbuffer,"%s",FLONMPNAME(expression));
-+      (void) strlcpy(&buf[off], tkbuffer, size - off);
-       break;
-       case tc_string:
--      sd << "\"";
--      for (i=0; exp->storage_as.string.data[i] != '\0'; i++)
-+      (void) strlcpy(&buf[off], "\"", size - off);
-+      off += 1;
-+      for (i=0; expression->storage_as.string.data[i] != '\0'; i++)
-       {
--          if (exp->storage_as.string.data[i] == '"')
--              sd << '\\';
--          if (exp->storage_as.string.data[i] == '\\')
--              sd << '\\';
--          sd << exp->storage_as.string.data[i];
-+          if (expression->storage_as.string.data[i] == '"' ||
-+              expression->storage_as.string.data[i] == '\\') {
-+              (void) strlcpy(&buf[off], "\\", size - off);
-+              off += 1;
-+          }
-+          (void) snprintf(&buf[off], size - off, "%c", expression->storage_as.string.data[i]);
-+          off += 1;
-       }
--      sd << "\"";
-+      (void) strlcpy(&buf[off], "\"", size - off);
-+      off += 1;
-       break;
-       case tc_symbol:
--      sd << PNAME(exp);
-+        off += snprintf(&buf[off], size - off, "%s", PNAME(expression));
-       break;
-       case tc_subr_0:
-       case tc_subr_1:
-@@ -167,57 +184,50 @@
-       case tc_lsubr:
-       case tc_fsubr:
-       case tc_msubr:
--      sprintf(tkbuffer,"#<SUBR(%d) ",TYPE(exp));
--      sd << tkbuffer;
--      sd << (*exp).storage_as.subr.name;
--      sd << ">";
-+      off += snprintf(&buf[off], size - off, "#<SUBR(%d) %s>", TYPE(expression), (*expression).storage_as.subr.name);
-       break;
-       case tc_c_file:
--      sprintf(tkbuffer,"#<FILE %p ",exp->storage_as.c_file.f);
--      sd << tkbuffer;
--      if (exp->storage_as.c_file.name)
--          sd << exp->storage_as.c_file.name;
--      sd << ">";
-+      off += snprintf(&buf[off], size - off, "#<FILE %p ", expression->storage_as.c_file.f);
-+      if (expression->storage_as.c_file.name)
-+          off += snprintf(&buf[off], size - off, "%s", expression->storage_as.c_file.name);
-+      (void) strlcpy(&buf[off], ">", size - off);
-+      off += 1;
-         break;
-       case tc_closure:
--      sd << "#<CLOSURE ";
--      siod_string_print(car((*exp).storage_as.closure.code),sd);
--      sd << " ";
--      siod_string_print(cdr((*exp).storage_as.closure.code),sd);
--      sd << ">";
-+      off += snprintf(&buf[off], size - off, "#<CLOSURE ");
-+      off += siod_string_print(car((*expression).storage_as.closure.code), buf, size - off, off);
-+      (void) strlcpy(&buf[off], " ", size - off);
-+      off += 1;
-+      off += siod_string_print(cdr((*expression).storage_as.closure.code), buf, size - off, off);
-+      (void) strlcpy(&buf[off], ">", size - off);
-+      off += 1;
-       break;
-       default:
-       struct user_type_hooks *p;
--      p = get_user_type_hooks(TYPE(exp));
-+      p = get_user_type_hooks(TYPE(expression));
-       if (p->print_string)
--        (*p->print_string)(exp, tkbuffer);
--      else
--      {
-+        (*p->print_string)(expression, tkbuffer);
-+      else {
-           if (p->name)
--              sprintf(tkbuffer,"#<%s %p>",p->name,exp);
-+              sprintf(tkbuffer,"#<%s %p>",p->name,expression);
-           else
--              sprintf(tkbuffer,"#<UNKNOWN %d %p>",TYPE(exp),exp);
-+              sprintf(tkbuffer,"#<UNKNOWN %d %p>",TYPE(expression),expression);
-       }
--      sd << tkbuffer;
-+      off += snprintf(&buf[off], size - off, "%s", tkbuffer);
-     }
--    return;
-+    return off - oldoff;
- }
- 
- 
--EST_String siod_sprint(LISP exp)
-+EST_String siod_sprint(LISP expression)
- {
--    ostrstream sd;
-     EST_String r;
-+    char buf[32767];
-+    int       cc;
- 
--    siod_string_print(exp,sd);
--
--    sd << '\0';
--    r = sd.str();
--
--#ifdef __GNUC__
--    // need to do this otherwise sd doesn't free its internal buffer
--    sd.freeze(0);
--#endif



Home | Main Index | Thread Index | Old Index