mirror of
https://github.com/google/sandboxed-api.git
synced 2024-03-22 13:11:30 +08:00
Use to_list() on Bazel depsets for iteration.
Starting with Bazel 0.27.0 --incompatible_depset_is_not_iterable became the default. Fixes #27 PiperOrigin-RevId: 254703981 Change-Id: I727e4b1c6a907c8794a00f61646c13ad8d4437b7
This commit is contained in:
parent
6ca744b959
commit
4bcea59309
@ -73,23 +73,23 @@ def sapi_interface_impl(ctx):
|
|||||||
# Append system headers as dependencies
|
# Append system headers as dependencies
|
||||||
input_files += cc_ctx.headers.to_list()
|
input_files += cc_ctx.headers.to_list()
|
||||||
append_all(extra_flags, "-D", cc_ctx.defines)
|
append_all(extra_flags, "-D", cc_ctx.defines)
|
||||||
append_all(extra_flags, "-isystem", cc_ctx.system_includes)
|
append_all(extra_flags, "-isystem", cc_ctx.system_includes.to_list())
|
||||||
append_all(extra_flags, "-iquote", cc_ctx.quote_includes)
|
append_all(extra_flags, "-iquote", cc_ctx.quote_includes.to_list())
|
||||||
|
|
||||||
for h in cc_ctx.headers:
|
|
||||||
# Collect all headers as dependency in case libclang needs them.
|
|
||||||
if h.extension == "h" and "/PROTECTED/" not in h.path:
|
|
||||||
input_files.append(h)
|
|
||||||
if ctx.attr.input_files:
|
if ctx.attr.input_files:
|
||||||
|
for h in cc_ctx.headers.to_list():
|
||||||
|
# Collect all headers as dependency in case libclang needs them.
|
||||||
|
if h.extension == "h" and "/PROTECTED/" not in h.path:
|
||||||
|
input_files.append(h)
|
||||||
for target in ctx.attr.input_files:
|
for target in ctx.attr.input_files:
|
||||||
if target.files:
|
if target.files:
|
||||||
for f in target.files:
|
for f in target.files.to_list():
|
||||||
input_files_paths.append(f.path)
|
input_files_paths.append(f.path)
|
||||||
input_files.append(f)
|
input_files.append(f)
|
||||||
|
|
||||||
# Try to find files automatically.
|
# Try to find files automatically.
|
||||||
else:
|
else:
|
||||||
for h in cc_ctx.headers:
|
for h in cc_ctx.headers.to_list():
|
||||||
# Collect all headers as dependency in case clang needs them.
|
# Collect all headers as dependency in case clang needs them.
|
||||||
if h.extension == "h" and "/PROTECTED/" not in h.path:
|
if h.extension == "h" and "/PROTECTED/" not in h.path:
|
||||||
input_files.append(h)
|
input_files.append(h)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user