mirror of https://github.com/ARMmbed/mbed-os.git
parent
99ed4e03f1
commit
0d9d4639cd
|
@ -249,20 +249,20 @@ class Config:
|
|||
# If the label is defined by the target or it has the special value "*", process the overrides
|
||||
if (label == '*') or (label in self.target_labels):
|
||||
# Parse out features
|
||||
if 'features' in overrides:
|
||||
features = overrides['features']
|
||||
self.remove_features(list(set(self.added_features) - set(features)))
|
||||
if 'target.features' in overrides:
|
||||
features = overrides['target.features']
|
||||
self.remove_features(self.added_features - set(features))
|
||||
self.add_features(features)
|
||||
self.removed_unecessary_features = True
|
||||
del overrides['features']
|
||||
del overrides['target.features']
|
||||
|
||||
if 'features_add' in overrides:
|
||||
self.add_features(overrides['features_add'])
|
||||
del overrides['features_add']
|
||||
if 'target.features_add' in overrides:
|
||||
self.add_features(overrides['target.features_add'])
|
||||
del overrides['target.features_add']
|
||||
|
||||
if 'features_remove' in overrides:
|
||||
self.remove_features(overrides['features_remove'])
|
||||
del overrides['features_remove']
|
||||
if 'target.features_remove' in overrides:
|
||||
self.remove_features(overrides['target.features_remove'])
|
||||
del overrides['target.features_remove']
|
||||
|
||||
# Consider the others as overrides
|
||||
for name, v in overrides.items():
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features": ["IPV4", "IPV6"]
|
||||
"target.features": ["IPV4", "IPV6"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib1",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV4"]
|
||||
"target.features_add": ["IPV4"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV6"]
|
||||
"target.features_add": ["IPV6"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib1",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV4"]
|
||||
"target.features_add": ["IPV4"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib2",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_remove": ["IPV4"]
|
||||
"target.features_remove": ["IPV4"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV6"]
|
||||
"target.features_add": ["IPV6"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib1",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV6"]
|
||||
"target.features_add": ["IPV6"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib2",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["UVISOR"]
|
||||
"target.features_add": ["UVISOR"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV4"]
|
||||
"target.features_add": ["IPV4"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib1",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV6"]
|
||||
"target.features_add": ["IPV6"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib2",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["UVISOR"]
|
||||
"target.features_add": ["UVISOR"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features": ["IPV4", "IPV6"]
|
||||
"target.features": ["IPV4", "IPV6"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "lib1",
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV6"]
|
||||
"target.features_add": ["IPV6"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"target_overrides": {
|
||||
"*": {
|
||||
"features_add": ["IPV4"],
|
||||
"target.features_add": ["IPV4"],
|
||||
"lib2.test": "GOOD"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue