From 594fc773e74bbb08552a320ba418e5db0336ab18 Mon Sep 17 00:00:00 2001 From: FbsourceTargetsToBuck Bot Date: Fri, 8 May 2026 16:19:16 -0700 Subject: [PATCH] Rename build files from TARGETS to BUCK (group ID: 1746601514138727150) Reviewed By: bigfootjon Differential Revision: D104414856 --- backends/vulkan/tools/gpuinfo/BUCK | 59 ++++++++++++++++++- backends/vulkan/tools/gpuinfo/TARGETS | 50 ---------------- .../partition/config/{TARGETS => BUCK} | 3 +- backends/xnnpack/quantizer/{TARGETS => BUCK} | 5 +- backends/xnnpack/recipes/{TARGETS => BUCK} | 7 ++- 5 files changed, 65 insertions(+), 59 deletions(-) delete mode 100644 backends/vulkan/tools/gpuinfo/TARGETS rename backends/xnnpack/partition/config/{TARGETS => BUCK} (75%) rename backends/xnnpack/quantizer/{TARGETS => BUCK} (74%) rename backends/xnnpack/recipes/{TARGETS => BUCK} (80%) diff --git a/backends/vulkan/tools/gpuinfo/BUCK b/backends/vulkan/tools/gpuinfo/BUCK index 7477875096e..7830ee4e1f5 100644 --- a/backends/vulkan/tools/gpuinfo/BUCK +++ b/backends/vulkan/tools/gpuinfo/BUCK @@ -1,3 +1,4 @@ +load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target") load("@fbcode_macros//build_defs:native_rules.bzl", "buck_filegroup") load("@fbsource//tools/build_defs:fb_xplat_cxx_binary.bzl", "fb_xplat_cxx_binary") load( @@ -11,7 +12,7 @@ load( oncall("executorch") -buck_filegroup( +non_fbcode_target(_kind = buck_filegroup, name = "gpuinfo_shaders", srcs = glob([ "glsl/*", @@ -21,14 +22,14 @@ buck_filegroup( ], ) -vulkan_spv_shader_lib( +non_fbcode_target(_kind = vulkan_spv_shader_lib, name = "gpuinfo_shader_lib", spv_filegroups = { ":gpuinfo_shaders": "glsl", }, ) -fb_xplat_cxx_binary( +non_fbcode_target(_kind = fb_xplat_cxx_binary, name = "vulkan_gpuinfo", srcs = glob([ "**/*.cpp", @@ -56,3 +57,55 @@ fb_xplat_cxx_binary( "//xplat/folly:json", ], ) + +# !!!! fbcode/executorch/backends/vulkan/tools/gpuinfo/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!! + +load("@fbcode_macros//build_defs:native_rules.bzl", "buck_filegroup") +load("@fbsource//tools/build_defs:fb_xplat_cxx_binary.bzl", "fb_xplat_cxx_binary") +load( + "@fbsource//tools/build_defs:platform_defs.bzl", + "ANDROID", +) +load( + "@fbsource//xplat/executorch/backends/vulkan:targets.bzl", + "vulkan_spv_shader_lib", +) + + +fbcode_target(_kind = buck_filegroup, + name = "gpuinfo_shaders", + srcs = glob([ + "glsl/*", + ]), + visibility = [ + "PUBLIC", + ], +) + +fbcode_target(_kind = vulkan_spv_shader_lib, + name = "gpuinfo_shader_lib", + is_fbcode = True, + spv_filegroups = { + ":gpuinfo_shaders": "glsl", + }, +) + +fbcode_target(_kind = fb_xplat_cxx_binary, + name = "vulkan_gpuinfo", + srcs = glob([ + "**/*.cpp", + ]), + headers = glob([ + "**/*.h", + ]), + header_namespace = "/include", + include_directories = ["/include"], + platforms = ANDROID, + raw_headers = glob([ + "**/*.h", + ]), + deps = [ + ":gpuinfo_shader_lib", + "//executorch/backends/vulkan:vulkan_graph_runtime", + ], +) diff --git a/backends/vulkan/tools/gpuinfo/TARGETS b/backends/vulkan/tools/gpuinfo/TARGETS deleted file mode 100644 index 10e3acb4b8c..00000000000 --- a/backends/vulkan/tools/gpuinfo/TARGETS +++ /dev/null @@ -1,50 +0,0 @@ -load("@fbcode_macros//build_defs:native_rules.bzl", "buck_filegroup") -load("@fbsource//tools/build_defs:fb_xplat_cxx_binary.bzl", "fb_xplat_cxx_binary") -load( - "@fbsource//tools/build_defs:platform_defs.bzl", - "ANDROID", -) -load( - "@fbsource//xplat/executorch/backends/vulkan:targets.bzl", - "vulkan_spv_shader_lib", -) - -oncall("executorch") - -buck_filegroup( - name = "gpuinfo_shaders", - srcs = glob([ - "glsl/*", - ]), - visibility = [ - "PUBLIC", - ], -) - -vulkan_spv_shader_lib( - name = "gpuinfo_shader_lib", - is_fbcode = True, - spv_filegroups = { - ":gpuinfo_shaders": "glsl", - }, -) - -fb_xplat_cxx_binary( - name = "vulkan_gpuinfo", - srcs = glob([ - "**/*.cpp", - ]), - headers = glob([ - "**/*.h", - ]), - header_namespace = "/include", - include_directories = ["/include"], - platforms = ANDROID, - raw_headers = glob([ - "**/*.h", - ]), - deps = [ - ":gpuinfo_shader_lib", - "//executorch/backends/vulkan:vulkan_graph_runtime", - ], -) diff --git a/backends/xnnpack/partition/config/TARGETS b/backends/xnnpack/partition/config/BUCK similarity index 75% rename from backends/xnnpack/partition/config/TARGETS rename to backends/xnnpack/partition/config/BUCK index af6472634b5..ad7aea48b99 100644 --- a/backends/xnnpack/partition/config/TARGETS +++ b/backends/xnnpack/partition/config/BUCK @@ -1,8 +1,9 @@ +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") -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "xnnpack_partitioner_configs", srcs = glob([ "*.py", diff --git a/backends/xnnpack/quantizer/TARGETS b/backends/xnnpack/quantizer/BUCK similarity index 74% rename from backends/xnnpack/quantizer/TARGETS rename to backends/xnnpack/quantizer/BUCK index 0a30773923d..94b3614d0bc 100644 --- a/backends/xnnpack/quantizer/TARGETS +++ b/backends/xnnpack/quantizer/BUCK @@ -1,6 +1,7 @@ +load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target") load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime") -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "xnnpack_quantizer", srcs = ["xnnpack_quantizer.py"], deps = [ @@ -11,7 +12,7 @@ runtime.python_library( ], ) -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "xnnpack_quantizer_utils", srcs = ["xnnpack_quantizer_utils.py"], deps = [ diff --git a/backends/xnnpack/recipes/TARGETS b/backends/xnnpack/recipes/BUCK similarity index 80% rename from backends/xnnpack/recipes/TARGETS rename to backends/xnnpack/recipes/BUCK index 03bdd7230c4..afae0a1982e 100644 --- a/backends/xnnpack/recipes/TARGETS +++ b/backends/xnnpack/recipes/BUCK @@ -1,8 +1,9 @@ +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") -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "xnnpack_recipes", srcs = [ "__init__.py", @@ -15,7 +16,7 @@ runtime.python_library( ], ) -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "xnnpack_recipe_provider", srcs = [ "xnnpack_recipe_provider.py", @@ -31,7 +32,7 @@ runtime.python_library( ], ) -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "xnnpack_recipe_types", srcs = [ "xnnpack_recipe_types.py",