blob: dc42d38c936bd1ecab659745078d2f7b9e5919e7 [file]
# Copyright 2026 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
load("@io_bazel_rules_go//go:def.bzl", "go_library")
load("@platforms//host:constraints.bzl", "HOST_CONSTRAINTS")
load("//build/bazel/rules/host:defs.bzl", "go_binary_host_tool")
load("//build/bazel/rules/host_tests:host_go_test.bzl", "host_go_test")
package(default_applicable_licenses = ["//:license"])
go_library(
name = "main",
srcs = [
"cmd/bucket.go",
"cmd/job.go",
"cmd/main.go",
"cmd/upload.go",
"cmd/worker.go",
],
importpath = "go.fuchsia.dev/fuchsia/tools/debug/debugsyms/cmd",
target_compatible_with = HOST_CONSTRAINTS,
deps = [
"//third_party/golibs:cloud.google.com/go/storage",
"//third_party/golibs:github.com/google/subcommands",
"//tools/debug/elflib",
"//tools/lib/color",
"//tools/lib/logger",
"//tools/lib/retry",
],
)
go_binary_host_tool(
name = "debugsyms",
embed = [":main"],
target_compatible_with = HOST_CONSTRAINTS,
)
host_go_test(
name = "debugsyms_tests",
srcs = [
"cmd/bucket_test.go",
"cmd/job_test.go",
"cmd/upload_test.go",
"cmd/worker_test.go",
],
embed = [":main"],
target_compatible_with = HOST_CONSTRAINTS,
visibility = ["//tools:__pkg__"],
deps = [
"//tools/debug/elflib",
"//tools/lib/retry",
],
)