From 293488e5c0fb4416e7ac0f60e3bf6348334dda82 Mon Sep 17 00:00:00 2001 From: Paul Cristian Sarbu Date: Mon, 7 Apr 2025 12:24:57 +0200 Subject: rules CC: Support debug fission in linting As the command passed to the linter can produce additional outputs if debug fission is enabled, pass those artifact paths in a new variable "extra outs", which the ["lint", "targets"] rule can then make it available in the meta.json file expected by the linter. --- lint/RULES | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'lint/RULES') diff --git a/lint/RULES b/lint/RULES index 6bdfba7..684ec2f 100644 --- a/lint/RULES +++ b/lint/RULES @@ -58,10 +58,13 @@ , " by the field \"config\", and" , "- OUT pointing to a directory to which files with the lint result" , " can be written." - , "- META pointing to a json file contaning" + , "- META pointing to a json file containing" , " - at key \"direct deps artifact names\" a list of all input" , " artifacts that come from the target itself or are runfiles of a" , " direct dependency." + , " - at key \"extra outs\" a list of extra output artifacts that the" + , " command might produce, such as DWARF objects if debug fission is" + , " enabled." , "- TMPDIR pointing to a directory location that can be used to" , " create additional temporary files." , "It is supposed to indicate by the exit code whether the file to lint" @@ -163,6 +166,12 @@ , "provider": "direct deps artifact names" } ] + , [ "extra outs" + , { "type": "DEP_PROVIDES" + , "dep": {"type": "var", "name": "_"} + , "provider": "extra outs" + } + ] ] , "body": { "type": "TREE" @@ -189,7 +198,8 @@ { "type": "json_encode" , "$1": { "type": "env" - , "vars": ["direct deps artifact names"] + , "vars": + ["direct deps artifact names", "extra outs"] } } } -- cgit v1.2.3