Repo containing for reproducing the error found in this this comment
In WORKSPACE, change /path/to/rules_pkg/
to wherever your checkout of rules_pkg is located:
local_repository(
name = "rules_pkg",
# Change me to wherever your rules_pkg checkout is
path = "/path/to/rules_pkg/pkg"
)
Then call bazel build ...
. Output error should look something like:
ERROR: error loading package '': in /home/apsaltis/.cache/bazel/_bazel_apsaltis/ca21bffe165d1853abbcdb2b62d6d44e/external/rules_pkg/experimental/rpm.bzl: Label '//experimental:pkg_filegroup.bzl' is invalid because 'experimental' is not a package; perhaps you meant to put the colon here: '//:experimental/pkg_filegroup.bzl'?