Compare commits

...

No commits in common. "c8" and "c10s" have entirely different histories.
c8 ... c10s

25 changed files with 340 additions and 29 deletions

View File

@ -1 +0,0 @@
a97b2f377c6a799928d6728c2ada55beb7f57d96 SOURCES/expect5.45.4.tar.gz

1
.fmf/version Normal file
View File

@ -0,0 +1 @@
1

2
.gitignore vendored
View File

@ -1 +1 @@
SOURCES/expect5.45.4.tar.gz
/expect5.45.4.tar.gz

View File

@ -1,6 +1,6 @@
diff -up expect5.45.4/exp_chan.c.orig expect5.45.4/exp_chan.c
--- expect5.45.4/exp_chan.c.orig 2018-02-02 20:15:52.000000000 +0100
+++ expect5.45.4/exp_chan.c 2018-10-10 09:29:44.702617967 +0200
+++ expect5.45.4/exp_chan.c 2018-10-09 14:14:44.851965292 +0200
@@ -51,6 +51,8 @@ static void ExpWatchProc _ANSI_ARGS_((C
int mask));
static int ExpGetHandleProc _ANSI_ARGS_((ClientData instanceData,
@ -11,8 +11,8 @@ diff -up expect5.45.4/exp_chan.c.orig expect5.45.4/exp_chan.c
/*
* This structure describes the channel type structure for Expect-based IO:
diff -up expect5.45.4/exp_clib.c.orig expect5.45.4/exp_clib.c
--- expect5.45.4/exp_clib.c.orig 2018-10-10 09:29:44.695617962 +0200
+++ expect5.45.4/exp_clib.c 2018-10-10 09:29:44.723617980 +0200
--- expect5.45.4/exp_clib.c.orig 2018-10-09 14:14:44.841965281 +0200
+++ expect5.45.4/exp_clib.c 2018-10-09 14:14:44.873965319 +0200
@@ -37,6 +37,14 @@ would appreciate credit if this program
# endif
#endif
@ -61,8 +61,8 @@ diff -up expect5.45.4/exp_clib.c.orig expect5.45.4/exp_clib.c
}
diff -up expect5.45.4/exp_log.c.orig expect5.45.4/exp_log.c
--- expect5.45.4/exp_log.c.orig 2018-10-10 09:29:44.691617960 +0200
+++ expect5.45.4/exp_log.c 2018-10-10 09:29:44.703617967 +0200
--- expect5.45.4/exp_log.c.orig 2018-10-09 14:14:44.838965277 +0200
+++ expect5.45.4/exp_log.c 2018-10-09 14:14:44.852965294 +0200
@@ -174,7 +174,10 @@ expStdoutLog TCL_VARARGS_DEF(int,arg1)
force_stdout = TCL_VARARGS_START(int,arg1,args);
fmt = va_arg(args,char *);
@ -76,8 +76,8 @@ diff -up expect5.45.4/exp_log.c.orig expect5.45.4/exp_log.c
(void) vsnprintf(bigbuf,sizeof(bigbuf),fmt,args);
expDiagWriteBytes(bigbuf,-1);
diff -up expect5.45.4/exp_main_sub.c.orig expect5.45.4/exp_main_sub.c
--- expect5.45.4/exp_main_sub.c.orig 2018-02-04 11:43:58.000000000 +0100
+++ expect5.45.4/exp_main_sub.c 2018-10-10 09:29:44.703617967 +0200
--- expect5.45.4/exp_main_sub.c.orig 2018-10-09 14:14:44.848965289 +0200
+++ expect5.45.4/exp_main_sub.c 2018-10-09 14:14:44.852965294 +0200
@@ -57,6 +57,7 @@ int exp_cmdlinecmds = FALSE;
int exp_interactive = FALSE;
int exp_buffer_command_input = FALSE;/* read in entire cmdfile at once */
@ -87,8 +87,8 @@ diff -up expect5.45.4/exp_main_sub.c.orig expect5.45.4/exp_main_sub.c
Tcl_Interp *exp_interp; /* for use by signal handlers who can't figure out */
/* the interpreter directly */
diff -up expect5.45.4/pty_termios.c.orig expect5.45.4/pty_termios.c
--- expect5.45.4/pty_termios.c.orig 2018-02-02 20:15:52.000000000 +0100
+++ expect5.45.4/pty_termios.c 2018-10-10 09:29:44.703617967 +0200
--- expect5.45.4/pty_termios.c.orig 2018-10-09 14:17:00.132127498 +0200
+++ expect5.45.4/pty_termios.c 2018-10-09 14:33:59.393315570 +0200
@@ -105,6 +105,7 @@ with openpty which supports 4000 while p
void expDiagLog();

24
expect-c99.patch Normal file
View File

@ -0,0 +1,24 @@
Adjustments for compatibility with the currrent (Tcl 8.4.0+) channel
implementation.
diff --git a/exp_chan.c b/exp_chan.c
index c92e26b6fbd02305..944200a63b102672 100644
--- a/exp_chan.c
+++ b/exp_chan.c
@@ -60,7 +60,7 @@ void exp_background_channelhandler _ANSI_ARGS_((ClientData,
Tcl_ChannelType expChannelType = {
"exp", /* Type name. */
- ExpBlockModeProc, /* Set blocking/nonblocking mode.*/
+ TCL_CHANNEL_VERSION_2,
ExpCloseProc, /* Close proc. */
ExpInputProc, /* Input proc. */
ExpOutputProc, /* Output proc. */
@@ -70,6 +70,7 @@ Tcl_ChannelType expChannelType = {
ExpWatchProc, /* Initialize notifier. */
ExpGetHandleProc, /* Get OS handles out of channel. */
NULL, /* Close2 proc */
+ ExpBlockModeProc, /* Set blocking/nonblocking mode.*/
};
typedef struct ThreadSpecificData {

200
expect-configure-c99.patch Normal file
View File

@ -0,0 +1,200 @@
Avoid calling exit without declaring the function.
Add missing <string.h> include for memcpy.
Use AC_TYPE_SIGNAL to fix REARM_SIG check. Add missing includes.
Fix various implicit int return types of main.
Submitted upstream here: <https://sourceforge.net/p/expect/patches/24/#6759>
diff --git a/configure.in b/configure.in
index 51558fa14d2bcf7e..055c88fbd8797eaa 100755
--- a/configure.in
+++ b/configure.in
@@ -452,7 +452,11 @@ AC_CHECK_FUNC(siglongjmp, AC_DEFINE(HAVE_SIGLONGJMP))
# because Unixware 2.0 handles it specially and refuses to compile
# autoconf's automatic test that is a call with no arguments
AC_MSG_CHECKING([for memcpy])
-AC_TRY_LINK(,[
+AC_TRY_LINK([
+#ifdef HAVE_STRING_H
+#include <string.h>
+#endif
+],[
char *s1, *s2;
memcpy(s1,s2,0);
],
@@ -469,6 +473,7 @@ memcpy(s1,s2,0);
AC_MSG_CHECKING([if WNOHANG requires _POSIX_SOURCE])
AC_TRY_RUN([
#include <sys/wait.h>
+int
main() {
#ifndef WNOHANG
return 0;
@@ -489,6 +494,7 @@ rm -rf wnohang
AC_TRY_RUN([
#include <stdio.h>
#include <sys/wait.h>
+int
main() {
#ifdef WNOHANG
FILE *fp = fopen("wnohang","w");
@@ -527,16 +533,21 @@ else
AC_DEFINE(SELECT_MASK_TYPE, fd_set)
fi
-dnl # Check for the data type of the function used in signal(). This
-dnl # must be before the test for rearming.
-dnl # echo checking return type of signal handlers
-dnl AC_HEADER_EGREP([(void|sighandler_t).*signal], signal.h, retsigtype=void,AC_DEFINE(RETSIGTYPE, int) retsigtype=int)
+AC_TYPE_SIGNAL
# FIXME: check if alarm exists
AC_MSG_CHECKING([if signals need to be re-armed])
AC_TRY_RUN([
#include <signal.h>
-#define RETSIGTYPE $retsigtype
+#ifdef HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+#ifndef NO_SYS_WAIT_H
+# include <sys/wait.h>
+#endif
int signal_rearms = 0;
@@ -553,6 +564,7 @@ int n;
signal_rearms++;
}
+int
main()
{
signal(SIGINT,parent_sigint_handler);
@@ -714,10 +726,11 @@ fi
AC_MSG_CHECKING([for struct sgttyb])
AC_TRY_RUN([
#include <sgtty.h>
+int
main()
{
struct sgttyb tmp;
- exit(0);
+ return 0;
}],
AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_SGTTYB)
@@ -738,10 +751,11 @@ if test $mach -eq 0 ; then
# pty_termios.c is set up to handle pty_termio.
AC_MSG_CHECKING([for struct termio])
AC_TRY_RUN([#include <termio.h>
+ int
main()
{
struct termio tmp;
- exit(0);
+ return 0;
}],
AC_DEFINE(HAVE_TERMIO)
PTY_TYPE=termios
@@ -760,10 +774,11 @@ if test $mach -eq 0 ; then
# include <inttypes.h>
# endif
# include <termios.h>
+ int
main()
{
struct termios tmp;
- exit(0);
+ return 0;
}],
AC_DEFINE(HAVE_TERMIOS)
PTY_TYPE=termios
@@ -782,6 +797,7 @@ AC_TRY_RUN([
#include <inttypes.h>
#endif
#include <termios.h>
+int
main() {
#if defined(TCGETS) || defined(TCGETA)
return 0;
@@ -804,6 +820,7 @@ AC_TRY_RUN([
#include <inttypes.h>
#endif
#include <termios.h>
+int
main() {
#ifdef TIOCGWINSZ
return 0;
@@ -823,6 +840,7 @@ main() {
AC_MSG_CHECKING([for Cray-style ptys])
SETUID=":"
AC_TRY_RUN([
+int
main(){
#ifdef CRAY
return 0;
@@ -878,12 +896,13 @@ AC_MSG_CHECKING([for SV-style timezone])
AC_TRY_RUN([
extern char *tzname[2];
extern int daylight;
+int
main()
{
int *x = &daylight;
char **y = tzname;
- exit(0);
+ return 0;
}],
AC_DEFINE(HAVE_SV_TIMEZONE)
AC_MSG_RESULT(yes),
diff --git a/tclconfig/tcl.m4 b/tclconfig/tcl.m4
index 0689cab3da994068..ebe839e5553ba520 100644
--- a/tclconfig/tcl.m4
+++ b/tclconfig/tcl.m4
@@ -2400,7 +2400,7 @@ AC_DEFUN([TEA_TIME_HANDLER], [
AC_TRY_COMPILE([#include <time.h>],
[extern long timezone;
timezone += 1;
- exit (0);],
+ return 0;],
tcl_cv_timezone_long=yes, tcl_cv_timezone_long=no)])
if test $tcl_cv_timezone_long = yes ; then
AC_DEFINE(HAVE_TIMEZONE_VAR, 1, [Should we use the global timezone variable?])
@@ -2412,7 +2412,7 @@ AC_DEFUN([TEA_TIME_HANDLER], [
AC_TRY_COMPILE([#include <time.h>],
[extern time_t timezone;
timezone += 1;
- exit (0);],
+ return 0;],
tcl_cv_timezone_time=yes, tcl_cv_timezone_time=no)])
if test $tcl_cv_timezone_time = yes ; then
AC_DEFINE(HAVE_TIMEZONE_VAR, 1, [Should we use the global timezone variable?])
@@ -2452,17 +2452,17 @@ AC_DEFUN([TEA_BUGGY_STRTOD], [
double value;
value = strtod(infString, &term);
if ((term != infString) && (term[-1] == 0)) {
- exit(1);
+ return 1;
}
value = strtod(nanString, &term);
if ((term != nanString) && (term[-1] == 0)) {
- exit(1);
+ return 1;
}
value = strtod(spaceString, &term);
if (term == (spaceString+1)) {
- exit(1);
+ return 1;
}
- exit(0);
+ return 0;
}], tcl_cv_strtod_buggy=ok, tcl_cv_strtod_buggy=buggy,
tcl_cv_strtod_buggy=buggy)])
if test "$tcl_cv_strtod_buggy" = buggy; then

View File

@ -5,12 +5,12 @@
Summary: A program-script interaction and testing utility
Name: expect
Version: %{majorver}
Release: 5%{?dist}
License: Public Domain
Release: 25%{?dist}
License: LicenseRef-Fedora-Public-Domain
URL: https://core.tcl.tk/expect/index
Source: http://downloads.sourceforge.net/%{name}/%{name}%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Buildrequires: tcl-devel autoconf automake chrpath
Buildrequires: gcc tcl-devel autoconf automake chrpath
BuildRequires: make
# Patch0: fixes change log file permissions
Patch0: expect-5.43.0-log_file.patch
# Patch1: fixes install location, change pkgIndex
@ -46,6 +46,8 @@ Patch103: expect-5.45-passmass-su-full-path.patch
Patch104: expect-5.45-mkpasswd-man.patch
# Patch105: Fix error with -Werror=format-security
Patch105: expect-5.45-format-security.patch
Patch106: expect-configure-c99.patch
Patch107: expect-c99.patch
%description
Expect is a tcl application for automating and testing
@ -102,6 +104,8 @@ of expectk.
%patch103 -p1 -b .passmass-su-full-path
%patch104 -p1 -b .mkpasswd-man
%patch105 -p0 -b .format-security
%patch106 -p1 -b .configure-c99
%patch -P 107 -p1
# -pkgpath.patch touch configure.in
aclocal
autoconf
@ -131,15 +135,17 @@ rm -f "$RPM_BUILD_ROOT"%{_bindir}/{cryptdir,decryptdir}
rm -f "$RPM_BUILD_ROOT"%{_mandir}/man1/{cryptdir,decryptdir}.1*
rm -f "$RPM_BUILD_ROOT"%{_bindir}/autopasswd
# rename mkpasswd, as it collides with more powerful variant from whois package (bug 1649456)
mv "$RPM_BUILD_ROOT"%{_bindir}/mkpasswd "$RPM_BUILD_ROOT"%{_bindir}/mkpasswd-expect
mv "$RPM_BUILD_ROOT"%{_mandir}/man1/mkpasswd.1 "$RPM_BUILD_ROOT"%{_mandir}/man1/mkpasswd-expect.1
sed -i 's/mkpasswd/mkpasswd-expect/g;s/MKPASSWD/MKPASSWD-EXPECT/g' "$RPM_BUILD_ROOT"%{_mandir}/man1/mkpasswd-expect.1
sed -i 's/mkpasswd/mkpasswd-expect/g' "$RPM_BUILD_ROOT"%{_bindir}/mkpasswd-expect
# remove rpath
chrpath --delete $RPM_BUILD_ROOT%{_libdir}/libexpect%{version}.so
%clean
rm -rf "$RPM_BUILD_ROOT"
%files
%defattr(-,root,root,-)
%doc FAQ HISTORY NEWS README
%{_bindir}/expect
%{_bindir}/autoexpect
@ -147,7 +153,7 @@ rm -rf "$RPM_BUILD_ROOT"
%{_bindir}/ftp-rfc
%{_bindir}/kibitz
%{_bindir}/lpunlock
%{_bindir}/mkpasswd
%{_bindir}/mkpasswd-expect
%{_bindir}/passmass
%{_bindir}/rftp
%{_bindir}/rlogin-cwd
@ -164,18 +170,16 @@ rm -rf "$RPM_BUILD_ROOT"
%{_mandir}/man1/dislocate.1.gz
%{_mandir}/man1/expect.1.gz
%{_mandir}/man1/kibitz.1.gz
%{_mandir}/man1/mkpasswd.1.gz
%{_mandir}/man1/mkpasswd-expect.1.gz
%{_mandir}/man1/passmass.1.gz
%{_mandir}/man1/unbuffer.1.gz
%{_mandir}/man1/xkibitz.1.gz
%files devel
%defattr(-,root,root,-)
%{_mandir}/man3/libexpect.3*
%{_includedir}/*
%files -n expectk
%defattr(-,root,root,-)
%{_bindir}/multixterm
%{_bindir}/tknewsbiff
%{_bindir}/tkpasswd
@ -184,20 +188,80 @@ rm -rf "$RPM_BUILD_ROOT"
%{_mandir}/man1/tknewsbiff.1*
%changelog
* Thu Nov 29 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-5
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 5.45.4-25
- Bump release for October 2024 mass rebuild:
Resolves: RHEL-64018
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 5.45.4-24
- Bump release for June 2024 mass rebuild
* Wed Jan 24 2024 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-23
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-22
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Wed Jan 17 2024 Florian Weimer <fweimer@redhat.com> - 5.45.4-21
- Use Tcl 8.4 channel type (GCC 14 compatibility)
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-20
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Wed Mar 29 2023 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-19
- SPDX migration
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Fri Nov 18 2022 Florian Weimer <fweimer@redhat.com> - 5.45.4-17
- Update configure for building in strict C99 mode
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-16
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-15
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-13
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-12
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-11
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-10
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Thu Nov 22 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-8
- Rename mkpasswd to mkpasswd-expect
Resolves: #1649456
* Wed Oct 10 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-7
- Fix issues detected by static analysis
Resolves: #1602490
* Thu Oct 18 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-4
* Wed Aug 29 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-6
- Unificate and improve both man page and usage message of expect
Resolves: #1612588
* Wed Jun 27 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-3
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 5.45.4-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Wed Jun 27 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-4
- Fix wrong log file permissions
* Wed Jun 20 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-2
* Wed Jun 20 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-3
- Fix upstream URL
* Tue Feb 27 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-2
- Add BuildRequires gcc
* Tue Feb 06 2018 Vitezslav Crhonek <vcrhonek@redhat.com> - 5.45.4-1
- New upstream release 5.45.4
Resolves: #1541735

6
gating.yaml Normal file
View File

@ -0,0 +1,6 @@
--- !Policy
product_versions:
- rhel-10
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}

16
plans/tier1.fmf Normal file
View File

@ -0,0 +1,16 @@
---
summary: Tier1 plan for expect
discover:
how: fmf
url: https://pkgs.devel.redhat.com/git/tests/expect
ref: master
filter: tier:1
execute:
how: tmt
adjust:
enabled: false
when: distro == centos-stream or distro == fedora

1
sources Normal file
View File

@ -0,0 +1 @@
SHA512 (expect5.45.4.tar.gz) = a8dc25e8175f67e029e15cbcfca1705165c1c4cb2dd37eaaaebffb61e3ba132d9519cd73ca5add4c3358a2b0b7a91e878279e8d0b72143ff2c287fce07e4659a