summaryrefslogtreecommitdiff
path: root/transitions/EXPRESSIONS
diff options
context:
space:
mode:
authorOliver Reiche <oliver.reiche@huawei.com>2023-08-07 15:14:46 +0200
committerOliver Reiche <oliver.reiche@huawei.com>2023-08-16 15:30:32 +0200
commit2c5e3a6756fc871bbdde8a34d38cda297519b0f9 (patch)
tree18a8acb30e9249fdb02405ca54afce3a53c1e92e /transitions/EXPRESSIONS
parent49a1fc766de1b78427a50f37dbf5650237293067 (diff)
downloadrules-cc-2c5e3a6756fc871bbdde8a34d38cda297519b0f9.tar.gz
rules: Support BUILD_ARCH for CC defaults
Diffstat (limited to 'transitions/EXPRESSIONS')
-rw-r--r--transitions/EXPRESSIONS25
1 files changed, 17 insertions, 8 deletions
diff --git a/transitions/EXPRESSIONS b/transitions/EXPRESSIONS
index 4fd0d1e..596b20e 100644
--- a/transitions/EXPRESSIONS
+++ b/transitions/EXPRESSIONS
@@ -1,13 +1,22 @@
{ "for host":
- { "vars": ["ARCH", "HOST_ARCH"]
+ { "vars": ["ARCH", "HOST_ARCH", "TARGET_ARCH"]
, "expression":
- { "type": "singleton_map"
- , "key": "TARGET_ARCH"
- , "value":
- { "type": "var"
- , "name": "HOST_ARCH"
- , "default": {"type": "var", "name": "ARCH"}
- }
+ { "type": "let*"
+ , "bindings":
+ [ [ "BUILD_ARCH"
+ , { "type": "var"
+ , "name": "TARGET_ARCH"
+ , "default": {"type": "var", "name": "ARCH"}
+ }
+ ]
+ , [ "TARGET_ARCH"
+ , { "type": "var"
+ , "name": "HOST_ARCH"
+ , "default": {"type": "var", "name": "ARCH"}
+ }
+ ]
+ ]
+ , "body": {"type": "env", "vars": ["BUILD_ARCH", "TARGET_ARCH"]}
}
}
, "target properties":