Skip to content

Example does not work for macos #20

Description

@tasmanvs

Hi, I tried getting this running on macos. Either I missed some setup for this or it is broken for macos.

Error:

% bazel build example
ERROR: /private/var/tmp/_bazel_tasman/4f0f97736624674ca371850865d18500/external/bazelregistry_sdl2/BUILD.bazel:68:1: name 'apple_binary' is not defined (did you mean 'py_binary'?)
ERROR: /Users/tasman/Coding/audio_interference/cpp/BUILD:10:11: no such target '@bazelregistry_sdl2//:SDL2_lib': target 'SDL2_lib' not declared in package '' defined by /private/var/tmp/_bazel_tasman/4f0f97736624674ca371850865d18500/external/bazelregistry_sdl2/BUILD.bazel (Tip: use `query "@bazelregistry_sdl2//:*"` to see all the targets in that package) and referenced by '//:example'
ERROR: Analysis of target '//:example' failed; build aborted: Analysis failed
INFO: Elapsed time: 0.037s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (1 packages loaded, 0 targets configured)

BUILD:

cc_library(
    name = "example",
    srcs = ["main.cc"],
    deps = ["@bazelregistry_sdl2//:SDL2_lib"],
)

WORKSPACE:

http_archive(
    name = "bazelregistry_sdl2",
    strip_prefix = "sdl2-c3efa24f546f0d8be97aaf1609688905e585cd69",
    urls = ["https://github.com/bazelregistry/sdl2/archive/c3efa24f546f0d8be97aaf1609688905e585cd69.zip"],
    sha256 = "735b86e808d78c3a6e7db86c4532140be4ad5d7349feea2dbfef7ea1382c31eb",
)
bazel --version
bazel 6.4.0-homebrew

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions