#64 wkcgi doesn't build on Mac OS X

closed-fixed
WebKit (58)
5
2004-03-26
2004-03-04
Josh Minor
No

When building wkcgi on Mac OS X the following error is reported:

In file included from ../common/wkcommon.h:20,
from wkcgi.h:6,
from wkcgi.c:5:
/usr/include/resolv.h:174: error: field `nsaddr_list' has incomplete
type
/usr/include/resolv.h:188: error: field `addr' has incomplete type
/usr/include/resolv.h:216: error: field `sin' has incomplete type

The fix is to add:
#include <tcpd.h>

right before:
#include <resolv.h>

in common/wkcommon.h

Discussion

  • Ian Bicking

    Ian Bicking - 2004-03-04

    Logged In: YES
    user_id=210337

    Do you know what we should use to determine the system?
    (E.g., #ifdef BSD or somthing)

    I can confirm that tcpd.h exists on a FreeBSD system, but
    not on a Debian Linux system.

     
  • Jason Hildebrand

    Logged In: YES
    user_id=173690

    Thanks for the bug report. I will add the missing line, but
    I don't want to break the build for other OS's which may not
    have tcpd.h.

    The file in question contains:

    #if defined(__MACH__) && defined(__APPLE__)
    #include <nameser.h>
    #endif
    #include <resolv.h>
    #endif

    I'm assuming __MACH__ and __APPLE__ are defined on OSX, so
    the missing line can be added inside that #if like so:

    #if defined(__MACH__) && defined(__APPLE__)
    #include <nameser.h>
    #include <tcpd.h>
    #endif
    #include <resolv.h>
    #endif

    Could you please confirm that this works for you?

     
  • Jason Hildebrand

    • assigned_to: nobody --> jdhildeb
     
  • Jason Hildebrand

    • status: open --> closed-fixed
     
  • Jason Hildebrand

    Logged In: YES
    user_id=173690

    No confirmation from reporter, but I think the fix as
    committed is correct. Closing this bug.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks