Nadeem Vawda <nadeem.va...@gmail.com> added the comment:

Also failing to compile on OS X:

http://www.python.org/dev/buildbot/all/builders/AMD64%20Leopard%203.x/builds/1385/steps/test/logs/stdio

The problem seems to be that <net/if.h> is not being included on these
non-Linux systems. Looking at Modules/socketmodule.h reveals that its
inclusion is conditional on HAVE_NETPACKET_PACKET_H:

    #ifdef HAVE_NETPACKET_PACKET_H
    # include <sys/ioctl.h>
    # include <net/if.h>
    # include <netpacket/packet.h>
    #endif

Changing it to something like this should solve the problem:

    #ifdef HAVE_NET_IF_H
    # include <net/if.h>
    #endif

    #ifdef HAVE_NETPACKET_PACKET_H
    # include <sys/ioctl.h>
    # include <netpacket/packet.h>
    #endif

----------
nosy: +nadeem.vawda

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue1746656>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to