Allow importing starlark code in makefiles
Adds a new `$(call run-starlark,my/starlark/file.bzl)` function that will run the starlark file and set all the variables in the variables_to_export_to_make dictionary as make variables. Fixes: 280685526 Test: m nothing repeatedly causes no ninja regeneration, but touching all_versions.bzl does. go test, ./out/rbcrun -mode=rbc ./build/make/tests/run.rbc Change-Id: Ic72e18dd28dba8233ba2dfb658b5d03ccece1bfd
This commit is contained in:
4
tools/rbcrun/testdata/module1.star
vendored
4
tools/rbcrun/testdata/module1.star
vendored
@@ -2,6 +2,6 @@
|
||||
load("assert.star", "assert")
|
||||
|
||||
# Make sure that builtins are defined for the loaded module, too
|
||||
assert.true(rblf_wildcard("module1.star"))
|
||||
assert.true(not rblf_wildcard("no_such file"))
|
||||
assert.true(rblf_wildcard("testdata/module1.star"))
|
||||
assert.true(not rblf_wildcard("testdata/no_such file"))
|
||||
test = "module1"
|
||||
|
Reference in New Issue
Block a user