Skip to content

Restore host and nonhost toolchain features (reversing #7407) #13315

@chandlerc

Description

@chandlerc

Description of the problem / feature request:

Currently it is necessary to pass --incompatible_dont_enable_host_nonhost_crosstool_features=false to get host and nonhost features back in the C++ toolchain.

In #7407 these were suggested to be removed because there may not be a separate host and target platform or toolchain. That is true, but features in C++ toolchains control much more than just which platform is used or which toolchain is used. There are features that make sense to enable in the host build but not in the target build even when the platforms are identical.

Some easy examples are the LLVM sanitizers. These are debugging aids but can come with high runtime overhead. It is often undesirable to subject host tools to these overheads, and instead they should only be enabled for target builds.

Another example is disabling debug information in host builds: #13308

Not sure anything else is needed here, but if there are questions about how this might be used, please let me know.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3We're not considering working on this, but happy to review a PR. (No assignee)staleIssues or PRs that are stale (no activity for 30 days)team-Rules-CPPIssues for C++ rulestype: feature request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions