Skip to content

target_overrides only allows to add extra features, not labels/macros/device_has #2209

Closed
@AlessandroA

Description

@AlessandroA

The target_overrides config option only allows to add/remove custom features (FEATURE_*). Other symbols can only be overridden (the symbol needs to be there in the first place).

This means that it is not possible for target_overrides to add/remove a new label (TARGET_*), a new custom macro or a new DEVICE_HAS_* macro.

How to reproduce

If in an application you override the K64F target, this is allowed:

{
    "target_overrides": {
        "K64F": {
            "target.features_add": ["UVISOR"]
        }
    }
}

but this is not (compile error):

{
    "target_overrides": {
        "K64F": {
            "target.features_add": ["UVISOR"],
            "target.extra_labels_add": ["UVISOR_SUPPORTED"]
        }
    }
}

Additional notes

This feature was originally available for custom targets (which BTW are not working any more, see #2196 and this related issue).

In the case of the uVisor hello-world example and other similar applications, though, it is not ideal to define custom targets. target_overrides are more natural.

This is a blocker for the release of the uVisor hello-world application.

@screamerbg @meriac @mjs-arm

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