From 4da2387af9c9ab8730c1bcbcd2f49385a7ba6bbb Mon Sep 17 00:00:00 2001 From: Mengwei Liu Date: Sun, 9 Mar 2025 12:08:30 -0700 Subject: [PATCH] Add a TARGETS file for executorch's buck build in oss Summary: In order for ExecuTorch's buck build to work in oss we need this TARGETS file. Test Plan: Reviewers: Subscribers: Tasks: Tags: --- third-party/TARGETS | 47 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 third-party/TARGETS diff --git a/third-party/TARGETS b/third-party/TARGETS new file mode 100644 index 0000000..978c123 --- /dev/null +++ b/third-party/TARGETS @@ -0,0 +1,47 @@ +load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime") + +oncall("executorch") + +runtime.cxx_library( + name = "abseil", + public_include_directories = ["abseil-cpp"], + srcs = glob( + ["abseil-cpp/absl/**/*.cc"], + exclude = [ + "abseil-cpp/absl/**/*test*.cc", + "abseil-cpp/absl/**/*mock*.cc", + "abseil-cpp/absl/**/*matchers*.cc", + "abseil-cpp/absl/**/*benchmark*.cc", + ], + ), + exported_linker_flags = select( + { + "DEFAULT": [], + "ovr_config//os:macos": ["-Wl,-framework,CoreFoundation"], + }, + ), + visibility = ["PUBLIC"], + _is_external_target = True, +) + +runtime.cxx_library( + name = "re2", + public_include_directories = ["re2"], + srcs = glob( + [ + "re2/re2/**/*.cc", + "re2/util/**/*.cc", + ], + exclude = [ + "re2/re2/**/*test*.cc", + "re2/re2/testing/*.cc", + "re2/re2/fuzzing/*.cc", + "re2/re2/**/*benchmark*.cc", + ], + ), + exported_deps = [ + ":abseil", + ], + visibility = ["PUBLIC"], + _is_external_target = True, +)