Skip to content

Support for injecting custom toolchain features #591

@limdor

Description

@limdor

There are situations where it is helpful to implement a toolchain feature for all toolchains that your project supports.
In our case, this was used for implementing different warning levels/groups that is compiler agnostic.
That allows us to have something like:

cc_library(
    name = "foo",
    srcs = ["foo.cpp"],
    hdrs = ["foo.h"],
    features = [
        "safety_related_warnings",
    ],
)

cc_library(
    name = "bar",
    srcs = ["bar.cpp"],
    hdrs = ["bar.h"],
    features = [
        "security_related_warnings",
    ],
)

The main question for the maintainers would be, are you interested in that feature? Do you see this as something that we could add to toolchains_llvm? If yes just add a comment here and I would start working right away.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions