summaryrefslogtreecommitdiff
path: root/CC/foreign/cmake/EXPRESSIONS
diff options
context:
space:
mode:
authorKlaus Aehlig <klaus.aehlig@huawei.com>2024-09-26 12:02:56 +0200
committerKlaus Aehlig <klaus.aehlig@huawei.com>2024-09-27 12:14:11 +0200
commit194d1f0197b2ec99d5dc4d9f623fdb2e7bac7327 (patch)
tree031612743c05635743089f4b76a6e006a5c94c38 /CC/foreign/cmake/EXPRESSIONS
parent38927e66d384c5fc639dba6d586d50a1ba746163 (diff)
downloadrules-cc-194d1f0197b2ec99d5dc4d9f623fdb2e7bac7327.tar.gz
Do not expand variables in PATH
... as otherwise we will use the same string in two ways: literal and as a value to the expanded, making proper quoting impossible. Moreover, it is not necessary to expand TOOLCHAIN: pointers into the toolchain can be passed through the "bin dirs" part of the toolchain.
Diffstat (limited to 'CC/foreign/cmake/EXPRESSIONS')
-rw-r--r--CC/foreign/cmake/EXPRESSIONS13
1 files changed, 2 insertions, 11 deletions
diff --git a/CC/foreign/cmake/EXPRESSIONS b/CC/foreign/cmake/EXPRESSIONS
index bf2385e..c8f6dc1 100644
--- a/CC/foreign/cmake/EXPRESSIONS
+++ b/CC/foreign/cmake/EXPRESSIONS
@@ -357,20 +357,11 @@
}
, { "type": "join"
, "$1":
- [ "export PATH=\"$(./expand_exec TOOLCHAIN -- echo "
+ [ "export PATH="
, { "type": "join_cmd"
, "$1": [{"type": "var", "name": "PATH"}]
}
- , ")${PATH:+:}${PATH}\""
- ]
- }
- , { "type": "join"
- , "$1":
- [ "export PATH=\"$(./expand_exec TOOLCHAIN -- echo "
- , { "type": "join_cmd"
- , "$1": [{"type": "var", "name": "PATH"}]
- }
- , ")${PATH:+:}${PATH}\""
+ , "${PATH:+:}\"${PATH}\""
]
}
]