-
Notifications
You must be signed in to change notification settings - Fork 192
Description
The new directory and subdirectory rules seem to only accept regular files. While this works well for sysroots (only usage of these new rules i can find) that are extracted during loading phase, it does not work if the sysroot archives kept intact as an archive and only extracted during execution phase when actually needed.
I am proposing that we add support for sources that are ctx.actions.declare_directory and support globbing over them. This is probably not possible due to how TreeArtifacts works so i am not sure how this can be implemented without the help of Bazel core.
bazel-lib has a similar rule https://github.com/bazel-contrib/bazel-lib/blob/main/docs/directory_path.md it only supports "plucking" a file nested within treeartifacts but it only works if the consumer rule checks the DirectoryPathInfo (which i believe similar to what directory rule does)