File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -65,8 +65,10 @@ def _ament_index_share_files_impl(ctx):
6565 }
6666
6767 for src in ctx .attr .srcs :
68- # src is a target that could have multiple files
69- for file in src .files .to_list ():
68+ for file in depset (transitive = [
69+ src .files ,
70+ src [DefaultInfo ].default_runfiles .files ,
71+ ]).to_list ():
7072 sp = file .short_path
7173 if sp .startswith (ctx .attr .strip_prefix ):
7274 sp = sp [len (ctx .attr .strip_prefix ):]
@@ -131,7 +133,8 @@ with the same package.
131133
132134Args:
133135 package_name: name of a ROS 2 package to which these share files belong
134- srcs: files to put into the share directory
136+ srcs: targets whose files are placed into the share directory. Both
137+ direct files and transitive runfiles are included.
135138 prefix: optional prefix to give to the generated runfiles.
136139 strip_prefix: optional prefix to strip from the short_path of the files
137140
You can’t perform that action at this time.
0 commit comments