Subject: pkg/24536: net/netcat doesn't builds on OpenBSD
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <pancake@panser.panser>
List: netbsd-bugs
Date: 02/23/2004 17:52:08
>Number:         24536
>Category:       pkg
>Synopsis:       net/netcat doesn't builds on OpenBSD
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Feb 23 16:44:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     
>Release:        NetBSD 1.6ZK
>Organization:
	
>Environment:
	
	
System: NetBSD panser 1.6ZK NetBSD 1.6ZK (PANCAKE-PANSER-SERVER) #0: Mon Feb 16 19:05:05 CET 2004 pancake@panser:/usr/src/sys/arch/i386/compile/PANCAKE_PANSER i386
Architecture: i386
Machine: i386
>Description:
	Netcat takes OPSYS_LOWER as ALL_TARGET, OpenBSD isn't supported by
	netcat makefile, the solution is type 'netbsd' instead of OPSYS,
	and it compiles and works perfectly.
	
>How-To-Repeat:
	# uname -a
	OpenBSD ops 3.4 GENERIC#18 i386
	# pwd
	/usr/pkgsrc/net/netcat
	# bmake
	(..)
	
>Fix:

Apply this patch or something similar :P	

--- Makefile.orig	Tue Jan 20 13:22:20 2004
+++ Makefile	Mon Feb 23 17:46:07 2004
@@ -21,7 +21,13 @@
 WRKSRC=		${WRKDIR}
 USE_BUILDLINK3=	yes
 MAKE_ENV+=	DFLAGS="-DGAPING_SECURITY_HOLE -DTELNET"
+.if defined(LOWER_OPSYS)
+.  if (${LOWER_OPSYS} == "openbsd")
+ALL_TARGET=	netbsd
+.else
 ALL_TARGET=	${LOWER_OPSYS}
+.endif
+.endif
 
 EXTRA_PROGS=	data rservice xor
 EXAMPLE_DIR=	share/examples/nc
	
>Release-Note:
>Audit-Trail:
>Unformatted:
 	But really tested on OpenBSD 3.4