Skip to content

'@com_github_skyapm_cpp2sky//source': BUILD file not found in directory 'source' of external repository  #86

@metaphorcode

Description

@metaphorcode

ERROR Info

`
bazel build //main:app

INFO: SHA256 (https://hub.fastgit.org/SkyAPM/cpp2sky/archive/refs/tags/v0.3.0.zip) = 464230fc02d2b98a0885dbe1a8c0a08d8428e8ca2657428a58e962470ad6e383
DEBUG: Rule 'com_github_skyapm_cpp2sky' indicated that a canonical reproducible form can be obtained by modifying arguments sha256 = "464230fc02d2b98a0885dbe1a8c0a08d8428e8ca2657428a58e962470ad6e383"
DEBUG: Repository com_github_skyapm_cpp2sky instantiated at:
/home/administrator/Documents/code/cpp_bazel/WORKSPACE:3:13: in
Repository rule http_archive defined at:
/home/administrator/.cache/bazel/_bazel_administrator/4b06ca283974840dd7b69227a74469d1/external/bazel_tools/tools/build_defs/repo/http.bzl:336:31: in
ERROR: /home/administrator/Documents/code/cpp_bazel/main/BUILD:3:10: no such package '@com_github_skyapm_cpp2sky//source': BUILD file not found in directory 'source' of external repository @com_github_skyapm_cpp2sky. Add a BUILD file to a directory to mark it as a package. and referenced by '//main:app'
ERROR: Analysis of target '//main:app' failed; build aborted: Analysis failed
INFO: Elapsed time: 8.019s
INFO: 0 processes.
`

Project Directory

-- CPP_BAZEL
---- main
------ app.cc
------ BUILD
---- WORKSPACE

WORKSPACE
`
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

http_archive(
name = "com_github_skyapm_cpp2sky",
urls = ["https://hub.fastgit.org/SkyAPM/cpp2sky/archive/refs/tags/v0.3.0.zip"],
)
`

BUILD

`
load("@rules_cc//cc:defs.bzl", "cc_binary")

cc_binary(
name = "app",
srcs = ["app.cc"],
deps = [
"@com_github_skyapm_cpp2sky//cpp2sky:cpp2sky_interface",
"@com_github_skyapm_cpp2sky//source:cpp2sky_lib",
],
)
`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions