Skip to content
Open
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
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest")

oncall("executorch")

python_unittest(
fbcode_target(_kind = python_unittest,
name = "test_delegation_info",
srcs = [
"test_delegation_info.py",
Expand Down
49 changes: 48 additions & 1 deletion devtools/bundled_program/BUCK
Original file line number Diff line number Diff line change
@@ -1,5 +1,52 @@
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
load(":targets.bzl", "define_common_targets")

oncall("executorch")

define_common_targets()
non_fbcode_target(_kind = define_common_targets,)

# !!!! fbcode/executorch/devtools/bundled_program/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!!

load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load(":targets.bzl", "define_common_targets")


fbcode_target(_kind = define_common_targets,)

fbcode_target(_kind = runtime.python_library,
name = "core",
srcs = [
"core.py",
],
visibility = ["PUBLIC"],
deps = [
":config",
":version",
"//caffe2:torch",
"//executorch/devtools/bundled_program/schema:bundled_program_schema_py",
"//executorch/exir:schema",
"//executorch/exir:tensor",
],
)

fbcode_target(_kind = runtime.python_library,
name = "config",
srcs = [
"config.py",
],
visibility = ["PUBLIC"],
deps = [
"fbsource//third-party/pypi/typing-extensions:typing-extensions",
"//caffe2:torch",
],
)

fbcode_target(_kind = runtime.python_library,
name = "version",
srcs = [
"version.py",
],
visibility = [
"//executorch/devtools/...",
],
)
44 changes: 0 additions & 44 deletions devtools/bundled_program/TARGETS

This file was deleted.

31 changes: 29 additions & 2 deletions devtools/bundled_program/schema/BUCK
Original file line number Diff line number Diff line change
@@ -1,8 +1,35 @@
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
oncall("executorch")
# Any targets that should be shared between fbcode and xplat must be defined in
# targets.bzl. This file can contain xplat-only targets.

load(":targets.bzl", "define_common_targets")

oncall("executorch")

define_common_targets()
non_fbcode_target(_kind = define_common_targets,)

# !!!! fbcode/executorch/devtools/bundled_program/schema/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!!

# Any targets that should be shared between fbcode and xplat must be defined in
# targets.bzl. This file can contain fbcode-only targets.

load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load(":targets.bzl", "define_common_targets")


fbcode_target(_kind = define_common_targets,)

fbcode_target(_kind = runtime.python_library,
name = "bundled_program_schema_py",
srcs = [
"__init__.py",
"bundled_program_schema.py",
],
visibility = [
"//executorch/devtools/bundled_program/...",
"//executorch/devtools/etrecord/...",
],
deps = [
"//executorch/exir:scalar_type",
],
)
24 changes: 0 additions & 24 deletions devtools/bundled_program/schema/TARGETS

This file was deleted.

15 changes: 14 additions & 1 deletion devtools/bundled_program/schema/test/BUCK
Original file line number Diff line number Diff line change
@@ -1,4 +1,17 @@
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
oncall("executorch")
# add this empty BUCK file to unblock landing. Without this, we get land error:
# "No build file at xplat/executorch/devtools/bundled_program/test/BUCK when resolving target fbsource//xplat/executorch/devtools/bundled_program/test/BUCK:."

oncall("executorch")

# !!!! fbcode/executorch/devtools/bundled_program/schema/test/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!!

load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest")


fbcode_target(_kind = python_unittest,
name = "schema",
srcs = [
"test_schema.py",
],
)
10 changes: 0 additions & 10 deletions devtools/bundled_program/schema/test/TARGETS

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")

oncall("executorch")

# Use runtime.python_library instead of the one defined in python_library.bzl,
# so we can have access to EXECUTORCH_CLIENTS list.
runtime.python_library(
fbcode_target(_kind = runtime.python_library,
name = "lib",
srcs = [
"__init__.py",
Expand Down
20 changes: 19 additions & 1 deletion devtools/bundled_program/serialize/test/BUCK
Original file line number Diff line number Diff line change
@@ -1,4 +1,22 @@
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
oncall("executorch")
# add this empty BUCK file to unblock landing. Without this, we get land error:
# "No build file at xplat/executorch/devtools/bundled_program/serialize/test/BUCK when resolving target fbsource//xplat/executorch/devtools/bundled_program/serialize/test/BUCK:."

oncall("executorch")

# !!!! fbcode/executorch/devtools/bundled_program/serialize/test/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!!

load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest")


fbcode_target(_kind = python_unittest,
name = "serialize",
srcs = [
"test_serialize.py",
],
deps = [
"//executorch/devtools/bundled_program:core",
"//executorch/devtools/bundled_program/serialize:lib",
"//executorch/devtools/bundled_program/util:test_util",
],
)
15 changes: 0 additions & 15 deletions devtools/bundled_program/serialize/test/TARGETS

This file was deleted.

68 changes: 67 additions & 1 deletion devtools/bundled_program/test/BUCK
Original file line number Diff line number Diff line change
@@ -1,4 +1,70 @@
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
oncall("executorch")
# add this empty BUCK file to unblock landing. Without this, we get land error:
# "No build file at xplat/executorch/exir/tests/BUCK when resolving target fbsource//xplat/executorch/exir/tests:."

oncall("executorch")

# !!!! fbcode/executorch/devtools/bundled_program/test/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!!

# @noautodeps

load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest")


fbcode_target(_kind = python_unittest,
name = "bundle_data",
srcs = [
"test_bundle_data.py",
],
deps = [
"//caffe2:torch",
"//executorch/devtools/bundled_program:config",
"//executorch/devtools/bundled_program:core",
"//executorch/devtools/bundled_program/schema:bundled_program_schema_py",
"//executorch/devtools/bundled_program/util:test_util",
"//executorch/exir/_serialize:lib",
],
)

fbcode_target(_kind = python_unittest,
name = "config",
srcs = [
"test_config.py",
],
deps = [
"//caffe2:torch",
"//executorch/devtools/bundled_program:config",
"//executorch/devtools/bundled_program/util:test_util",
"//executorch/extension/pytree:pylib",
],
)

fbcode_target(_kind = python_unittest,
name = "end2end",
srcs = [
"test_end2end.py",
],
deps = [
"//caffe2:torch",
"//executorch/devtools/bundled_program:config",
"//executorch/devtools/bundled_program:core",
"//executorch/devtools/bundled_program/serialize:lib",
"//executorch/devtools/bundled_program/util:test_util",
"//executorch/exir:dynamic_shape",
"//executorch/exir:lib",
"//executorch/exir:memory",
"//executorch/exir:pass_manager",
"//executorch/exir:print_program",
"//executorch/exir:tensor",
"//executorch/exir/_serialize:lib",
"//executorch/exir/emit:lib",
"//executorch/exir/passes:lib",
"//executorch/exir/tests:control_flow_models",
"//executorch/exir/tests:dynamic_shape_models",
"//executorch/exir/tests:models",
"//executorch/exir/tests:transformer",
"//executorch/extension/pybindings:portable_lib",
"//executorch/extension/pytree:pybindings",
"//executorch/kernels/portable:custom_ops_generated_lib",
],
)
63 changes: 0 additions & 63 deletions devtools/bundled_program/test/TARGETS

This file was deleted.

Loading
Loading