Control: tags 954506 + patch
Control: tags 954506 + pending

Dear maintainer,

I've prepared an NMU for ttyrec (versioned as 1.0.8-5.1) and
uploaded it to mentors for sponsoring. Please feel free to tell me if I
should remove it.

--
Regards
Sudip

diff -Nru ttyrec-1.0.8/debian/changelog ttyrec-1.0.8/debian/changelog
--- ttyrec-1.0.8/debian/changelog       2010-04-28 06:09:09.000000000 +0100
+++ ttyrec-1.0.8/debian/changelog       2020-04-06 19:48:56.000000000 +0100
@@ -1,3 +1,10 @@
+ttyrec (1.0.8-5.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTBFS. (Closes: #954506)
+
+ -- Sudip Mukherjee <sudipm.mukher...@gmail.com>  Mon, 06 Apr 2020 19:48:56 
+0100
+
 ttyrec (1.0.8-5) unstable; urgency=low
 
   * debian/patches/15_ttyrec_dont_record_query.diff: New file (Closes:
diff -Nru ttyrec-1.0.8/debian/patches/17_remove_stropts.patch 
ttyrec-1.0.8/debian/patches/17_remove_stropts.patch
--- ttyrec-1.0.8/debian/patches/17_remove_stropts.patch 1970-01-01 
01:00:00.000000000 +0100
+++ ttyrec-1.0.8/debian/patches/17_remove_stropts.patch 2020-04-06 
19:48:21.000000000 +0100
@@ -0,0 +1,48 @@
+Description: Fix FTBFS
+ glibc removed obsolete, never-implemented XSI STREAMS declarations via:
+ 
https://sourceware.org/git/?p=glibc.git;a=commit;h=a0a0dc83173ce11ff45105fd32e5d14356cdfb9c
+ And so stropts.h file is not available anymore.
+
+ Moreover isastream() was declared in stropts.h and was never actually
+ implemented. It always returned 0.
+ ref: https://sources.debian.org/src/glibc/2.30-4/posix/streams-compat.c/#L68
+ As a result, "if (isastrem())" will always be false, so remove that.
+
+Author: Sudip Mukherjee <sudipm.mukher...@gmail.com>
+Bug-Debian: https://bugs.debian.org/954506
+
+---
+
+--- ttyrec-1.0.8.orig/ttyrec.c
++++ ttyrec-1.0.8/ttyrec.c
+@@ -57,7 +57,6 @@
+ 
+ #if defined(SVR4)
+ #include <fcntl.h>
+-#include <stropts.h>
+ #endif /* SVR4 */
+ 
+ #include <sys/time.h>
+@@ -483,22 +482,6 @@ getslave()
+               perror("open(fd, O_RDWR)");
+               fail();
+       }
+-      if (isastream(slave)) {
+-              if (ioctl(slave, I_PUSH, "ptem") < 0) {
+-                      perror("ioctl(fd, I_PUSH, ptem)");
+-                      fail();
+-              }
+-              if (ioctl(slave, I_PUSH, "ldterm") < 0) {
+-                      perror("ioctl(fd, I_PUSH, ldterm)");
+-                      fail();
+-              }
+-#ifndef _HPUX_SOURCE
+-              if (ioctl(slave, I_PUSH, "ttcompat") < 0) {
+-                      perror("ioctl(fd, I_PUSH, ttcompat)");
+-                      fail();
+-              }
+-#endif
+-      }
+       (void) tcsetattr(slave, TCSAFLUSH, &tt);
+       (void) ioctl(slave, TIOCSWINSZ, (char *)&win);
+       (void) ioctl(slave, TIOCSCTTY, 0);
diff -Nru ttyrec-1.0.8/debian/patches/series ttyrec-1.0.8/debian/patches/series
--- ttyrec-1.0.8/debian/patches/series  2010-04-28 05:49:40.000000000 +0100
+++ ttyrec-1.0.8/debian/patches/series  2020-04-06 19:41:17.000000000 +0100
@@ -14,3 +14,4 @@
 14_ttyplay_man.diff
 15_ttyrec_dont_record_query.diff
 16_ttyrec_XCASE.diff
+17_remove_stropts.patch

Reply via email to