aboutsummaryrefslogtreecommitdiff
path: root/docs/yaml/functions/structured_sources.yaml
blob: a5f0a83f3b1c92287d916a645a547b0b8a68a676 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
name: structured_sources
returns: structured_src
since: 0.62.0
description: |
  Create a StructuredSource object, which is opaque and may be passed as a source
  to any build_target (including static_library, shared_library, executable,
  etc.). This is useful for languages like Rust, which use the filesystem layout
  to determine import names. This is only allowed in Rust targets, and cannot be
  mixed with non structured inputs.

posargs:
  root:
    type: list[str | file | custom_tgt | custom_idx | generated_list]
    description: Sources to put at the root of the generated structure

optargs:
  additional:
    type: dict[str | file | custom_tgt | custom_idx | generated_list]
    description: |
      Additional sources, where the key is the directory under the root to place
      the values