Organize BUCK for torch/standalone (#156503)

Summary: Undo highlevel BUCKification in favor of something more organized by moving it to the dir itself

Test Plan:
CI

Rollback Plan:

Reviewed By: swolchok

Differential Revision: D76920013

Pull Request resolved: https://github.com/pytorch/pytorch/pull/156503
Approved by: https://github.com/swolchok
This commit is contained in:
Jane Xu
2025-06-25 22:56:15 +00:00
committed by PyTorch MergeBot
parent d98fa4a103
commit acaf6ba3c6
6 changed files with 13 additions and 13 deletions

View File

@ -671,14 +671,6 @@ flatbuffer_cc_library(
out_prefix = "torch/csrc/jit/serialization/",
)
cc_library(
name = "torch_standalone_headers",
hdrs = glob([
"torch/standalone/**/*.h"
]),
visibility = ["//visibility:public"],
)
cc_library(
name = "torch_headers",
hdrs = if_cuda(

View File

@ -80,7 +80,6 @@ def define_targets(rules):
deps = [
":ScalarType",
"//third_party/cpuinfo",
"//:torch_standalone_headers",
"//c10/macros",
"//c10/util:TypeCast",
"//c10/util:base",

View File

@ -13,7 +13,7 @@ def define_targets(rules):
local_defines = ["C10_BUILD_MAIN_LIB"],
visibility = ["//visibility:public"],
deps = [
"//:torch_standalone_headers",
"//torch/standalone:torch_standalone_headers",
],
)

View File

@ -74,7 +74,7 @@ def define_c10_ovrsource(name, is_mobile):
],
}),
exported_deps = [
"//xplat/caffe2:torch_standalone_headers",
"//xplat/caffe2/torch/standalone:torch_standalone_headers",
":ovrsource_c10_cmake_macros.h",
"//arvr/third-party/gflags:gflags",
"//third-party/cpuinfo:cpuinfo",

View File

@ -34,7 +34,7 @@ def define_targets(rules):
visibility = ["//visibility:public"],
deps = [
":bit_cast",
"//:torch_standalone_headers",
"//torch/standalone:torch_standalone_headers",
"//c10/macros",
"@fmt",
"@moodycamel//:moodycamel",
@ -92,7 +92,7 @@ def define_targets(rules):
],
),
deps = [
"//:torch_standalone_headers",
"//torch/standalone:torch_standalone_headers",
],
visibility = ["//visibility:public"],
)

View File

@ -0,0 +1,9 @@
load("@rules_cc//cc:defs.bzl", "cc_library")
cc_library(
name = "torch_standalone_headers",
hdrs = glob([
"**/*.h"
]),
visibility = ["//visibility:public"],
)