include/X11/Xos_r.h and NetBSD

Jeremy C. Reed reed at
Sat Oct 15 18:43:59 PDT 2005

On Sat, 15 Oct 2005, Jeremy C. Reed wrote:

> I was building libX11-0.99.0 on NetBSD/i386 3.0_BETA and it failed with
>  cc -DHAVE_CONFIG_H -I. -I../include/X11 
> -I/tmp/pkgsrc/wip/libX11/work.glacier/.buildlink/include -I../include 
> -I../src/xcms -I../src/xkb -I../src/xlibi18n -Wall -Wpointer-arith 
> -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations 
> -Wnested-externs -fno-strict-aliasing -D_BSD_SOURCE -DHAS_FCHOWN 
> .deps/GetDflt.Tpo -c GetDflt.c  -fPIC -DPIC -o .libs/GetDflt.o
>  GetDflt.c: In function `GetHomeDir':
>  GetDflt.c:133: error: too few arguments to function `getpwnam_r'
>  GetDflt.c:135: error: too few arguments to function `getpwuid_r'
>  gmake[3]: *** [GetDflt.lo] Error 1
> My xproto is from xproto-7.0. Both from X11R7.0-RC0.
> NetBSD's GETPWENT(3) Man page says:
>     getpwnam_r(const char *name, struct passwd *pw, char *buffer,
>         size_t buflen, struct passwd **result);
>     getpwuid_r(uid_t uid, struct passwd *pw, char *buffer, size_t buflen,
>         struct passwd **result);
> I see changes to lib/X11/ and others.
> When will a release candidate download be available for these?
> I also had the following when I attempt to run autoconf:
> error: m4_defn: undefined macro: _m4_divert_diversion

Ignore this problem. I had used a corruped file.

> So I have not tested yet whether new xorg/lib/X11 cvs works on NetBSD yet.

I found an error in libX11/

The test expression for xthreads uses two equals. This is not portable.
if test x$xthreads == xyes ; then

And NetBSD complains:

test: ==: unexpected operator

I fixed that on my system to use one =.

I also had:

         XTHREADLIB=-lpthread ;;

And it did build with -D_THREAD_SAFE, but no change. Same error.

I saw in

# define SystemMTDefines        -D_REENTRANT

So I build using:
and that GetDflt.c compiled.

Should I file a bug report?

I didn't have a chance today to try against CVS...

  Jeremy C. Reed

  	  	 	 technical support & remote administration

More information about the xorg-modular mailing list