github.com/SagerNet/gvisor@v0.0.0-20210707092255-7731c139d75c/pkg/sentry/time/BUILD (about) 1 load("//tools:defs.bzl", "go_library", "go_test") 2 load("//tools/go_generics:defs.bzl", "go_template_instance") 3 4 package(licenses = ["notice"]) 5 6 go_template_instance( 7 name = "seqatomic_parameters", 8 out = "seqatomic_parameters_unsafe.go", 9 package = "time", 10 suffix = "Parameters", 11 template = "//pkg/sync/seqatomic:generic_seqatomic", 12 types = { 13 "Value": "Parameters", 14 }, 15 ) 16 17 go_library( 18 name = "time", 19 srcs = [ 20 "arith_arm64.go", 21 "calibrated_clock.go", 22 "clock_id.go", 23 "clocks.go", 24 "muldiv_amd64.s", 25 "muldiv_arm64.s", 26 "parameters.go", 27 "sampler.go", 28 "sampler_amd64.go", 29 "sampler_arm64.go", 30 "sampler_unsafe.go", 31 "seqatomic_parameters_unsafe.go", 32 "tsc_amd64.s", 33 "tsc_arm64.s", 34 ], 35 visibility = ["//:sandbox"], 36 deps = [ 37 "//pkg/errors/linuxerr", 38 "//pkg/gohacks", 39 "//pkg/log", 40 "//pkg/metric", 41 "//pkg/sync", 42 "//pkg/syserror", 43 "@org_golang_x_sys//unix:go_default_library", 44 ], 45 ) 46 47 go_test( 48 name = "time_test", 49 srcs = [ 50 "calibrated_clock_test.go", 51 "parameters_test.go", 52 "sampler_test.go", 53 ], 54 library = ":time", 55 )