Skip to content

Error loading '@@rules_cc+//cc:extensions.bzl' for module extensions, requested by ... #593

@dsharlet

Description

@dsharlet

We started seeing this issue recently, after updating to bazel 9 and fixing associated warnings (e.g. likely relevant google/XNNPACK#9480 PR description was overly optimistic about fixing this issue... :) )

https://github.com/google/XNNPACK/actions/runs/21690358119/job/62566256419

Error loading '@@rules_cc+//cc:extensions.bzl' for module extensions, requested by https://bcr.bazel.build/modules/rules_cc/0.2.14/MODULE.bazel:33:23: at /github/home/.cache/bazel/_bazel_xnnpack/7af42c7278a28d4a50c31513d31d4932/external/rules_cc+/cc/extensions.bzl:17:6: Every .bzl file must have a corresponding package, but '@@bazel_features+//private:util.bzl' does not have one. Please create a BUILD file in the same or any parent directory. Note that this BUILD file does not need to do anything except exist.: at /github/home/.cache/bazel/_bazel_xnnpack/7af42c7278a28d4a50c31513d31d4932/external/rules_cc+/cc/extensions.bzl:17:6: Every .bzl file must have a corresponding package, but '@@bazel_features+//private:util.bzl' does not have one. Please create a BUILD file in the same or any parent directory. Note that this BUILD file does not need to do anything except exist.

This seems like a bug internal to rules_cc. We still see the same issue even after removing the bazel_dep on bazel_features that attempted to fix this.

Is there a workaround available for this problem? Or are we doing something wrong to trigger it?

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