Mercurial > hgrepos > FreeBSD > ports > PyPy
view files/patch-rpython_rlib___rsocket__rffi.py @ 61:e12dfbf0a674
Support the byte-compilation: add an extra PLIST_SUB variable
| author | Franz Glasner <hg@dom66.de> |
|---|---|
| date | Wed, 10 Jan 2024 18:47:48 +0100 |
| parents | 585cf5a218ad |
| children |
line wrap: on
line source
--- rpython/rlib/_rsocket_rffi.py.orig 2023-12-23 15:29:17 UTC +++ rpython/rlib/_rsocket_rffi.py @@ -16,6 +16,7 @@ _MSVC = target_platform.name == "msvc" _MINGW = target_platform.name == "mingw32" _SOLARIS = sys.platform == "sunos5" _MACOSX = sys.platform == "darwin" +_FREEBSD = sys.platform.startswith('freebsd') _HAS_AF_PACKET = sys.platform.startswith('linux') # only Linux for now if _POSIX: @@ -42,7 +43,10 @@ if _POSIX: 'sys/ioctl.h', ) - cond_includes = [('AF_NETLINK', 'linux/netlink.h')] + if _FREEBSD: + cond_includes = [('AF_NETLINK', 'netlink/netlink.h')] + else: + cond_includes = [('AF_NETLINK', 'linux/netlink.h')] libraries = () calling_conv = 'c'
