golang.org/x/net@v0.25.1-0.20240516223405-c87a5b62e243/route/defs_darwin.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  
     7  package route
     8  
     9  /*
    10  #include <sys/socket.h>
    11  #include <sys/sysctl.h>
    12  
    13  #include <net/if.h>
    14  #include <net/if_dl.h>
    15  #include <net/route.h>
    16  
    17  #include <netinet/in.h>
    18  */
    19  import "C"
    20  
    21  const (
    22  	sizeofIfMsghdrDarwin15    = C.sizeof_struct_if_msghdr
    23  	sizeofIfaMsghdrDarwin15   = C.sizeof_struct_ifa_msghdr
    24  	sizeofIfmaMsghdrDarwin15  = C.sizeof_struct_ifma_msghdr
    25  	sizeofIfMsghdr2Darwin15   = C.sizeof_struct_if_msghdr2
    26  	sizeofIfmaMsghdr2Darwin15 = C.sizeof_struct_ifma_msghdr2
    27  	sizeofIfDataDarwin15      = C.sizeof_struct_if_data
    28  	sizeofIfData64Darwin15    = C.sizeof_struct_if_data64
    29  
    30  	sizeofRtMsghdrDarwin15  = C.sizeof_struct_rt_msghdr
    31  	sizeofRtMsghdr2Darwin15 = C.sizeof_struct_rt_msghdr2
    32  	sizeofRtMetricsDarwin15 = C.sizeof_struct_rt_metrics
    33  
    34  	sizeofSockaddrStorage = C.sizeof_struct_sockaddr_storage
    35  	sizeofSockaddrInet    = C.sizeof_struct_sockaddr_in
    36  	sizeofSockaddrInet6   = C.sizeof_struct_sockaddr_in6
    37  )