Subject: pkg/15763: [PATCH] Make games/xfrisk work on SunOS
To: None <gnats-bugs@gnats.netbsd.org>
From: None <sketch@rd.bbc.co.uk>
List: netbsd-bugs
Date: 02/28/2002 08:30:34
>Number:         15763
>Category:       pkg
>Synopsis:       [PATCH] Make games/xfrisk work on SunOS
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Feb 28 08:31:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Jonathan Perkin
>Release:        1.5ZA
>Organization:
British Broadcasting Corporation
>Environment:
NetBSD batfink.intra.nut 1.5ZA NetBSD 1.5ZA (BATFINK) #0: Wed Feb 20 21:10:17 GMT 2002     sketch@batfink.intra.nut:/usr/src/sys/arch/i386/compile/BATFINK i386
>Description:
Ok, as a Zoularis user I accept pointy hat for not testing my recently-
submitted xfrisk package on my Solaris box :)

Currently fails due to needing -lsocket -lnsl

Following patch solves the problem after quick check on tech-pkg on how
to do this in the neatest possible way.  I know the current developers
of XFrisk so hopefully can reduce patch-aa in next release.
>How-To-Repeat:

>Fix:
cvs diff: Diffing .
Index: Makefile
===================================================================
RCS file: /home/ncvs/pkgsrc/games/xfrisk/Makefile,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 Makefile
--- Makefile    2002/02/27 21:38:46     1.1.1.1
+++ Makefile    2002/02/28 16:21:18
@@ -18,4 +18,10 @@
 NO_SRC_ON_CDROM=${RESTRICTED}
 NO_BIN_ON_CDROM=${RESTRICTED}
 
+.include "../../mk/bsd.prefs.mk"
+
+.if ${OPSYS} == "SunOS"
+MAKE_ENV+=      LIBS="-lsocket -lnsl"
+.endif
+
 .include "../../mk/bsd.pkg.mk"
cvs diff: Diffing patches
Index: patches/patch-aa
===================================================================
RCS file: /home/ncvs/pkgsrc/games/xfrisk/patches/patch-aa,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 patch-aa
--- patches/patch-aa    2002/02/27 21:38:46     1.1.1.1
+++ patches/patch-aa    2002/02/28 16:26:40
@@ -1,7 +1,7 @@
 $NetBSD$
 
---- Makefile.orig      Sun Feb 24 21:34:38 2002
-+++ Makefile   Sun Feb 24 22:01:06 2002
+--- Makefile.orig      Sun Jan 23 19:01:55 2000
++++ Makefile   Thu Feb 28 16:07:20 2002
 @@ -77,11 +77,11 @@
  #CFLAGS+=-DTEST_GAME
  
@@ -27,3 +27,12 @@
  
  XLIBS=-L$(XDIR)/lib -l$(XAW) -lXext -lXmu -lXt -lSM -lICE -lX11
  
+@@ -106,7 +106,7 @@
+ # System V (Solaris, Irix, etc.) will probably want -lsocket -lnsl.
+ #LIBS=-lsocket -lnsl
+ # on other systems leave LIBS blank for now
+-LIBS=
++#LIBS=
+ 
+ # On some systems -DNARROWPROTO is needed for working Xaw scrollbars
+ # This includes FreeBSD 3.x and recent Linux

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