Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
File renamed without changes.
4 changes: 4 additions & 0 deletions backends/aoti/slim/c10/core/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_common_targets():
"""Define targets for SlimTensor c10 core module."""

if not is_fbcode():
return

# Header-only library for DeviceType
runtime.cxx_library(
name = "device_type",
Expand Down
File renamed without changes.
4 changes: 4 additions & 0 deletions backends/aoti/slim/util/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_common_targets():
"""Define targets for SlimTensor util module."""

if not is_fbcode():
return

# Header-only library for SharedPtr
runtime.cxx_library(
name = "shared_ptr",
Expand Down
File renamed without changes.
4 changes: 4 additions & 0 deletions backends/aoti/slim/util/test/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_common_targets():
"""Define test targets for SlimTensor util module."""

if not is_fbcode():
return

runtime.cxx_test(
name = "test_size_util",
srcs = [
Expand Down
4 changes: 4 additions & 0 deletions backends/aoti/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_common_targets():
if not is_fbcode():
return

runtime.python_library(
name = "aoti_partitioner",
srcs = [
Expand Down
6 changes: 5 additions & 1 deletion backends/qualcomm/partition/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_common_targets():
if not is_fbcode():
return

"""Defines targets that should be shared between fbcode and xplat.
The directory containing this targets.bzl file should also contain both
TARGETS and BUCK files that call this function.
"""

runtime.python_library(
name = "partition",
srcs = glob([
Expand Down
4 changes: 4 additions & 0 deletions devtools/etdump/data_sinks/tests/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_data_sink_test(data_sink_name):
runtime.cxx_test(
Expand All @@ -19,5 +20,8 @@ def define_common_targets():
TARGETS and BUCK files that call this function.
"""

if not is_fbcode():
return

define_data_sink_test("buffer_data_sink")
define_data_sink_test("file_data_sink")
4 changes: 4 additions & 0 deletions examples/models/llama/experimental/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_common_targets():
if not is_fbcode():
return

runtime.python_library(
name = "subclass",
srcs = [
Expand Down
File renamed without changes.
4 changes: 4 additions & 0 deletions extension/kernel_util/test/targets.bzl
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load("@fbsource//tools/build_defs:fbsource_utils.bzl", "is_fbcode")

def define_common_targets():
"""Defines targets that should be shared between fbcode and xplat.

The directory containing this targets.bzl file should also contain both
TARGETS and BUCK files that call this function.
"""
if not is_fbcode():
return

runtime.cxx_test(
name = "make_boxed_from_unboxed_functor_test",
srcs = [
Expand Down
Loading