Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 23 Jun 2004 22:00:18 -0400 (EDT)
From:      "Stephen J. Roznowski" <sjr@comcast.net>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        markm@FreeBSD.org
Subject:   ports/68260: [PATCH] Removal of -lcompat from freebsd-games port
Message-ID:  <200406240200.i5O20Iih065247@istari.comcast.net>
Resent-Message-ID: <200406240200.i5O20c39054507@freefall.freebsd.org>

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

>Number:         68260
>Category:       ports
>Synopsis:       [PATCH] Removal of -lcompat from freebsd-games port
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Thu Jun 24 02:00:38 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Stephen J. Roznowski
>Release:        FreeBSD 4.10-STABLE i386
>Organization:
>Environment:
System: FreeBSD istari.comcast.net 4.10-STABLE FreeBSD 4.10-STABLE #2: Thu May 27 14:21:13 EDT 2004 sjr@istari.comcast.net:/usr/obj/usr/src/sys/ISTARI i386


	
>Description:
	Per Poul-Henning Kamp's request, updated port to remove -lcompat
	library.
	
>How-To-Repeat:
	
>Fix:

	


diff -ru work.orig/freebsd-games-5.1.1/battlestar/Makefile work/freebsd-games-5.1.1/battlestar/Makefile
--- work.orig/freebsd-games-5.1.1/battlestar/Makefile	Sun Nov 24 10:20:46 2002
+++ work/freebsd-games-5.1.1/battlestar/Makefile	Wed Jun 23 21:47:57 2004
@@ -6,8 +6,8 @@
 	init.c cypher.c getcom.c parse.c room.c save.c fly.c misc.c \
 	globals.c dayfile.c nightfile.c dayobjs.c nightobjs.c words.c
 MAN=	battlestar.6
-DPADD=	${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lcurses -lcompat
+DPADD=	${LIBCURSES}
+LDADD=	-lcurses
 
 beforeinstall:
 .if !exists(${DESTDIR}/var/games/battlestar.log)
diff -ru work.orig/freebsd-games-5.1.1/cribbage/Makefile work/freebsd-games-5.1.1/cribbage/Makefile
--- work.orig/freebsd-games-5.1.1/cribbage/Makefile	Sun Nov 24 10:23:49 2002
+++ work/freebsd-games-5.1.1/cribbage/Makefile	Wed Jun 23 21:48:02 2004
@@ -2,8 +2,8 @@
 # $FreeBSD$
 
 PROG=	cribbage
-DPADD=	${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lcurses -lcompat
+DPADD=	${LIBCURSES}
+LDADD=	-lcurses
 SRCS=	extern.c crib.c cards.c instr.c io.c score.c support.c
 FILES=	cribbage.n
 FILESNAME_cribbage.n=	cribbage.instr
diff -ru work.orig/freebsd-games-5.1.1/hack/Makefile work/freebsd-games-5.1.1/hack/Makefile
--- work.orig/freebsd-games-5.1.1/hack/Makefile	Wed Jun 23 21:36:26 2004
+++ work/freebsd-games-5.1.1/hack/Makefile	Wed Jun 23 21:48:08 2004
@@ -15,8 +15,8 @@
 	hack.wizard.c hack.worm.c hack.worn.c hack.zap.c rnd.c \
 	hack.onames.h
 MAN=	hack.6
-DPADD=	${LIBTERMCAP} ${LIBCOMPAT}
-LDADD=	-ltermcap -lcompat
+DPADD=	${LIBTERMCAP}
+LDADD=	-ltermcap
 CFLAGS+= -fwritable-strings -I${.CURDIR} -I.
 BINGRP=	games
 BINMODE=2555
diff -ru work.orig/freebsd-games-5.1.1/hack/hack.tty.c work/freebsd-games-5.1.1/hack/hack.tty.c
--- work.orig/freebsd-games-5.1.1/hack/hack.tty.c	Wed Jun 23 21:36:26 2004
+++ work/freebsd-games-5.1.1/hack/hack.tty.c	Wed Jun 23 21:50:12 2004
@@ -95,8 +95,8 @@
 #define CBRKMASK	CBREAK
 #define CBRKON		/* empty */
 #define OSPEED(x)	(x).sg_ospeed
-#define GTTY(x)		(gtty(0, x))
-#define STTY(x)		(stty(0, x))
+#define GTTY(x)		(ioctl(0, TIOCGETP, x))
+#define STTY(x)		(ioctl(0, TIOCSETP, x))
 
 #endif /* USG */
 
diff -ru work.orig/freebsd-games-5.1.1/hangman/Makefile work/freebsd-games-5.1.1/hangman/Makefile
--- work.orig/freebsd-games-5.1.1/hangman/Makefile	Sun Nov 24 10:23:53 2002
+++ work/freebsd-games-5.1.1/hangman/Makefile	Wed Jun 23 21:48:12 2004
@@ -5,8 +5,8 @@
 SRCS=	endgame.c extern.c getguess.c getword.c main.c playgame.c \
 	prdata.c prman.c prword.c setup.c
 MAN=	hangman.6
-DPADD=	${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lcurses -lcompat
+DPADD=	${LIBCURSES}
+LDADD=	-lcurses
 
 .include <bsd.prog.mk>
 
diff -ru work.orig/freebsd-games-5.1.1/larn/Makefile work/freebsd-games-5.1.1/larn/Makefile
--- work.orig/freebsd-games-5.1.1/larn/Makefile	Mon Nov 10 18:47:00 2003
+++ work/freebsd-games-5.1.1/larn/Makefile	Wed Jun 23 21:48:20 2004
@@ -58,8 +58,8 @@
 SRCS=	main.c object.c create.c tok.c display.c global.c data.c io.c \
 	monster.c store.c diag.c help.c config.c nap.c bill.c scores.c \
 	signal.c moreobj.c movem.c regen.c fortune.c savelev.c
-DPADD=	${LIBTERMCAP} ${LIBCOMPAT}
-LDADD=	-ltermcap -lcompat
+DPADD=	${LIBTERMCAP}
+LDADD=	-ltermcap
 FILES=	larnmaze larnopts larn.help
 FILESDIR=	${SHAREDIR}/games/larn
 
diff -ru work.orig/freebsd-games-5.1.1/larn/io.c work/freebsd-games-5.1.1/larn/io.c
--- work.orig/freebsd-games-5.1.1/larn/io.c	Wed Jun 23 21:36:26 2004
+++ work/freebsd-games-5.1.1/larn/io.c	Wed Jun 23 21:50:56 2004
@@ -75,6 +75,9 @@
 #define CBREAK RAW		/* V7 has no CBREAK */
 #endif
 
+#define stty(_a,_b) ioctl(_a,TIOCSETP,_b)
+#define gtty(_a,_b) ioctl(_a,TIOCGETP,_b)
+
 #define doraw(_a) (_a.sg_flags |= CBREAK,_a.sg_flags &= ~ECHO)
 #define unraw(_a) (_a.sg_flags &= ~CBREAK,_a.sg_flags |= ECHO)
 #include <sgtty.h>
diff -ru work.orig/freebsd-games-5.1.1/mille/Makefile work/freebsd-games-5.1.1/mille/Makefile
--- work.orig/freebsd-games-5.1.1/mille/Makefile	Sun Nov 24 10:23:56 2002
+++ work/freebsd-games-5.1.1/mille/Makefile	Wed Jun 23 21:48:25 2004
@@ -4,8 +4,8 @@
 PROG=	mille
 SRCS=	comp.c end.c extern.c init.c mille.c misc.c move.c print.c \
 	roll.c save.c types.c varpush.c
-DPADD=	${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lcurses -lcompat
+DPADD=	${LIBCURSES}
+LDADD=	-lcurses
 MAN=	mille.6
 
 .include <bsd.prog.mk>
diff -ru work.orig/freebsd-games-5.1.1/phantasia/Makefile work/freebsd-games-5.1.1/phantasia/Makefile
--- work.orig/freebsd-games-5.1.1/phantasia/Makefile	Sun Nov 24 10:23:57 2002
+++ work/freebsd-games-5.1.1/phantasia/Makefile	Wed Jun 23 21:48:31 2004
@@ -3,8 +3,8 @@
 
 PROG=	phantasia
 SRCS=	main.c fight.c io.c interplayer.c gamesupport.c misc.c phantglobs.c
-DPADD=	${LIBM} ${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lm -lcurses -lcompat
+DPADD=	${LIBM} ${LIBCURSES}
+LDADD=	-lm -lcurses
 DATAFILES=characs gold lastdead mess monsters motd scoreboard void
 MAN=	phantasia.6
 CLEANFILES=${DATAFILES} cross-phantglobs.o map setup setup.o stamp.setuprun
diff -ru work.orig/freebsd-games-5.1.1/robots/Makefile work/freebsd-games-5.1.1/robots/Makefile
--- work.orig/freebsd-games-5.1.1/robots/Makefile	Sun Nov 24 10:24:01 2002
+++ work/freebsd-games-5.1.1/robots/Makefile	Wed Jun 23 21:48:35 2004
@@ -6,8 +6,8 @@
 SRCS=	extern.c init_field.c main.c make_level.c move.c move_robs.c \
 	play_level.c query.c rnd_pos.c score.c flush_in.c
 MAN=	robots.6
-DPADD=	${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lcurses -lcompat
+DPADD=	${LIBCURSES}
+LDADD=	-lcurses
 
 beforeinstall:
 .if !exists(${DESTDIR}/var/games/robots_roll)
diff -ru work.orig/freebsd-games-5.1.1/sail/Makefile work/freebsd-games-5.1.1/sail/Makefile
--- work.orig/freebsd-games-5.1.1/sail/Makefile	Sun Nov 24 10:24:02 2002
+++ work/freebsd-games-5.1.1/sail/Makefile	Wed Jun 23 21:48:39 2004
@@ -6,8 +6,8 @@
 	dr_main.c dr_1.c dr_2.c dr_3.c dr_4.c dr_5.c lo_main.c \
 	assorted.c game.c globals.c misc.c parties.c sync.c version.c
 MAN=	sail.6
-DPADD=	${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lcurses -lcompat
+DPADD=	${LIBCURSES}
+LDADD=	-lcurses
 
 beforeinstall:
 .if !exists(${DESTDIR}/var/games/saillog)
diff -ru work.orig/freebsd-games-5.1.1/trek/Makefile work/freebsd-games-5.1.1/trek/Makefile
--- work.orig/freebsd-games-5.1.1/trek/Makefile	Sun Nov 24 10:24:05 2002
+++ work/freebsd-games-5.1.1/trek/Makefile	Wed Jun 23 21:48:44 2004
@@ -11,7 +11,7 @@
 	shield.c snova.c srscan.c systemname.c torped.c utility.c \
 	visual.c warp.c win.c cgetc.c
 MAN=	trek.6
-DPADD=	${LIBM} ${LIBCOMPAT}
-LDADD=	-lm -lcompat
+DPADD=	${LIBM}
+LDADD=	-lm
 
 .include <bsd.prog.mk>
diff -ru work.orig/freebsd-games-5.1.1/trek/main.c work/freebsd-games-5.1.1/trek/main.c
--- work.orig/freebsd-games-5.1.1/trek/main.c	Wed Jun 23 21:36:27 2004
+++ work/freebsd-games-5.1.1/trek/main.c	Wed Jun 23 21:49:29 2004
@@ -47,6 +47,7 @@
 
 # include	"trek.h"
 # include	<stdio.h>
+# include	<sys/ioctl.h>
 # include	<sgtty.h>
 # include	<setjmp.h>
 # include       <stdlib.h>
@@ -174,7 +175,7 @@
 	srandomdev();
 	opencode = 'w';
 	prio = PRIO;
-	if (gtty(1, &argp) == 0)
+	if (ioctl(1, TIOCGETP, &argp) == 0)
 	{
 		if ((argp.sg_ispeed ) < B1200)
 			Etc.fast++;
diff -ru work.orig/freebsd-games-5.1.1/worm/Makefile work/freebsd-games-5.1.1/worm/Makefile
--- work.orig/freebsd-games-5.1.1/worm/Makefile	Sun Nov 24 10:24:06 2002
+++ work/freebsd-games-5.1.1/worm/Makefile	Wed Jun 23 21:48:48 2004
@@ -3,7 +3,7 @@
 
 PROG=	worm
 MAN=	worm.6
-DPADD=	${LIBCURSES} ${LIBCOMPAT}
-LDADD=	-lcurses -lcompat
+DPADD=	${LIBCURSES}
+LDADD=	-lcurses
 
 .include <bsd.prog.mk>
>Release-Note:
>Audit-Trail:
>Unformatted:



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