2015-01-23 23:24:17 +01:00
|
|
|
bootstrap_go_package(
|
|
|
|
name = "blueprint",
|
|
|
|
deps = [
|
|
|
|
"blueprint-parser",
|
2015-04-01 05:39:02 +02:00
|
|
|
"blueprint-pathtools",
|
2015-01-23 23:24:17 +01:00
|
|
|
"blueprint-proptools",
|
|
|
|
],
|
2015-03-21 03:39:29 +01:00
|
|
|
pkgPath = "github.com/google/blueprint",
|
2015-01-23 23:24:17 +01:00
|
|
|
srcs = [
|
|
|
|
"context.go",
|
2016-06-03 00:30:20 +02:00
|
|
|
"fs.go",
|
2015-01-23 23:24:17 +01:00
|
|
|
"live_tracker.go",
|
|
|
|
"mangle.go",
|
|
|
|
"module_ctx.go",
|
|
|
|
"ninja_defs.go",
|
|
|
|
"ninja_strings.go",
|
|
|
|
"ninja_writer.go",
|
|
|
|
"package_ctx.go",
|
|
|
|
"scope.go",
|
|
|
|
"singleton_ctx.go",
|
|
|
|
"unpack.go",
|
|
|
|
],
|
2015-06-24 02:21:00 +02:00
|
|
|
testSrcs = [
|
|
|
|
"context_test.go",
|
|
|
|
"ninja_strings_test.go",
|
|
|
|
"ninja_writer_test.go",
|
|
|
|
"splice_modules_test.go",
|
|
|
|
"unpack_test.go",
|
2016-08-08 20:21:09 +02:00
|
|
|
"visit_test.go",
|
2015-06-24 02:21:00 +02:00
|
|
|
],
|
2015-01-23 23:24:17 +01:00
|
|
|
)
|
2014-05-28 01:34:41 +02:00
|
|
|
|
2015-01-23 23:24:17 +01:00
|
|
|
bootstrap_go_package(
|
|
|
|
name = "blueprint-parser",
|
2015-03-21 03:39:29 +01:00
|
|
|
pkgPath = "github.com/google/blueprint/parser",
|
2015-01-23 23:24:17 +01:00
|
|
|
srcs = [
|
2016-06-07 21:28:16 +02:00
|
|
|
"parser/ast.go",
|
2015-01-23 23:24:17 +01:00
|
|
|
"parser/modify.go",
|
|
|
|
"parser/parser.go",
|
|
|
|
"parser/printer.go",
|
|
|
|
"parser/sort.go",
|
|
|
|
],
|
2015-06-24 02:21:00 +02:00
|
|
|
testSrcs = [
|
|
|
|
"parser/parser_test.go",
|
|
|
|
"parser/printer_test.go",
|
|
|
|
],
|
2015-01-23 23:24:17 +01:00
|
|
|
)
|
2014-05-28 01:34:41 +02:00
|
|
|
|
2015-01-23 23:24:17 +01:00
|
|
|
bootstrap_go_package(
|
|
|
|
name = "blueprint-deptools",
|
2015-03-21 03:39:29 +01:00
|
|
|
pkgPath = "github.com/google/blueprint/deptools",
|
2015-01-23 23:24:17 +01:00
|
|
|
srcs = ["deptools/depfile.go"],
|
|
|
|
)
|
2014-10-14 10:30:17 +02:00
|
|
|
|
2015-01-23 23:24:17 +01:00
|
|
|
bootstrap_go_package(
|
|
|
|
name = "blueprint-pathtools",
|
2015-03-21 03:39:29 +01:00
|
|
|
pkgPath = "github.com/google/blueprint/pathtools",
|
2015-01-23 23:24:17 +01:00
|
|
|
srcs = [
|
|
|
|
"pathtools/lists.go",
|
|
|
|
"pathtools/glob.go",
|
|
|
|
],
|
2015-06-24 02:21:00 +02:00
|
|
|
testSrcs = [
|
|
|
|
"pathtools/glob_test.go",
|
|
|
|
],
|
2015-01-23 23:24:17 +01:00
|
|
|
)
|
2014-06-06 23:37:07 +02:00
|
|
|
|
2015-01-23 23:24:17 +01:00
|
|
|
bootstrap_go_package(
|
|
|
|
name = "blueprint-proptools",
|
2015-03-21 03:39:29 +01:00
|
|
|
pkgPath = "github.com/google/blueprint/proptools",
|
2015-10-28 02:15:15 +01:00
|
|
|
srcs = [
|
2015-10-30 21:19:14 +01:00
|
|
|
"proptools/clone.go",
|
2015-10-28 02:15:15 +01:00
|
|
|
"proptools/extend.go",
|
|
|
|
"proptools/proptools.go",
|
2015-11-02 23:58:10 +01:00
|
|
|
"proptools/typeequal.go",
|
2015-10-28 02:15:15 +01:00
|
|
|
],
|
|
|
|
testSrcs = [
|
2015-10-30 19:42:57 +01:00
|
|
|
"proptools/clone_test.go",
|
2015-10-28 02:15:15 +01:00
|
|
|
"proptools/extend_test.go",
|
2015-11-02 23:58:10 +01:00
|
|
|
"proptools/typeequal_test.go",
|
2015-10-28 02:15:15 +01:00
|
|
|
],
|
2015-01-23 23:24:17 +01:00
|
|
|
)
|
2014-10-03 03:36:13 +02:00
|
|
|
|
2015-01-23 23:24:17 +01:00
|
|
|
bootstrap_go_package(
|
|
|
|
name = "blueprint-bootstrap",
|
|
|
|
deps = [
|
|
|
|
"blueprint",
|
|
|
|
"blueprint-deptools",
|
|
|
|
"blueprint-pathtools",
|
2015-05-13 23:36:24 +02:00
|
|
|
"blueprint-bootstrap-bpdoc",
|
2015-01-23 23:24:17 +01:00
|
|
|
],
|
2015-03-21 03:39:29 +01:00
|
|
|
pkgPath = "github.com/google/blueprint/bootstrap",
|
2015-01-23 23:24:17 +01:00
|
|
|
srcs = [
|
|
|
|
"bootstrap/bootstrap.go",
|
|
|
|
"bootstrap/cleanup.go",
|
|
|
|
"bootstrap/command.go",
|
|
|
|
"bootstrap/config.go",
|
|
|
|
"bootstrap/doc.go",
|
2015-05-13 23:36:24 +02:00
|
|
|
"bootstrap/writedocs.go",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
bootstrap_go_package(
|
|
|
|
name = "blueprint-bootstrap-bpdoc",
|
|
|
|
deps = [
|
|
|
|
"blueprint",
|
|
|
|
"blueprint-proptools",
|
|
|
|
],
|
|
|
|
pkgPath = "github.com/google/blueprint/bootstrap/bpdoc",
|
|
|
|
srcs = [
|
|
|
|
"bootstrap/bpdoc/bpdoc.go",
|
2015-01-23 23:24:17 +01:00
|
|
|
],
|
|
|
|
)
|
2014-05-28 01:34:41 +02:00
|
|
|
|
2015-07-23 02:06:06 +02:00
|
|
|
bootstrap_core_go_binary(
|
2015-01-23 23:24:17 +01:00
|
|
|
name = "minibp",
|
|
|
|
deps = [
|
|
|
|
"blueprint",
|
|
|
|
"blueprint-bootstrap",
|
|
|
|
],
|
|
|
|
srcs = ["bootstrap/minibp/main.go"],
|
|
|
|
)
|
2015-01-09 04:35:10 +01:00
|
|
|
|
2016-05-26 19:07:59 +02:00
|
|
|
blueprint_go_binary(
|
2015-01-23 23:24:17 +01:00
|
|
|
name = "bpfmt",
|
|
|
|
deps = ["blueprint-parser"],
|
|
|
|
srcs = ["bpfmt/bpfmt.go"],
|
|
|
|
)
|
2015-01-13 02:43:04 +01:00
|
|
|
|
2016-05-26 19:07:59 +02:00
|
|
|
blueprint_go_binary(
|
2015-01-23 23:24:17 +01:00
|
|
|
name = "bpmodify",
|
|
|
|
deps = ["blueprint-parser"],
|
|
|
|
srcs = ["bpmodify/bpmodify.go"],
|
|
|
|
)
|
2015-06-24 02:21:00 +02:00
|
|
|
|
2015-07-23 02:06:06 +02:00
|
|
|
bootstrap_core_go_binary(
|
2015-06-24 02:21:00 +02:00
|
|
|
name = "gotestmain",
|
|
|
|
srcs = ["gotestmain/gotestmain.go"],
|
|
|
|
)
|
Enhance bootstrap stage selection
This simplifies the bootstrap process while making it more flexible by
moving the stage selection into a go binary(choosestage). It will now be
possible to have more than two build stages.
Now each stage has a ninja template(main.ninja.in) and a timestamp
file(main.ninja.in.timestamp). The timestamp file may be updated by any
build stage that wishes to regenerate the ninja template. If the
choosestage binaries sees that the timestamp is newer than the template,
it will choose the prior stage.
The main stage no longer writes to the source tree to update the
build.ninja.in file. This was a problem for read-only source trees.
Instead, the choosestage binary first checks to see if that file is
newer than the last bootstrap.ninja.in, copies it in place, and starts
the boostrap stage.
The bootstrap stage regenerates it's own ninja template, but that
required a loop through the main stage to actually run it. The
choosestage binary now detects if the template has changed for the
current stage, and will restart the stage.
One change is that if dependencies do get messed up, instead of silently
failing, there's a higher chance that the bootstrap step will just
continue looping, doing nothing. This can happen if the main stage
has a dependency that triggers the bootstrap stage, but the bootstrap
stage doesn't see anything required to rebuild the main ninja file. A
side effect of this requirement is that changes to test code will now
rebuild the main ninja file.
Change-Id: I9965cfba79dc0dbbd3af05f5944f7653054455a2
2015-07-23 02:05:59 +02:00
|
|
|
|
2015-09-18 05:59:51 +02:00
|
|
|
bootstrap_core_go_binary(
|
|
|
|
name = "gotestrunner",
|
|
|
|
srcs = ["gotestrunner/gotestrunner.go"],
|
|
|
|
)
|
|
|
|
|
2015-07-25 01:53:27 +02:00
|
|
|
bootstrap_go_binary{
|
|
|
|
name = "loadplugins",
|
|
|
|
srcs = ["loadplugins/loadplugins.go"],
|
|
|
|
}
|