Skip to content

Commit

Permalink
pythonGH-107812: extend socket's netlink support to FreeBSD
Browse files Browse the repository at this point in the history
on FreeBSD, netlink.h lives under netlink.
Extend the AC_HEADER_CHECK to look there as well.
  • Loading branch information
igalic committed Aug 9, 2023
1 parent 65ce365 commit fb93864
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 1 deletion.
15 changes: 15 additions & 0 deletions configure

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2880,7 +2880,8 @@ AC_CHECK_HEADERS([net/if.h], [], [],
])

# On Linux, netlink.h requires asm/types.h
AC_CHECK_HEADERS([linux/netlink.h], [], [], [
# On FreeBSD, netlink.h is located in netlink/netlink.h
AC_CHECK_HEADERS([linux/netlink.h netlink/netlink.h], [], [], [
#ifdef HAVE_ASM_TYPES_H
#include <asm/types.h>
#endif
Expand Down
3 changes: 3 additions & 0 deletions pyconfig.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -841,6 +841,9 @@
/* Define to 1 if you have the <netinet/in.h> header file. */
#undef HAVE_NETINET_IN_H

/* Define to 1 if you have the <netlink/netlink.h> header file. */
#undef HAVE_NETLINK_NETLINK_H

/* Define to 1 if you have the <netpacket/packet.h> header file. */
#undef HAVE_NETPACKET_PACKET_H

Expand Down

0 comments on commit fb93864

Please sign in to comment.