1load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime") 2 3def define_common_targets(): 4 """Defines targets that should be shared between fbcode and xplat. 5 6 The directory containing this targets.bzl file should also contain both 7 TARGETS and BUCK files that call this function. 8 9 See README.md for instructions on selective build. 10 """ 11 runtime.filegroup( 12 name = "templates", 13 srcs = native.glob([ 14 "templates/**/*.cpp", 15 "templates/**/*.ini", 16 "templates/**/*.h", 17 ]), 18 visibility = [ 19 "//executorch/...", 20 "@EXECUTORCH_CLIENTS", 21 ], 22 ) 23 24 runtime.cxx_library( 25 name = "macros", 26 exported_headers = [ 27 "macros.h", 28 ], 29 visibility = [ 30 "//executorch/runtime/kernel/...", 31 "//executorch/kernels/...", 32 "@EXECUTORCH_CLIENTS", 33 ], 34 ) 35