Subject: pkg/12199: configure tests incorrectly for IPv6
To: None <>
From: Olaf Seibert <>
List: netbsd-bugs
Date: 02/13/2001 14:11:50
>Number:         12199
>Category:       pkg
>Synopsis:       configure tests incorrectly for IPv6 (php4)
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Feb 13 05:13:00 PST 2001
>Originator:     Olaf Seibert
>Release:        current pkgsrc
System: NetBSD 1.4.2 NetBSD 1.4.2 (KIELDRECHT) #11: Wed Jul 19 14:00:31 CEST 2000 root@kieldrecht:/usr/src/sys/arch/i386/compile/KIELDRECHT i386

	Configure uses an incorrect test program to check for availability
	of IPv6. I noticed this for the php4 package but I'm sure it is
	a more general configure problem.

	This is the code that is used:

	#line 6338 "configure"
	#include "confdefs.h"
	#include <sys/socket.h>
	#include <netinet/in.h>
	int main() {
	struct sockaddr_in6 s; int i=AF_INET6; s
	; return 0; }

	What is missing is an #include <sys/types.h>. The compilation
	fails with messages like

	configure:6333: checking for IPv6 support
	configure:6346: cc -c -O2  -I/usr/pkg/include -I/usr/pkg/include conftest.c 1>&5
	In file included from configure:6339:
	/usr/include/sys/socket.h:186: syntax error before `u_char'
	/usr/include/sys/socket.h:214: syntax error before `u_char'
	/usr/include/sys/socket.h:216: `int64_t' undeclared here (not in a function)
	/usr/include/sys/socket.h:216: `u_char' undeclared here (not in a function)
	/usr/include/sys/socket.h:217: syntax error before `int64_t'
	...and more.
	This is independent of actual support of IPv6.
	cd www/ap-php4 && make
	notice the configure output includes

	checking for IPv6 support: no
	workaround: patch configure script in each relevant case.

___ Olaf 'Rhialto' Seibert - rhialto@polder --Soep van de dag, wat zal dat zijn
\X/     --wat kan dat wezen, beter maar het ergste vrezen -Boy Bensdorp