Commit Graph

12 Commits

Author SHA1 Message Date
Otavio Salvador
bfa2a3b98d Ensure we fail if old SoC overrides are in use
To assist existing layers to convert to the new BSP-specific
overrides. Besides failing the parsing of the recipes where it is in
use, we provide a script to automate most of it.

Fixes: #990.
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2022-03-03 10:41:35 -03:00
Otavio Salvador
a3b102a9ed classes/machine-overrides-extender: Postpone filter out
The overrides ought to allow the filter out execution even for overrides
included during the extension, for this to work we need to postpone it.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2022-02-21 19:22:02 -03:00
Otavio Salvador
deea917d0a classes/machine-overrides-extender: Allow filter out without an override
We should be able to use a single MACHINEOVERRIDES_EXTENDER_FILTER_OUT
definition, without an override, to reduce code duplication.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2022-02-21 19:22:02 -03:00
Tom Hochstein
a31e8a6a7e machine-overrides-extender.bbclass: Adjust for new override character
Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-08-12 10:08:24 -07:00
André Draszik
74df05a7f0 remove True option to getVar calls
getVar() has been defaulting to expanding by default for
a long time (2016), thus remove the True option from
getVar() calls with a regex search and replace.

Search & replace made using the following command:
    sed -e 's|\(d\.getVar \?\)( \?\([^,()]*\), \?True)|\1(\2)|g' \
        -i $(git grep -E 'getVar ?\( ?([^,()]*), ?True\)' \
             | cut -d':' -f1 \
             | sort -u)

Signed-off-by: André Draszik <andre.draszik@jci.com>
2019-01-17 14:29:17 +00:00
Otavio Salvador
e9820a5de4 machine-overrides-extender.bbclass: Avoid an empty override
All uses of MACHINEOVERRIDES already include an ':' suffix so we
cannot add it again or we end with a match-all override.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-03 18:40:57 -03:00
Otavio Salvador
d227cc1331 machine-overrides-extender.bbclass: Postpone overrides processing
We need to keep a reference to the original MACHINEOVERRIDES value so
it can be reprocessed as need. This allow the compatibility with
existing BSP's while fixing the complex multilib interactions.

I'd like to record that Richard Purdie was key to solve this issue.
Its implications were beyond my understanding until he guided me and
provided a prototype fix.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-03 09:17:52 -03:00
Otavio Salvador
a59a205985 machine-overrides-extender.bbclass: Fix multilib parsing
The 'ConfigParsed' event was too early and when we mangled the
MACHINEOVERRIDES using the extender, we ended overriding some values
when using together with multilib.

This fixes the multilib use-case and keep current ones working.

Reported-by: Cristinel Panfir <cristinel.panfir@nxp.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-06-01 09:49:26 -03:00
Otavio Salvador
eeaa4b69ca Revert "machine-overrides-extender.bbclass: Postpone until 'RecipeParsed' event"
This reverts commit 65144beb63.

The commit has side effects and must be better investigated. For now,
we are reverting it so we don't cause problems for other use cases.

Change-Id: I63333c974746bd7f95fa7a56153099256e206912
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-05-22 17:36:33 -03:00
Otavio Salvador
65144beb63 machine-overrides-extender.bbclass: Postpone until 'RecipeParsed' event
The 'ConfigParsed' event was too early and when we mangled the
MACHINEOVERRIDES using the extender, we ended overriding some values
when using together with multilib.

This fixes the multilib use-case and keep current ones working.

Change-Id: I6f1d952dfe2d04fa10229a86763af4ca6b1e601f
Reported-by: Cristinel Panfir <cristinel.panfir@nxp.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-05-22 09:41:24 -03:00
Otavio Salvador
7dc760ad8b machine-overrides-extender.bbclass: Add filter out support
The allow easier enablement of mainline BSP support, we need to allow
for specific overrides to be filtered out, before and during the
extending process.

The new MACHINEOVERRIDES_EXTENDER_FILTER_OUT variable does exactly
this and will be used in a subsequent commit to enable the
'use-mainline-bsp' override.

Change-Id: Ieaec9d5eb27ccc73b7b0097cb365c519978bd080
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2017-03-27 11:52:44 -03:00
Otavio Salvador
9d378923a9 machine-overrides-extender.bbclass: Automatically set extend the MACHINEOVERRIDES
This allow to grouping of different settings for similar platforms.

To use the class, specify, for example:

 MACHINEOVERRIDES_EXTENDER_soc = "group1:group2"

Change-Id: I4a7dcd353b8bedf9d8f213827d7de768783c3d5d
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2016-09-08 11:24:24 -03:00