gvisor.dev/gvisor@v0.0.0-20240520182842-f9d4d51c7e0f/pkg/tcpip/transport/udp/BUILD (about) 1 load("//tools:defs.bzl", "go_library", "go_test") 2 load("//tools/go_generics:defs.bzl", "go_template_instance") 3 4 package( 5 default_applicable_licenses = ["//:license"], 6 licenses = ["notice"], 7 ) 8 9 go_template_instance( 10 name = "udp_packet_list", 11 out = "udp_packet_list.go", 12 package = "udp", 13 prefix = "udpPacket", 14 template = "//pkg/ilist:generic_list", 15 types = { 16 "Element": "*udpPacket", 17 "Linker": "*udpPacket", 18 }, 19 ) 20 21 go_library( 22 name = "udp", 23 srcs = [ 24 "endpoint.go", 25 "endpoint_state.go", 26 "forwarder.go", 27 "protocol.go", 28 "udp_packet_list.go", 29 ], 30 visibility = ["//visibility:public"], 31 deps = [ 32 "//pkg/buffer", 33 "//pkg/log", 34 "//pkg/sleep", 35 "//pkg/sync", 36 "//pkg/tcpip", 37 "//pkg/tcpip/checksum", 38 "//pkg/tcpip/header", 39 "//pkg/tcpip/header/parse", 40 "//pkg/tcpip/ports", 41 "//pkg/tcpip/stack", 42 "//pkg/tcpip/transport", 43 "//pkg/tcpip/transport/internal/network", 44 "//pkg/tcpip/transport/raw", 45 "//pkg/waiter", 46 ], 47 ) 48 49 go_test( 50 name = "udp_x_test", 51 size = "small", 52 srcs = ["udp_test.go"], 53 deps = [ 54 ":udp", 55 "//pkg/buffer", 56 "//pkg/refs", 57 "//pkg/tcpip", 58 "//pkg/tcpip/checker", 59 "//pkg/tcpip/checksum", 60 "//pkg/tcpip/faketime", 61 "//pkg/tcpip/header", 62 "//pkg/tcpip/link/channel", 63 "//pkg/tcpip/link/loopback", 64 "//pkg/tcpip/network/ipv4", 65 "//pkg/tcpip/network/ipv6", 66 "//pkg/tcpip/stack", 67 "//pkg/tcpip/testutil", 68 "//pkg/tcpip/transport", 69 "//pkg/tcpip/transport/icmp", 70 "//pkg/tcpip/transport/testing/context", 71 "//pkg/waiter", 72 ], 73 )