eclipse-iceoryx / eclipse-iceoryx/iceoryx

Fails to build with Bazel 8.0.0

Open
#2,400 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug tooling
Dominant language
C++
Stars
2.2k
Forks
492
Avg merge
18h 57m
Merged PRs (30d)
1

Description

Required information

Operating system

macOS Sequoia 15.2

Compiler version:
$ clang --version
Homebrew clang version 19.1.1
Target: arm64-apple-darwin24.2.0
Thread model: posix
InstalledDir: /opt/homebrew/Cellar/llvm/19.1.1/bin
Eclipse iceoryx version:

main

Observed result or behaviour

First, I get an error about both --enable_bzlmod and --enable_workspace being disabled:

$ bazel build //...
Starting local Bazel server and connecting to it...
WARNING: ignoring JAVA_TOOL_OPTIONS in environment.
ERROR: Error computing the main repository mapping: error loading package 'external': Both --enable_bzlmod and --enable_workspace are disabled, but one of them must be enabled to fetch external dependencies.

If I set --enable_bzlmod, I get the following errors:

$ bazel build --enable_bzlmod //...
WARNING: For repository 'rules_cc', the root module requires module version rules_cc@0.0.9, but got rules_cc@0.0.16 in the resolved dependency graph. Please update the version in your MODULE.bazel or set --check_direct_dependencies=off
WARNING: Couldn't auto load rules or symbols, because no dependency on module/repository 'rules_android' found. This will result in a failure if there's a reference to those rules or symbols.
ERROR: Traceback (most recent call last):
        File "/Users/dzc/Repos/github/eclipse-iceoryx/iceoryx/iceoryx_hoofs/test/stresstests/BUILD.bazel", line 49, column 16, in <toplevel>
                srcs = glob([
Error in glob: glob pattern '*.hpp' didn't match anything, but allow_empty is set to False (the default value of allow_empty can be set with --incompatible_disallow_empty_glob).
ERROR: Traceback (most recent call last):
        File "/Users/dzc/Repos/github/eclipse-iceoryx/iceoryx/iceoryx_platform/test/BUILD.bazel", line 21, column 16, in <toplevel>
                srcs = glob([
Error in glob: glob pattern 'moduletests/*.hpp' didn't match anything, but allow_empty is set to False (the default value of allow_empty can be set with --incompatible_disallow_empty_glob).
ERROR: Traceback (most recent call last):
        File "/Users/dzc/Repos/github/eclipse-iceoryx/iceoryx/iceoryx_hoofs/test/BUILD.bazel", line 48, column 16, in <toplevel>
                srcs = glob([
Error in glob: glob pattern 'integrationtests/*.hpp' didn't match anything, but allow_empty is set to False (the default value of allow_empty can be set with --incompatible_disallow_empty_glob).
ERROR: Traceback (most recent call last):
        File "/Users/dzc/Repos/github/eclipse-iceoryx/iceoryx/iceoryx_posh/BUILD.bazel", line 118, column 16, in <toplevel>
                srcs = glob(
Error in glob: glob pattern 'source/log/**' didn't match anything, but allow_empty is set to False (the default value of allow_empty can be set with --incompatible_disallow_empty_glob).
ERROR: package contains errors: iceoryx_platform/test
ERROR: Traceback (most recent call last):
        File "/Users/dzc/Repos/github/eclipse-iceoryx/iceoryx/iceoryx_hoofs/BUILD.bazel", line 34, column 16, in <toplevel>
                srcs = glob([
Error in glob: glob pattern 'design/source/*.cpp' didn't match anything, but allow_empty is set to False (the default value of allow_empty can be set with --incompatible_disallow_empty_glob).
ERROR: package contains errors: iceoryx_hoofs/test/stresstests
ERROR: Traceback (most recent call last):
        File "/Users/dzc/Repos/github/eclipse-iceoryx/iceoryx/iceoryx_posh/test/BUILD.bazel", line 28, column 16, in <toplevel>
                data = glob(["input/**"]),
Error in glob: glob pattern 'input/**' didn't match anything, but allow_empty is set to False (the default value of allow_empty can be set with --incompatible_disallow_empty_glob).
ERROR: package contains errors: iceoryx_hoofs/test
ERROR: package contains errors: iceoryx_posh/test
ERROR: package contains errors: iceoryx_hoofs
ERROR: package contains errors: iceoryx_posh
ERROR: Traceback (most recent call last):
        File "/Users/dzc/Repos/github/eclipse-iceoryx/iceoryx/iceoryx_binding_c/test/BUILD.bazel", line 53, column 16, in <toplevel>
                srcs = glob([
Error in glob: glob pattern 'integrationtests/*.hpp' didn't match anything, but allow_empty is set to False (the default value of allow_empty can be set with --incompatible_disallow_empty_glob).
ERROR: package contains errors: iceoryx_binding_c/test
WARNING: Target pattern parsing failed.
ERROR: Skipping '//...': Error evaluating '//...': error loading package 'iceoryx_binding_c/test': Package 'iceoryx_binding_c/test' contains errors
ERROR: Error evaluating '//...': error loading package 'iceoryx_binding_c/test': Package 'iceoryx_binding_c/test' contains errors
INFO: Elapsed time: 6.459s
INFO: 0 processes.
ERROR: Build did NOT complete successfully
Expected result or behaviour

Build succeeds

Conditions where it occurred / Performed steps:
  1. Update Bazel to 8.0.0 LTS
  2. bazel build //...

Additional helpful information

None

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running bazel build --enable_bzlmod //... and inspect the reported glob failures in iceoryx_hoofs/test/stresstests/BUILD.bazel, iceoryx_platform/test/BUILD.bazel, iceoryx_hoofs/test/BUILD.bazel, iceoryx_posh/BUILD.bazel, iceoryx_hoofs/BUILD.bazel, iceoryx_posh/test/BUILD.bazel, and iceoryx_binding_c/test/BUILD.bazel. Also review the Bazel module configuration mentioned by the dependency warnings; done means bazel build //... succeeds with Bazel 8.0.0.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.