Subject: pkg/20613: bind 9.2.2 fails to compile
To: None <gnats-bugs@gnats.netbsd.org>
From: None <kefren@netbastards.org>
List: netbsd-bugs
Date: 03/07/2003 18:03:42
>Number:         20613
>Category:       pkg
>Synopsis:       pkgsrc bind-9.2.2 fails to compile (patch included)
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Fri Mar 07 08:04:00 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Mihai CHELARU
>Release:        NetBSD 1.6P
>Organization:
	
None
>Environment:
	
	
System: NetBSD kefren.girsa.ro 1.6P NetBSD 1.6P (Kefren) #5: Fri Mar 7 13:18:54 EET 2003 root@kefren.girsa.ro:/sys/arch/i386/compile/Kefren i386
Architecture: i386
Machine: i386
>Description:
	
	pkgsrc bind-9.2.2 needs some patches to compile
>How-To-Repeat:
	
>Fix:
	

--- configure.orig	2003-03-07 17:20:33.000000000 +0200
+++ configure	2003-03-07 17:43:33.000000000 +0200
@@ -4652,7 +4652,7 @@
 *-netbsd*)
 	# Socket I/O optimizations introduced in 9.2 expose a
 	# bug in unproven-pthreads; see PR #12650
-	use_threads=false ;;
+	use_threads=true ;;
 *-openbsd*)
 	# OpenBSD users have reported that named dumps core on
 	# startup when built with threads.
@@ -4707,61 +4707,6 @@
 	#
 	# Search for / configure pthreads in a system-dependent fashion.
 	#
-	case "$host" in
-	  *-netbsd*)
-		# NetBSD has multiple pthreads implementations.	 The
-		# recommended one to use is "unproven-pthreads".  The
-		# older "mit-pthreads" may also work on some NetBSD
-		# versions.  The PTL2 thread library does not
-		# currently work with bind9, but can be chosen with
-		# the --with-ptl2 option for those who wish to
-		# experiment with it.
-		CC="gcc"
-		echo "$as_me:$LINENO: checking which NetBSD thread library to use" >&5
-echo $ECHO_N "checking which NetBSD thread library to use... $ECHO_C" >&6
-
-
-# Check whether --with-ptl2 or --without-ptl2 was given.
-if test "${with_ptl2+set}" = set; then
-  withval="$with_ptl2"
-  use_ptl2="$withval"
-else
-  use_ptl2="no"
-fi;
-
-		: ${LOCALBASE:=/usr/pkg}
-
-		if test "X$use_ptl2" = "Xyes"
-		then
-			echo "$as_me:$LINENO: result: PTL2" >&5
-echo "${ECHO_T}PTL2" >&6
-			{ echo "$as_me:$LINENO: WARNING: linking with PTL2 is highly experimental and not expected to work" >&5
-echo "$as_me: WARNING: linking with PTL2 is highly experimental and not expected to work" >&2;}
-			CC=ptlgcc
-		else
-			if test ! -d $LOCALBASE/pthreads
-			then
-				echo "$as_me:$LINENO: result: none" >&5
-echo "${ECHO_T}none" >&6
-				{ { echo "$as_me:$LINENO: error: \"could not find thread libraries\"" >&5
-echo "$as_me: error: \"could not find thread libraries\"" >&2;}
-   { (exit 1); exit 1; }; }
-			fi
-
-			if $use_threads
-			then
-				echo "$as_me:$LINENO: result: mit-pthreads/unproven-pthreads" >&5
-echo "${ECHO_T}mit-pthreads/unproven-pthreads" >&6
-				pkg="$LOCALBASE/pthreads"
-				lib1="-L$pkg/lib -Wl,-R$pkg/lib"
-				lib2="-lpthread -lm -lgcc -lpthread"
-				LIBS="$lib1 $lib2 $LIBS"
-				CPPFLAGS="$CPPFLAGS -I$pkg/include"
-				STD_CINCLUDES="$STD_CINCLUDES -I$pkg/include"
-			fi
-		fi
-		;;
-		*)
 
 echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
 echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6
@@ -5095,8 +5040,6 @@
 
 fi
 
-		;;
-	esac
 fi
 
 if $use_threads
>Release-Note:
>Audit-Trail:
>Unformatted: