Skip to content

Fixed issues with --features=external_include_paths#243

Open
furtib wants to merge 5 commits into
Ericsson:mainfrom
furtib:fix-external-include-paths
Open

Fixed issues with --features=external_include_paths#243
furtib wants to merge 5 commits into
Ericsson:mainfrom
furtib:fix-external-include-paths

Conversation

@furtib

@furtib furtib commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Why:
We want to support running analysis with --features=external_include_paths.

What:

  • Added flags from external_includes to compile commands.
  • Added flags from iquotes and external_includes to compile commands of dependencies.

Addresses:
Fixes: #236

@furtib furtib requested a review from Szelethus June 16, 2026 08:06
@furtib furtib self-assigned this Jun 16, 2026
@furtib furtib added bug Something isn't working enhancement New feature or request labels Jun 16, 2026

@Szelethus Szelethus left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bazel 6.5.0 CI jobs break:

Error: 'CompilationContext' value has no field or method 'external_includes'

If this is a bazel 6 specific issue, then I suggest this might be a sign that it is time to officially stop supporting it.

Comment thread src/compile_commands.bzl
Comment on lines +144 to +147
for quote_include in compilation_context.quote_includes.to_list():
if len(quote_include) == 0:
quote_include = "."
options.append(QUOTE_INCLUDE + quote_include)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't have a test.

Comment thread README.md Outdated

Limitations:
------------
In Bazel 6, we do not support using the `--features=external_include_paths` flag.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it makes sense not to explicitly drop Bazel 6, and keep it in a limited, but working state.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I disagree. I don't want to half-support a bazel major version we already agreed on dropping.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, let's drop Bazel 6 then.

@furtib furtib force-pushed the fix-external-include-paths branch from 14fc533 to 5e1a45e Compare June 16, 2026 08:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support --features=external_include_paths

2 participants