[Date Prev][Date Next]
Re: Build Problems for 2.1.13 with Win2K/Cygwin (ITS#2333)
On Thu, 27 Feb 2003 14:12:28 GMT
> Full_Name: Matt Heitker
> Version: 2.1.13
> OS: Win 2K/Cygwin
> URL: ftp://ftp.openldap.org/incoming/
> Submission from: (NULL) (126.96.36.199)
> When I downloaded 2.1.13 and tried to build it, it had problems with
> liblutil/getpeereid.c and libldap/os-local.c.
> Both were looking for a definition of "struct iovec", which was not
For reference, MacOS X exhibits this same problem in both 2.1.13 and
#including <sys/uio.h> does indeed show it what an iovec is, and seems
to be appropriate for code using readv/writev.
Unfortunately, that is not sufficient to get it to build:
getpeereid.c: In function `getpeereid':
getpeereid.c:61: structure has no member named `msg_accrights'
getpeereid.c:62: structure has no member named `msg_accrightslen'
getpeereid.c:63: structure has no member named `msg_accrightslen'
grepping, I find those are indeed not present in struct msghdr, but
rather in struct omsghdr.
Curious, I looked at my linux box and found the following in
* As we do 4.4BSD message passing we use a 4.4BSD message passing
* system, not 4.3. Thus msg_accrights(len) are now missing. They
* belong in an obscure libc emulation or the bin.
Hm. So linux doesn't have msg_accrights* either.
MacOS X happens to include enough of BSD5ish things to have
getpeereid() documented in the manpages.
Unfortunately they did not include it in libc, even though it is
documented. Sigh. AC_REPLACE_FUNCS correctly decides to replace it.
About this point I realized that all of this fuss is used only for
unix domain sockets, which I'm not using.
adding --disable-local to ./configure seems to have fixed things.
configure.in only checks for a valid <sys/un.h> before enabling local.
The problem is, local gets enabled on my linux hosts and they build it
getpeereid.c:21 tests for SO_PEERCRED, which is defined on the linux
hosts but not the mac. As a result, DO_SENDMSG gets #define'd and it
tries to use msg_accrights* stuff that doesn't exist anymore.
I'm not sure what to do with that, other than --disable-local and go
about my merry business for now... ^_^
$ uname -a
Darwin Peregrine 6.3 Darwin Kernel Version 6.3: Sat Dec 14 03:11:25 PST 2002; root:xnu/xnu-344.23.obj~4/RELEASE_PPC Power Macintosh powerpc
$ gcc -v
Reading specs from /usr/libexec/gcc/darwin/ppc/3.1/specs
Thread model: posix
Apple Computer, Inc. GCC version 1151, based on gcc version 3.1 20020420 (prerelease)