aspect-build / aspect-workflows-template

Scaffolding for new Aspect workspace
1 stars 1 forks source link

[Bug]: Leaking a dependency on cc toolchain #32

Open alexeagle opened 3 months ago

alexeagle commented 3 months ago

What happened?

On a minimal linux machine, after aspect init and aspect test ... I see an error from cc_autoconf - but there's no C++ in the project so I shouldn't have a dependency on that.

Also the CI on this repo is green which means it's using a machine that has too much installed on it.

INFO: Repository bazel_tools~cc_configure_extension~local_config_cc instantiated at:
  <builtin>: in <toplevel>
Repository rule cc_autoconf defined at:
  /home/alex/.cache/bazel/_bazel_alex/ff49db37519b09b5527b26c86443d6b8/external/bazel_tools/tools/cpp/cc_configure.bzl:109:30: in <toplevel>
ERROR: An error occurred during the fetch of repository 'bazel_tools~cc_configure_extension~local_config_cc':
   Traceback (most recent call last):
        File "/home/alex/.cache/bazel/_bazel_alex/ff49db37519b09b5527b26c86443d6b8/external/bazel_tools/tools/cpp/cc_configure.bzl", line 91, column 33, in cc_autoconf_impl
                configure_unix_toolchain(repository_ctx, cpu_value, overriden_tools)
        File "/home/alex/.cache/bazel/_bazel_alex/ff49db37519b09b5527b26c86443d6b8/external/bazel_tools/tools/cpp/unix_cc_configure.bzl", line 349, column 17, in configure_unix_toolchain
                cc = find_cc(repository_ctx, overriden_tools)
        File "/home/alex/.cache/bazel/_bazel_alex/ff49db37519b09b5527b26c86443d6b8/external/bazel_tools/tools/cpp/unix_cc_configure.bzl", line 314, column 23, in find_cc
                cc = _find_generic(repository_ctx, "gcc", "CC", overriden_tools)
        File "/home/alex/.cache/bazel/_bazel_alex/ff49db37519b09b5527b26c86443d6b8/external/bazel_tools/tools/cpp/unix_cc_configure.bzl", line 310, column 32, in _find_generic
                auto_configure_fail(msg)
        File "/home/alex/.cache/bazel/_bazel_alex/ff49db37519b09b5527b26c86443d6b8/external/bazel_tools/tools/cpp/lib_cc_configure.bzl", line 112, column 9, in auto_configure_fail
                fail("\n%sAuto-Configuration Error:%s %s\n" % (red, no_color, msg))
Error in fail: 
Auto-Configuration Error: Cannot find gcc or CC; either correct your path or set the CC environment variable

Version

HEAD

How to reproduce

No response

Any other information?

No response