I want bazel to fetch an external dependency from a URL. The file is an rpm file. I added this in the WORKSPACE file in root dir:
http_archive(
name = "mylib",
url = "someURL/somefile.rpm",
build_file = "example.BUILD"
)
When I try:
bazel fetch @mylib//...
It says:
"com.google.devtools.build.lib.syntax.EvalException: Expected a file with a .zip, .jar, .war, .tar, .tar.gz, .tgz, .tar.xz, .txz, or .tar.bz2 suffix"
Basically it is not allowing to download rpm deps. How can I achieve this ? How to download external dependency of type rpm.
You're trying to fetch an
.rpmfile, but it seems that bazel only accepts archive files with the suffixes.zip, .jar, .war, .tar, .tar.gz, .tgz, .tar.xz, .txz, or .tar.bz2.