]> git.ipfire.org Git - ipfire-3.x.git/commitdiff
expect: Update to 5.45.4
authorMichael Tremer <michael.tremer@ipfire.org>
Tue, 28 Feb 2023 17:37:51 +0000 (17:37 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Tue, 28 Feb 2023 17:38:15 +0000 (17:38 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
expect/expect.nm
expect/patches/expect-5.32.2-random.patch [deleted file]
expect/patches/expect-5.43.0-log_file.patch [deleted file]
expect/patches/expect-5.43.0-pkgpath.patch [deleted file]
expect/patches/expect-5.45-check-telnet.patch [deleted file]
expect/patches/expect-5.45-format-security.patch [new file with mode: 0644]
expect/patches/expect-5.45-man-page.patch [deleted file]
expect/patches/expect-5.45-match-gt-numchars-segfault.patch [deleted file]
expect/patches/expect-5.45-mkpasswd-dash.patch [deleted file]
expect/patches/expect-5.45-passmass-su-full-path.patch [deleted file]

index 0c098a379e21e01a0bfd23e6e94997d5fd683fd2..af7658c1d7462c4895c08c2ab086b54a81d00e73 100644 (file)
@@ -4,12 +4,12 @@
 ###############################################################################
 
 name       = expect
-version    = 5.45
-release    = 2
+version    = 5.45.4
+release    = 1
 thisapp    = %{name}%{version}
 
 groups     = Development/Languages
-url        = http://expect.nist.gov/
+url        = https://core.tcl-lang.org/expect/index
 license    = Public Domain
 summary    = A program-script interaction and testing utility.
 
@@ -20,26 +20,14 @@ description
        control another program and interact with it.
 end
 
-source_dl  = http://downloads.sourceforge.net/project/expect/Expect/%{version}/
+source_dl  = https://downloads.sourceforge.net/project/expect/Expect/%{version}/
 
 build
        requires
-               autoconf
-               automake
-               chrpath
                tcl-devel
        end
 
-       prepare_cmds
-               aclocal
-               autoconf
-
-               cd testsuite
-               autoconf -I..
-       end
-
        configure_options += \
-               --mandir=%{mandir} \
                --with-tcl=%{libdir} \
                --with-tclinclude=%{includedir} \
                --enable-shared
@@ -49,19 +37,10 @@ build
        end
 
        install_cmds
-               # Install lib to right location.
-               mkdir -pv %{BUILDROOT}%{libdir}
-               mv -v %{BUILDROOT}/%{libdir}/tcl*/expect%{version}/libexpect%{version}.so \
-                       %{BUILDROOT}%{libdir}
-               ln -svf libexpect%{version}.so %{BUILDROOT}%{libdir}/libexpect.so
-
-               # Remove rpath.
-               chrpath --delete %{BUILDROOT}%{libdir}/libexpect%{version}.so
-
-               # remove cryptdir/decryptdir, as Linux has no crypt command
-               rm -f %{BUILDROOT}/usr/bin/{cryptdir,decryptdir}
-               rm -f %{BUILDROOT}/usr/share/man1/{cryptdir,decryptdir}.1*
-               rm -f %{BUILDROOT}/usr/bin/autopasswd
+               # Remove cryptdir/decryptdir, as Linux has no crypt command
+               rm -vf %{BUILDROOT}/usr/bin/{cryptdir,decryptdir}
+               rm -vf %{BUILDROOT}/usr/share/man1/{cryptdir,decryptdir}.1*
+               rm -vf %{BUILDROOT}/usr/bin/autopasswd
        end
 end
 
diff --git a/expect/patches/expect-5.32.2-random.patch b/expect/patches/expect-5.32.2-random.patch
deleted file mode 100644 (file)
index 0cac294..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-diff -up expect-5.44.1.15/example/mkpasswd.orig expect-5.44.1.15/example/mkpasswd
---- expect-5.44.1.15/example/mkpasswd.orig     2010-03-08 16:01:05.518378075 +0100
-+++ expect-5.44.1.15/example/mkpasswd  2010-03-08 16:01:27.408388162 +0100
-@@ -92,7 +92,14 @@ proc insert {pvar char} {
- }
- proc rand {m} {
--    expr {int($m*rand())}
-+    set device /dev/urandom            ;# /dev/random can block
-+    set fileId [open $device r]
-+    binary scan [read $fileId 4] i1 number
-+    set clipped [expr $number % $m]
-+#    puts "number is $number"
-+#    puts "clipped is $clipped"
-+    close $fileId
-+    return $clipped
- }
- # choose left or right starting hand
diff --git a/expect/patches/expect-5.43.0-log_file.patch b/expect/patches/expect-5.43.0-log_file.patch
deleted file mode 100644 (file)
index 8a2c93d..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -up expect-5.44.1.15/exp_log.c.orig expect-5.44.1.15/exp_log.c
---- expect-5.44.1.15/exp_log.c.orig    2010-03-08 15:45:20.581378309 +0100
-+++ expect-5.44.1.15/exp_log.c 2010-03-08 15:45:38.838398279 +0100
-@@ -374,7 +374,7 @@ expDiagChannelOpen(interp,filename)
-       Tcl_DStringAppend(&tsdPtr->diagFilename,filename,-1);
-     }
--    tsdPtr->diagChannel = Tcl_OpenFileChannel(interp,newfilename,"a",0777);
-+    tsdPtr->diagChannel = Tcl_OpenFileChannel(interp,newfilename,"a",0666);
-     if (!tsdPtr->diagChannel) {
-       Tcl_DStringFree(&tsdPtr->diagFilename);
-       return TCL_ERROR;
diff --git a/expect/patches/expect-5.43.0-pkgpath.patch b/expect/patches/expect-5.43.0-pkgpath.patch
deleted file mode 100644 (file)
index 0c32a1f..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-diff -up expect5.45/configure.in.orig expect5.45/configure.in
---- expect5.45/configure.in.orig       2011-01-18 16:58:14.860806442 +0100
-+++ expect5.45/configure.in    2011-01-18 16:58:30.378753210 +0100
-@@ -977,6 +977,7 @@ AC_SUBST(EXP_CC_SEARCH_FLAGS)
- AC_SUBST(SETUID)
- AC_SUBST(SETPGRP_VOID)
- AC_SUBST(DEFAULT_STTY_ARGS)
-+AC_SUBST(TCL_VERSION)
- # Expect uses these from tclConfig.sh to make the main executable
- AC_SUBST(TCL_DL_LIBS)
- AC_SUBST(TCL_CC_SEARCH_FLAGS)
-diff -up expect5.45/Makefile.in.orig expect5.45/Makefile.in
---- expect5.45/Makefile.in.orig        2011-01-18 16:58:37.787723824 +0100
-+++ expect5.45/Makefile.in     2011-01-18 17:05:10.697636907 +0100
-@@ -121,8 +121,8 @@ includedir = @includedir@
- DESTDIR               =
- PKG_DIR               = $(PACKAGE_NAME)$(PACKAGE_VERSION)
--pkgdatadir    = $(datadir)/$(PKG_DIR)
--pkglibdir     = $(libdir)/$(PKG_DIR)
-+pkgdatadir     = $(datadir)/tcl@TCL_VERSION@/$(PKG_DIR)
-+pkglibdir      = $(libdir)/tcl@TCL_VERSION@/$(PKG_DIR)
- pkgincludedir = $(includedir)/$(PKG_DIR)
- top_builddir  = .
-@@ -263,7 +263,7 @@ install-doc: doc
-         else true; fi ; \
-       done
--test: binaries libraries
-+test: binaries libraries pkgIndex.tcl-test
-       $(TCLSH) `@CYGPATH@ $(srcdir)/tests/all.tcl` $(TESTFLAGS)
- shell: binaries libraries
-@@ -331,6 +331,11 @@ pkgIndex.tcl:
- pkgIndex.tcl-hand:
-       (echo 'if {![package vsatisfies [package provide Tcl] @TCL_VERSION@]} {return}' ; \
-        echo 'package ifneeded Expect $(PACKAGE_VERSION) \
-+          [list load [file join $$dir .. .. $(PKG_LIB_FILE)]]'\
-+      ) > pkgIndex.tcl
-+
-+pkgIndex.tcl-test:
-+      (echo 'package ifneeded Expect $(PACKAGE_VERSION) \
-           [list load [file join $$dir $(PKG_LIB_FILE)]]'\
-       ) > pkgIndex.tcl
diff --git a/expect/patches/expect-5.45-check-telnet.patch b/expect/patches/expect-5.45-check-telnet.patch
deleted file mode 100644 (file)
index 0b67dc6..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-diff -up expect5.45/example/passmass.orig expect5.45/example/passmass
---- expect5.45/example/passmass.orig   2011-07-27 16:09:31.013843393 +0200
-+++ expect5.45/example/passmass        2011-07-27 16:10:55.667843578 +0200
-@@ -107,6 +107,10 @@ for {set i 0} {$i<$argc} {incr i} {
-       set login "ssh"
-       continue
-     } "-telnet" {
-+      if {[file executable /usr/bin/telnet] == 0} {
-+              send_user "It seems that telnet is not installed. Please install telnet in order to use the script with this option.\n"
-+              exit 1
-+      }
-       set login "telnet"
-       continue
-     } "-program" {
-diff -up expect5.45/example/weather.orig expect5.45/example/weather
---- expect5.45/example/weather.orig    2011-07-27 15:49:57.878843862 +0200
-+++ expect5.45/example/weather 2011-07-27 16:08:48.067843491 +0200
-@@ -33,6 +33,11 @@ set timeout 60
- set env(TERM) vt100   ;# actual value doesn't matter, just has to be set
-+if {[file executable /usr/bin/telnet] == 0} {
-+      send_user "It seems that telnet is not installed. Please install telnet in order to use this script.\n"
-+      exit 1
-+}
-+
- spawn telnet rainmaker.wunderground.com 3000
- while {1} {
-       expect timeout {
diff --git a/expect/patches/expect-5.45-format-security.patch b/expect/patches/expect-5.45-format-security.patch
new file mode 100644 (file)
index 0000000..5b621ff
--- /dev/null
@@ -0,0 +1,13 @@
+--- a/exp_clib.c.orig  2017-03-24 10:34:37.269183513 -0400
++++ b/exp_clib.c       2017-03-24 10:34:41.171117943 -0400
+@@ -1938,8 +1938,8 @@
+      char *str;
+ {
+   if (exp_is_debugging) {
+-    fprintf(stderr,str);
+-    if (exp_logfile) fprintf(exp_logfile,str);
++    fprintf(stderr, "%s", str);
++    if (exp_logfile) fprintf(exp_logfile, "%s", str);
+   }
+ }
diff --git a/expect/patches/expect-5.45-man-page.patch b/expect/patches/expect-5.45-man-page.patch
deleted file mode 100644 (file)
index 1a55251..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-diff -up expect5.45/expect.man.orig expect5.45/expect.man
---- expect5.45/expect.man.orig 2011-09-06 13:15:57.081827720 +0200
-+++ expect5.45/expect.man      2011-09-06 13:16:19.463826364 +0200
-@@ -173,7 +173,8 @@ way, use the
- .B \-b
- flag.
- (When using Expectk, this option is specified as
--.BR \-buffer .)  Note that stdio-buffering may still take place however this shouldn't cause problems when reading from a fifo or stdin.
-+.BR \-buffer .)
-+Note that stdio-buffering may still take place however this shouldn't cause problems when reading from a fifo or stdin.
- .PP
- If the string "\-" is supplied as a filename, standard input is read instead.
- (Use "./\-" to read from a file actually named "\-".)
diff --git a/expect/patches/expect-5.45-match-gt-numchars-segfault.patch b/expect/patches/expect-5.45-match-gt-numchars-segfault.patch
deleted file mode 100644 (file)
index 1abd424..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-diff -up expect5.45/expect.c.orig expect5.45/expect.c
---- expect5.45/expect.c.orig   2012-02-06 14:15:13.469490744 +0100
-+++ expect5.45/expect.c        2012-02-06 14:16:23.596837896 +0100
-@@ -2363,7 +2363,12 @@ expMatchProcess(
-       /* "!e" means no case matched - transfer by default */
-       if (!e || e->transfer) {
--          int remainder = numchars-match;
-+          int remainder;
-+          if (match > numchars) {
-+              match = numchars;
-+              eo->matchlen = match;
-+          }
-+          remainder = numchars-match;
-           /* delete matched chars from input buffer */
-           esPtr->printed -= match;
-           if (numchars != 0) {
diff --git a/expect/patches/expect-5.45-mkpasswd-dash.patch b/expect/patches/expect-5.45-mkpasswd-dash.patch
deleted file mode 100644 (file)
index fbdecde..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-diff -up expect5.45/example/mkpasswd.orig expect5.45/example/mkpasswd
---- expect5.45/example/mkpasswd.orig   2011-03-16 13:23:23.125480017 +0100
-+++ expect5.45/example/mkpasswd        2011-03-16 13:24:08.739353139 +0100
-@@ -202,7 +202,8 @@ if {[info exists user]} {
-       expect {
-               "assword*:" {
-                       # some systems say "Password (again):"
--                      send "$password\r"
-+                      send -- "$password\r"
-+                      # "--" because of passwords beginning with dash
-                       exp_continue
-               }
-       }
diff --git a/expect/patches/expect-5.45-passmass-su-full-path.patch b/expect/patches/expect-5.45-passmass-su-full-path.patch
deleted file mode 100644 (file)
index 6febf94..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -up expect5.45/example/passmass.orig expect5.45/example/passmass
---- expect5.45/example/passmass.orig   2011-09-06 13:04:41.439875491 +0200
-+++ expect5.45/example/passmass        2011-09-06 13:04:54.663874571 +0200
-@@ -178,7 +178,7 @@ for {set i 0} {$i<$argc} {incr i} {
-     }
-     if ($su) {
--      send "su -\r"
-+      send "/bin/su -\r"
-       expect -nocase "password:"
-       send "$password(old)\r"
-       expect "# "