github.com/hxx258456/ccgo@v0.0.5-0.20230213014102-48b35f46f66f/net/route/defs_netbsd.go (about) 1 // Copyright 2016 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 //go:build ignore 6 // +build ignore 7 8 package route 9 10 /* 11 #include <sys/socket.h> 12 #include <sys/sysctl.h> 13 14 #include <net/if.h> 15 #include <net/if_dl.h> 16 #include <net/route.h> 17 18 #include <netinet/in.h> 19 */ 20 import "C" 21 22 const ( 23 sysAF_UNSPEC = C.AF_UNSPEC 24 sysAF_INET = C.AF_INET 25 sysAF_ROUTE = C.AF_ROUTE 26 sysAF_LINK = C.AF_LINK 27 sysAF_INET6 = C.AF_INET6 28 29 sysSOCK_RAW = C.SOCK_RAW 30 31 sysNET_RT_DUMP = C.NET_RT_DUMP 32 sysNET_RT_FLAGS = C.NET_RT_FLAGS 33 sysNET_RT_IFLIST = C.NET_RT_IFLIST 34 sysNET_RT_MAXID = C.NET_RT_MAXID 35 ) 36 37 const ( 38 sysCTL_MAXNAME = C.CTL_MAXNAME 39 40 sysCTL_UNSPEC = C.CTL_UNSPEC 41 sysCTL_KERN = C.CTL_KERN 42 sysCTL_VM = C.CTL_VM 43 sysCTL_VFS = C.CTL_VFS 44 sysCTL_NET = C.CTL_NET 45 sysCTL_DEBUG = C.CTL_DEBUG 46 sysCTL_HW = C.CTL_HW 47 sysCTL_MACHDEP = C.CTL_MACHDEP 48 sysCTL_USER = C.CTL_USER 49 sysCTL_DDB = C.CTL_DDB 50 sysCTL_PROC = C.CTL_PROC 51 sysCTL_VENDOR = C.CTL_VENDOR 52 sysCTL_EMUL = C.CTL_EMUL 53 sysCTL_SECURITY = C.CTL_SECURITY 54 sysCTL_MAXID = C.CTL_MAXID 55 ) 56 57 const ( 58 sysRTM_VERSION = C.RTM_VERSION 59 60 sysRTM_ADD = C.RTM_ADD 61 sysRTM_DELETE = C.RTM_DELETE 62 sysRTM_CHANGE = C.RTM_CHANGE 63 sysRTM_GET = C.RTM_GET 64 sysRTM_LOSING = C.RTM_LOSING 65 sysRTM_REDIRECT = C.RTM_REDIRECT 66 sysRTM_MISS = C.RTM_MISS 67 sysRTM_LOCK = C.RTM_LOCK 68 sysRTM_OLDADD = C.RTM_OLDADD 69 sysRTM_OLDDEL = C.RTM_OLDDEL 70 sysRTM_RESOLVE = C.RTM_RESOLVE 71 sysRTM_NEWADDR = C.RTM_NEWADDR 72 sysRTM_DELADDR = C.RTM_DELADDR 73 sysRTM_IFANNOUNCE = C.RTM_IFANNOUNCE 74 sysRTM_IEEE80211 = C.RTM_IEEE80211 75 sysRTM_SETGATE = C.RTM_SETGATE 76 sysRTM_LLINFO_UPD = C.RTM_LLINFO_UPD 77 sysRTM_IFINFO = C.RTM_IFINFO 78 sysRTM_CHGADDR = C.RTM_CHGADDR 79 80 sysRTA_DST = C.RTA_DST 81 sysRTA_GATEWAY = C.RTA_GATEWAY 82 sysRTA_NETMASK = C.RTA_NETMASK 83 sysRTA_GENMASK = C.RTA_GENMASK 84 sysRTA_IFP = C.RTA_IFP 85 sysRTA_IFA = C.RTA_IFA 86 sysRTA_AUTHOR = C.RTA_AUTHOR 87 sysRTA_BRD = C.RTA_BRD 88 sysRTA_TAG = C.RTA_TAG 89 90 sysRTAX_DST = C.RTAX_DST 91 sysRTAX_GATEWAY = C.RTAX_GATEWAY 92 sysRTAX_NETMASK = C.RTAX_NETMASK 93 sysRTAX_GENMASK = C.RTAX_GENMASK 94 sysRTAX_IFP = C.RTAX_IFP 95 sysRTAX_IFA = C.RTAX_IFA 96 sysRTAX_AUTHOR = C.RTAX_AUTHOR 97 sysRTAX_BRD = C.RTAX_BRD 98 sysRTAX_TAG = C.RTAX_TAG 99 sysRTAX_MAX = C.RTAX_MAX 100 ) 101 102 const ( 103 sizeofIfMsghdrNetBSD7 = C.sizeof_struct_if_msghdr 104 sizeofIfaMsghdrNetBSD7 = C.sizeof_struct_ifa_msghdr 105 sizeofIfAnnouncemsghdrNetBSD7 = C.sizeof_struct_if_announcemsghdr 106 107 sizeofRtMsghdrNetBSD7 = C.sizeof_struct_rt_msghdr 108 sizeofRtMetricsNetBSD7 = C.sizeof_struct_rt_metrics 109 110 sizeofSockaddrStorage = C.sizeof_struct_sockaddr_storage 111 sizeofSockaddrInet = C.sizeof_struct_sockaddr_in 112 sizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 113 )