1load("//bazel:skia_rules.bzl", "skia_filegroup") 2 3# We export a known file inside the resources directory so that we can compute a path to said 4# directory from places that support "Make" variables[1], such as the "cmd" attribute[2] of a 5# genrule. For example, a genrule can compute the path to the resources directory from its "cmd" 6# attribute as follows: 7# 8# $$(dirname $$(rootpath //resources:README)) 9# 10# [1] https://bazel.build/reference/be/make-variables 11# [2] https://bazel.build/reference/be/general#genrule.cmd 12exports_files( 13 ["README"], 14 visibility = [ 15 "//bench:__pkg__", 16 "//gm:__pkg__", 17 "//tests:__pkg__", 18 ], 19) 20 21skia_filegroup( 22 name = "resources", 23 srcs = [ 24 "Cowboy.svg", 25 "crbug769134.fil", 26 "diff_canvas_traces/lorem_ipsum.trace", 27 "nov-talk-sequence.txt", 28 "pdf_command_stream.txt", 29 "//resources/sksl", 30 ] + glob( 31 [ 32 "android_fonts/**", 33 ], 34 allow_empty = False, 35 ) + glob( 36 [ 37 "empty_images/**", 38 ], 39 allow_empty = False, 40 ) + glob( 41 [ 42 "fonts/**", 43 ], 44 allow_empty = False, 45 ) + glob( 46 [ 47 "icc_profiles/**", 48 ], 49 allow_empty = False, 50 ) + glob( 51 [ 52 "images/**", 53 ], 54 allow_empty = False, 55 ) + glob( 56 [ 57 "invalid_images/**", 58 ], 59 allow_empty = False, 60 ) + glob( 61 [ 62 "skottie/**", 63 ], 64 allow_empty = False, 65 ) + glob( 66 [ 67 "text/**", 68 ], 69 allow_empty = False, 70 ), 71 visibility = [ 72 "//bench:__pkg__", 73 "//dm:__pkg__", 74 "//gm:__pkg__", 75 "//src/ports/fontations:__pkg__", 76 "//tests:__pkg__", 77 "//tools/viewer:__pkg__", 78 ], 79) 80 81filegroup( 82 name = "core_test_resources", 83 srcs = [ 84 "images/baby_tux.png", 85 "images/baby_tux.webp", 86 ], 87 visibility = [ 88 "//tests:__pkg__", 89 ], 90) 91