]> git.ipfire.org Git - ipfire-3.x.git/commitdiff
expect: Remove broken patches from toolchain.
authorSchantl Stefan <Stevee@ipfire.org>
Fri, 19 Mar 2010 14:19:05 +0000 (15:19 +0100)
committerSchantl Stefan <Stevee@ipfire.org>
Fri, 19 Mar 2010 14:19:05 +0000 (15:19 +0100)
pkgs/toolchain/expect/patches/expect-5.43.0-tcl8.5.6.patch [deleted file]
pkgs/toolchain/expect/patches/expect-5.43.0-tcl8.5.patch [deleted file]
pkgs/toolchain/expect/patches/expect-5.43.0-tcl_8.5.8_fix-1.patch [new file with mode: 0644]

diff --git a/pkgs/toolchain/expect/patches/expect-5.43.0-tcl8.5.6.patch b/pkgs/toolchain/expect/patches/expect-5.43.0-tcl8.5.6.patch
deleted file mode 100644 (file)
index fd75c0e..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-diff -up expect-5.43/exp_command.c_old expect-5.43/exp_command.c
---- expect-5.43/exp_command.c_old      2009-02-10 16:23:48.000000000 +0100
-+++ expect-5.43/exp_command.c  2009-02-10 16:31:38.000000000 +0100
-@@ -2311,12 +2311,11 @@ Tcl_Obj *CONST objv[]; /* Argument objec
-       /* Historical note: we used "close"  long before there was a */
-       /* Tcl builtin by the same name. */
--      Tcl_CmdInfo info;
-+      Tcl_CmdInfo* close_info;
-       Tcl_ResetResult(interp);
--      if (0 == Tcl_GetCommandInfo(interp,"close",&info)) {
--          info.clientData = 0;
--      }
--      return(Tcl_CloseObjCmd(info.clientData,interp,objc_orig,objv_orig));
-+
-+      close_info = (Tcl_CmdInfo*) Tcl_GetAssocData (interp, EXP_CMDINFO_CLOSE, NULL);
-+      return(close_info->objProc(close_info->objClientData,interp,objc,objv));
-     }
-     if (chanName) {
-@@ -2961,7 +2960,10 @@ Tcl_Obj *CONST objv[];
-     /* if successful (i.e., TCL_RETURN is returned) */
-     /* modify the result, so that we will handle it specially */
--    int result = Tcl_ReturnObjCmd(clientData,interp,objc,objv);
-+    Tcl_CmdInfo* return_info = (Tcl_CmdInfo*)
-+    Tcl_GetAssocData (interp, EXP_CMDINFO_RETURN, NULL);
-+
-+    int result = return_info->objProc(return_info->objClientData,interp,objc,objv);
-     if (result == TCL_RETURN)
-         result = EXP_TCL_RETURN;
-     return result;
-diff -up expect-5.43/exp_command.h_old expect-5.43/exp_command.h
---- expect-5.43/exp_command.h_old      2009-02-10 17:33:19.000000000 +0100
-+++ expect-5.43/exp_command.h  2009-02-10 17:33:46.000000000 +0100
-@@ -326,3 +326,6 @@ EXTERN ExpState *  expDevttyGet _ANSI_ARG
- /* generic functions that really should be provided by Tcl */
- EXTERN int            expSizeGet _ANSI_ARGS_((ExpState *));
- EXTERN int            expSizeZero _ANSI_ARGS_((ExpState *));
-+
-+#define EXP_CMDINFO_CLOSE  "expect/cmdinfo/close"
-+#define EXP_CMDINFO_RETURN "expect/cmdinfo/return"
diff --git a/pkgs/toolchain/expect/patches/expect-5.43.0-tcl8.5.patch b/pkgs/toolchain/expect/patches/expect-5.43.0-tcl8.5.patch
deleted file mode 100644 (file)
index b0c4bcb..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-diff -up expect-5.43/Dbg.c.tcl8.5 expect-5.43/Dbg.c
---- expect-5.43/Dbg.c.tcl8.5   2002-03-23 05:11:54.000000000 +0100
-+++ expect-5.43/Dbg.c  2008-09-25 12:25:40.000000000 +0200
-@@ -10,6 +10,7 @@ would appreciate credit if this program 
- #include <stdio.h>
-+#include "expect_cf.h"
- #include "tcldbgcf.h"
- #if 0
- /* tclInt.h drags in stdlib.  By claiming no-stdlib, force it to drag in */
-diff -up expect-5.43/exp_inter.c.tcl8.5 expect-5.43/exp_inter.c
---- expect-5.43/exp_inter.c.tcl8.5     2004-08-18 04:03:00.000000000 +0200
-+++ expect-5.43/exp_inter.c    2008-09-25 12:25:40.000000000 +0200
-@@ -36,6 +36,7 @@ would appreciate credit if this program 
- #include <ctype.h>
- #include "tcl.h"
-+#include "tclInt.h"
- #include "string.h"
- #include "exp_tty_in.h"
diff --git a/pkgs/toolchain/expect/patches/expect-5.43.0-tcl_8.5.8_fix-1.patch b/pkgs/toolchain/expect/patches/expect-5.43.0-tcl_8.5.8_fix-1.patch
new file mode 100644 (file)
index 0000000..5b9596a
--- /dev/null
@@ -0,0 +1,125 @@
+Submitted By: DJ Lucas <dj_AT_linuxfromscratch_DOT_org>
+Date: 2008-09-28
+Initial Package Version: 5.43
+Upstream status: Not Submitted
+Origin: LFS ticket 2126 (http://wiki.linuxfromscratch.org/lfs/ticket/2126)
+        Bryan Kadzban <bryan@kadzban.is-a-geek.net>
+Description: Removes references to functions that Tcl 8.5 no longer exposes 
+             and correct other minor build problems WRT TCL-8.5.x.
+
+diff -Naur expect-5.43-orig/Dbg.c expect-5.43/Dbg.c
+--- expect-5.43-orig/Dbg.c     2002-03-22 22:11:54.000000000 -0600
++++ expect-5.43/Dbg.c  2008-08-24 01:30:15.000000000 -0500
+@@ -9,7 +9,7 @@
+ */
+ #include <stdio.h>
+-
++#include "expect_cf.h"
+ #include "tcldbgcf.h"
+ #if 0
+ /* tclInt.h drags in stdlib.  By claiming no-stdlib, force it to drag in */
+diff -Naur expect-5.43-orig/exp_inter.c expect-5.43/exp_inter.c
+--- expect-5.43-orig/exp_inter.c       2004-08-17 21:03:00.000000000 -0500
++++ expect-5.43/exp_inter.c    2008-08-24 01:28:59.000000000 -0500
+@@ -36,6 +36,7 @@
+ #include <ctype.h>
+ #include "tcl.h"
++#include "tclInt.h"
+ #include "string.h"
+ #include "exp_tty_in.h"
+diff -Naur expect-5.43/exp_command.c expect-5.43-patched/exp_command.c
+--- expect-5.43/exp_command.c  2004-08-20 13:18:01.000000000 -0400
++++ expect-5.43-patched/exp_command.c  2008-01-12 11:42:45.000000000 -0500
+@@ -2265,6 +2265,8 @@
+       /*NOTREACHED*/
+ }
++static struct exp_cmd_data cmd_data[];
++
+ /*ARGSUSED*/
+ static int
+ Exp_CloseObjCmd(clientData, interp, objc, objv)
+@@ -2311,12 +2313,23 @@
+       /* Historical note: we used "close"  long before there was a */
+       /* Tcl builtin by the same name. */
++      /* The code that registered this function as the handler for */
++      /* the "close" command stored away the old handler in the */
++      /* exp_cmd_data for the "close" command. */
++
++      struct exp_cmd_data *cmd_ptr;
+       Tcl_CmdInfo info;
++
++      for(cmd_ptr = &cmd_data[0]; cmd_ptr->name; cmd_ptr++) {
++          if(strncmp(cmd_ptr->name, "close", 5) == 0)
++              break;
++      }
++
+       Tcl_ResetResult(interp);
+       if (0 == Tcl_GetCommandInfo(interp,"close",&info)) {
+           info.clientData = 0;
+       }
+-      return(Tcl_CloseObjCmd(info.clientData,interp,objc_orig,objv_orig));
++      return(cmd_ptr->old_objProc(info.clientData,interp,objc_orig,objv_orig));
+     }
+     if (chanName) {
+@@ -2961,7 +2974,10 @@
+     /* if successful (i.e., TCL_RETURN is returned) */
+     /* modify the result, so that we will handle it specially */
+-    int result = Tcl_ReturnObjCmd(clientData,interp,objc,objv);
++    Tcl_CmdInfo info;
++    Tcl_GetCommandInfo(interp, "return", &info);
++
++    int result = info.objProc(clientData,interp,objc,objv);
+     if (result == TCL_RETURN)
+         result = EXP_TCL_RETURN;
+     return result;
+@@ -3062,8 +3078,7 @@
+       for (;c->name;c++) {
+               /* if already defined, don't redefine */
+-              if ((c->flags & EXP_REDEFINE) ||
+-                  !(Tcl_FindHashEntry(&globalNsPtr->cmdTable,c->name) ||
++              if (!(Tcl_FindHashEntry(&globalNsPtr->cmdTable,c->name) ||
+                     Tcl_FindHashEntry(&currNsPtr->cmdTable,c->name))) {
+                       if (c->objproc)
+                               Tcl_CreateObjCommand(interp,c->name,
+@@ -3072,6 +3087,21 @@
+                               Tcl_CreateCommand(interp,c->name,c->proc,
+                                                 c->data,exp_deleteProc);
+               }
++              else if (c->flags & EXP_REDEFINE) { /* unless the REDEFINE flag is present */
++                      Tcl_CmdInfo info;
++
++                      if (Tcl_GetCommandInfo(interp, c->name, &info)) {
++                              c->old_proc     = info.proc;
++                              c->old_objProc  = info.objProc;
++                      }
++
++                      if (c->objproc)
++                              Tcl_CreateObjCommand(interp,c->name,
++                                                   c->objproc,c->data,exp_deleteObjProc);
++                      else
++                              Tcl_CreateCommand(interp,c->name,c->proc,
++                                                c->data,exp_deleteProc);
++              }
+               if (!(c->name[0] == 'e' &&
+                     c->name[1] == 'x' &&
+                     c->name[2] == 'p')
+diff -Naur expect-5.43/exp_command.h expect-5.43-patched/exp_command.h
+--- expect-5.43/exp_command.h  2008-01-12 11:44:11.000000000 -0500
++++ expect-5.43-patched/exp_command.h  2008-01-12 11:26:05.000000000 -0500
+@@ -297,6 +297,8 @@
+       Tcl_CmdProc     *proc;
+       ClientData      data;
+       int             flags;
++      Tcl_CmdProc     *old_proc;     /* these store the procedure for the old command, */
++      Tcl_ObjCmdProc  *old_objProc;  /* if any */
+ };
+ EXTERN void           exp_create_commands _ANSI_ARGS_((Tcl_Interp *,