Skip site navigation (1)Skip section navigation (2)
Date:      Sat,  7 Oct 2006 15:45:38 +0200 (CEST)
From:      trasz <trasz@pin.if.uz.zgora.pl>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/104104: [PATCH] misc/splitvt: fix build with gcc41
Message-ID:  <20061007134538.3C33239DB8@pin.if.uz.zgora.pl>
Resent-Message-ID: <200610071350.k97DoDJM061874@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         104104
>Category:       ports
>Synopsis:       [PATCH] misc/splitvt: fix build with gcc41
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sat Oct 07 13:50:13 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     trasz
>Release:        FreeBSD 6.1-RELEASE i386
>Organization:
>Environment:
System: FreeBSD pin.if.uz.zgora.pl 6.1-RELEASE FreeBSD 6.1-RELEASE #0: Sat Jun  3 01:12:10 CEST
>Description:
Fix build with gcc41.

(http://pointyhat.freebsd.org/errorlogs/i386-errorlogs/e.7.2006100419/splitvt-1.6.5_2.log)

Added file(s):
- files/patch-cut-paste.c
- files/patch-terminal.c
- files/patch-vtmouse.h
- files/patch-vttest.c

Generated with FreeBSD Port Tools 0.77
>How-To-Repeat:
>Fix:

--- splitvt-1.6.5_2.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-config.c /home/trasz/splitvt/files/patch-config.c
--- /usr/ports/misc/splitvt/files/patch-config.c	Sat Feb 19 21:56:51 2005
+++ /home/trasz/splitvt/files/patch-config.c	Sat Oct  7 15:43:20 2006
@@ -1,5 +1,12 @@
 --- config.c.orig	Sun May  4 06:48:04 2003
 +++ config.c	Sat Feb 19 11:30:53 2005
+@@ -1,5 +1,6 @@
+ #include	<sys/types.h>
+ #include	<stdio.h>
++#include	<stdlib.h>
+ #include	<sys/stat.h>
+ #include	<signal.h>
+ 
 @@ -238,8 +238,8 @@
  	fprintf(makefile, "\nclean: \n\trm -f *.o core \n");
  	fprintf(makefile, "\ndistclean: clean\n\trm -f splitvt Makefile\n");
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-cut-paste.c /home/trasz/splitvt/files/patch-cut-paste.c
--- /usr/ports/misc/splitvt/files/patch-cut-paste.c	Thu Jan  1 01:00:00 1970
+++ /home/trasz/splitvt/files/patch-cut-paste.c	Sat Oct  7 15:43:20 2006
@@ -0,0 +1,10 @@
+--- cut-paste.c.orig	Sat Oct  7 14:38:24 2006
++++ cut-paste.c	Sat Oct  7 14:38:37 2006
+@@ -2,6 +2,7 @@
+ /* The cut-paste module for splitvt */
+ 
+ #include	<stdio.h>
++#include	<string.h>
+ #include	"vt100.h"
+ #include	"video.h"
+ 
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-misc.c /home/trasz/splitvt/files/patch-misc.c
--- /usr/ports/misc/splitvt/files/patch-misc.c	Wed Jun 18 13:53:49 2003
+++ /home/trasz/splitvt/files/patch-misc.c	Sat Oct  7 15:43:19 2006
@@ -1,10 +1,11 @@
---- misc.c.orig	Sat Jan 13 13:48:13 2001
-+++ misc.c	Wed Jun 18 04:44:02 2003
-@@ -5,6 +5,7 @@
+--- misc.c.orig	Wed Dec 15 10:28:45 2004
++++ misc.c	Sat Oct  7 14:34:28 2006
+@@ -5,6 +5,8 @@
  #include	<fcntl.h>
  #include	<stdio.h>
  #include	<signal.h>
 +#include	<stdlib.h>
++#include	<string.h>
  
  
  #ifdef HAVE_TERMIO_H
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-splitvt.c /home/trasz/splitvt/files/patch-splitvt.c
--- /usr/ports/misc/splitvt/files/patch-splitvt.c	Wed Jun 18 13:53:49 2003
+++ /home/trasz/splitvt/files/patch-splitvt.c	Sat Oct  7 15:43:19 2006
@@ -1,10 +1,11 @@
---- splitvt.c.orig	Sat Jan 13 14:00:22 2001
-+++ splitvt.c	Wed Jun 18 04:44:39 2003
-@@ -21,6 +21,7 @@
+--- splitvt.c.orig	Sat Jan 13 23:00:22 2001
++++ splitvt.c	Sat Oct  7 14:33:17 2006
+@@ -21,6 +21,8 @@
  #include	<stdio.h>
  #include	<errno.h>
  #include	<pwd.h>
 +#include	<stdlib.h>
++#include	<string.h>
  #ifdef HAVE_UNISTD_H
  #include	<unistd.h>
  #endif
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-terminal.c /home/trasz/splitvt/files/patch-terminal.c
--- /usr/ports/misc/splitvt/files/patch-terminal.c	Thu Jan  1 01:00:00 1970
+++ /home/trasz/splitvt/files/patch-terminal.c	Sat Oct  7 15:43:20 2006
@@ -0,0 +1,10 @@
+--- terminal.c.orig	Sat Oct  7 14:37:05 2006
++++ terminal.c	Sat Oct  7 14:37:17 2006
+@@ -6,6 +6,7 @@
+ 
+ 
+ #include	<stdio.h>
++#include	<string.h>
+ #include	"video.h"
+ #include	"terminal.h"
+ 
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-utmp.c /home/trasz/splitvt/files/patch-utmp.c
--- /usr/ports/misc/splitvt/files/patch-utmp.c	Wed Jun 18 13:53:49 2003
+++ /home/trasz/splitvt/files/patch-utmp.c	Sat Oct  7 15:43:19 2006
@@ -1,10 +1,11 @@
---- utmp.c.orig	Sat Jan 13 13:48:13 2001
-+++ utmp.c	Wed Jun 18 04:45:38 2003
-@@ -6,13 +6,14 @@
+--- utmp.c.orig	Sat Jan 13 22:48:13 2001
++++ utmp.c	Sat Oct  7 14:35:08 2006
+@@ -6,13 +6,15 @@
  #include	<fcntl.h>
  #include	<utmp.h>
  #include	<stdio.h>
 +#include	<unistd.h>
++#include	<string.h>
  
  #ifdef DEBUG_UTMP
  #undef  UTMP_FILE
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-vt100.c /home/trasz/splitvt/files/patch-vt100.c
--- /usr/ports/misc/splitvt/files/patch-vt100.c	Wed Jun 18 13:53:49 2003
+++ /home/trasz/splitvt/files/patch-vt100.c	Sat Oct  7 15:43:20 2006
@@ -1,10 +1,11 @@
---- vt100.c.orig	Sat Jun  3 14:31:05 2000
-+++ vt100.c	Wed Jun 18 04:44:21 2003
-@@ -17,6 +17,7 @@
+--- vt100.c.orig	Sat Jun  3 23:31:05 2000
++++ vt100.c	Sat Oct  7 14:35:57 2006
+@@ -17,6 +17,8 @@
  #include	<errno.h>
  #include	<stdio.h>
  #include	<ctype.h>
 +#include	<stdlib.h>
++#include	<string.h>
  #include	"vt100.h"
  #include	"video.h"
  #include	"terminal.h"
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-vtmouse.c /home/trasz/splitvt/files/patch-vtmouse.c
--- /usr/ports/misc/splitvt/files/patch-vtmouse.c	Wed Jun 18 13:53:49 2003
+++ /home/trasz/splitvt/files/patch-vtmouse.c	Sat Oct  7 15:43:19 2006
@@ -1,10 +1,11 @@
---- vtmouse.c.orig	Sat Jun  3 14:05:57 2000
-+++ vtmouse.c	Wed Jun 18 04:46:02 2003
-@@ -8,6 +8,7 @@
+--- vtmouse.c.orig	Sat Jun  3 23:05:57 2000
++++ vtmouse.c	Sat Oct  7 14:37:42 2006
+@@ -8,6 +8,8 @@
  #define SPLITVT_SOURCE
  
  #include <stdio.h>
 +#include <stdlib.h>
++#include <string.h>
  #include "vtmouse.h"
  
  extern FILE *safe_popen();		/* From misc.c */
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-vtmouse.h /home/trasz/splitvt/files/patch-vtmouse.h
--- /usr/ports/misc/splitvt/files/patch-vtmouse.h	Thu Jan  1 01:00:00 1970
+++ /home/trasz/splitvt/files/patch-vtmouse.h	Sat Oct  7 15:43:20 2006
@@ -0,0 +1,9 @@
+--- vtmouse.h.orig	Sat Oct  7 02:22:11 2006
++++ vtmouse.h	Sat Oct  7 02:22:36 2006
+@@ -39,5 +39,5 @@
+ extern int  event_getc();
+ extern void event_quit();
+ 
+-extern FILE *xt_input, *xt_output;	/* Usually untouched */
++static FILE *xt_input, *xt_output;	/* Usually untouched */
+ 
diff -ruN --exclude=CVS /usr/ports/misc/splitvt/files/patch-vttest.c /home/trasz/splitvt/files/patch-vttest.c
--- /usr/ports/misc/splitvt/files/patch-vttest.c	Thu Jan  1 01:00:00 1970
+++ /home/trasz/splitvt/files/patch-vttest.c	Sat Oct  7 15:43:20 2006
@@ -0,0 +1,17 @@
+--- vttest.c.orig	Sat Oct  7 15:38:17 2006
++++ vttest.c	Sat Oct  7 15:40:43 2006
+@@ -87,9 +87,13 @@
+ 	setjmp(alarm_buf);
+ #endif
+ 	while ( !alarmed && (x < 20) ) { 
+-		if ( read(fd, &buff[x++], 1) <= 0 )
++		// Workaround for gcc41.  Without it, splitvt fails with
++		// "Can't initialize screen: Terminal type must be set to vt100".
++		if ( read(fd, &buff[x], 1) <= 0 )
+ 			break;
++		x++;
+ 	}
++	x++;
+ 	buff[x]='\0';		/* For printing, if we desire. */
+   	if ( buff[0] == '\033' )	/* An escape sequence? :) */
+ 		rc=1;
--- splitvt-1.6.5_2.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061007134538.3C33239DB8>