Skip to content

strip_include_prefix doesn't apply to textual_hdrs #12424

@chandlerc

Description

@chandlerc

Description of the problem / feature request:

strip_include_prefix in cc_* rules is super useful, but it needs to apply to textual_hdrs as well as hdrs. The inconsistency is extremely problematic for rules successfully using either textual_hdrs or strip_include_prefix.

Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

Given this rule:

cc_library(
    name = "test",
    hdrs = ["some/path/prefix/normal_header.h"
    textual_hdrs = ["some/path/prefix/textual_header.h"],
    strip_include_prefix = "some/path/prefix",
)

Rules depending on :test can #include "normal_header.h" as expected, but cannot #include "textual_header.h".

What operating system are you running Bazel on?

Impacts all OSes AFAICT, tested on Linux.

What's the output of bazel info release?

release 3.3.1

Activity

added
P4This is either out of scope or we don't have bandwidth to review a PR. (No assignee)
and removed on Nov 19, 2020
github-actions

github-actions commented on Apr 13, 2023

@github-actions

Thank you for contributing to the Bazel repository! This issue has been marked as stale since it has not had any activity in the last 2+ years. It will be closed in the next 14 days unless any other activity occurs or one of the following labels is added: "not stale", "awaiting-bazeler". Please reach out to the triage team (@bazelbuild/triage) if you think this issue is still relevant or you are interested in getting the issue resolved.

added
staleIssues or PRs that are stale (no activity for 30 days)
on Apr 13, 2023
chandlerc

chandlerc commented on Apr 13, 2023

@chandlerc
Author

@bazelbuild/triage - This is definitely still relevant and I'd like to see it resolved.

Pretty sure it was triaged and a team added back in 2020, but then marked as untriaged... 🤷

removed
staleIssues or PRs that are stale (no activity for 30 days)
on Apr 13, 2023
github-actions

github-actions commented on Jun 17, 2024

@github-actions

Thank you for contributing to the Bazel repository! This issue has been marked as stale since it has not had any activity in the last 1+ years. It will be closed in the next 90 days unless any other activity occurs. If you think this issue is still relevant and should stay open, please post any comment here and the issue will no longer be marked as stale.

added
staleIssues or PRs that are stale (no activity for 30 days)
on Jun 17, 2024

28 remaining items

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P4This is either out of scope or we don't have bandwidth to review a PR. (No assignee)team-Rules-CPPIssues for C++ rulestype: bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Participants

    @keith@philwo@chandlerc@hlopko@lberki

    Issue actions

      `strip_include_prefix` doesn't apply to `textual_hdrs` · Issue #12424 · bazelbuild/bazel