Subject: Trying to upgrade zoularis...
To: None <tech-pkg@netbsd.org>
From: Hauke Fath <hauke@Espresso.Rhein-Neckar.DE>
List: tech-pkg
Date: 04/10/2001 23:53:30
... to zoularis-20010311 / -current netbsd sources of 25 Mar / ss10 &
Solaris 7, I get


(1)

gcc -pipe -O2   -I/usr/pkg/include -D__EXTENSIONS__ -D_XPG4_2 -DSUNOS_5_7 -I/home/hauke/src/zoularis-20010311/zoularis/bsd/lib/libbsdcompat -I/usr/bsdsrc/lib/libc/include -D__DBINTERFACE_PRIVATE -DOLD_GETCWD -DSUNOS_5_7 -c -fPIC -DPIC pwd.c -o pwd.so
gcc -pipe -O2   -I/usr/pkg/include -D__EXTENSIONS__ -D_XPG4_2 -DSUNOS_5_7 -I/home/hauke/src/zoularis-20010311/zoularis/bsd/lib/libbsdcompat -I/usr/bsdsrc/lib/libc/include -D__DBINTERFACE_PRIVATE -DOLD_GETCWD -DSUNOS_5_7 -c /usr/bsdsrc/lib/libc/net/rcmd.c
/usr/bsdsrc/lib/libc/net/rcmd.c: In function `rresvport_af':
/usr/bsdsrc/lib/libc/net/rcmd.c:519: argument `family' doesn't match prototype
/usr/pkg/include/unistd.h:96: prototype declaration
*** Error code 1

Stop.


<unistd.h> has 

#ifndef SUNOS_5_8 /*INET6*/
#include <sys/socket.h>
int     rresvport_af __P((int *, sa_family_t));
int     ruserok_af __P((const char *, int, const char *, 
	const char *, sa_family_t));
int     iruserok_af __P((const void *, int, const char *, 
	const char *, sa_family_t));
#endif 


while rcmd.c and the NetBSD <unistd.h> have

int
rresvport_af(alport, family)
        int *alport;
        int family;

-- can apparently be fixed in <unistd.h> with 
	"#if !(defined (SUNOS_5_8) ||  defined (SUNOS_5_7))"


(2)

mv -f /usr/pkg/lib/libbsdcompat.so.tmp /usr/pkg/lib/libbsdcompat.so
gcc -pipe -O2   -I/usr/pkg/include -D__EXTENSIONS__ -D_XPG4_2 -DSUNOS_5_7 -DFLOATING_POINT -I/home/hauke/src/zoularis-20010311/zoularis/bsd/lib/libbsdstdio -I/usr/bsdsrc/lib/libc/include -DBSDSTDIO -DSUNOS_5_7 -c /usr/bsdsrc/lib/libc/stdio/_fseeko.c
In file included from /usr/pkg/include/stdio.h:70,
                 from /usr/bsdsrc/lib/libc/stdio/_fseeko.c:37:
/usr/pkg/include/bsd/stdio.h:233: parse error before `fread'
/usr/pkg/include/bsd/stdio.h:233: parse error before `size_t'
/usr/pkg/include/bsd/stdio.h:233: warning: data definition has no type or storage class
/usr/pkg/include/bsd/stdio.h:239: parse error before `fwrite'
/usr/pkg/include/bsd/stdio.h:239: parse error before `size_t'
/usr/pkg/include/bsd/stdio.h:240: warning: data definition has no type or storage class
/usr/pkg/include/bsd/stdio.h:252: parse error before `size_t'
/usr/pkg/include/bsd/stdio.h:333: parse error before `size_t'
/usr/pkg/include/bsd/stdio.h:335: parse error before `size_t'
/usr/pkg/include/bsd/stdio.h:369: parse error before `size_t'
*** Error code 1


-- Looks like no usable definition of size_t can be found. 
<sys/types.h> has


#if defined(_BSD_SIZE_T_) && !defined(_SIZE_T)
typedef _BSD_SIZE_T_            size_t;
#undef  _BSD_SIZE_T_
#define _SIZE_T
#define __size_t_defined
#endif

-- who defines _BSD_SIZE_T_, and where? Why is there no <stddef.h>?

I am stuck here, in a maze of little include files, all alike. When is 
the zoularis include dir used (/usr/pkg/include for me), when the
Solaris /usr/include?

Can anybody shed a little light, please?

	hauke