LoginSignup
2
2

More than 5 years have passed since last update.

Brillo で 使われている 新 build system Soong, Blueprint, Ninja, Kati and go

Last updated at Posted at 2015-11-13

前回 は、brilloを動いているfileを分析しましたが、それを生成するbuild systemが変更になっているので、分析してみます。

keywordは、
1. Blueprint
2. Ninja
3. Kati
4. Soong
5. go
です。

それぞれについての説明を訳してみます。

Blueprint

Blueprint is a meta-build system that reads in Blueprints files that describe modules that need to be built, and produces a Ninja manifest describing the commands that need to be run and their dependencies. Where most build systems use built-in rules or a domain-specific language to describe the logic for converting module descriptions to build rules, Blueprint delegates this to per-project build logic written in Go. For large, heterogenous projects this allows the inherent complexity of the build logic to be maintained in a high-level language, while still allowing simple changes to individual modules by modifying easy to understand Blueprints files.
Blueprintとは、meta build systemです。buildするmoduleを記述したBlueprint fileを読み込んで、Ninja manifestを生成します。Ninja manifestは、実行すべきcommandとその依存関係を記述したものです。 多くのbuild systemが、組み込みのruleやdomain specific languageを用いて、build ruleを記述していますが、Blueprintでは、これを、go言語で書かれたproject毎のbuild logicに変換して実行します。high-levelなlogicでbuild logicをメンテすることができるので、巨大なヘテロジニアスなprojectにおいて有用です。それは、わかりやすいBlueprint fileを変更するだけで、個々のmoduleをsimpleに変更することができるためです。

Ninja

Ninja is a small build system with a focus on speed. It differs from other build systems in two major respects: it is designed to have its input files generated by a higher-level build system, and it is designed to run builds as fast as possible.
Ninjaは、speedに特化した小さなbuild systemです。 他との違いは、2つあり、1つ目は、より高級なbuild systemにより入力ファイルを生成してもらうという設計です。もう1つは、できるだけ高速にbuildが実行できるように設計されているということです。
Why yet another build system?
Where other build systems are high-level languages Ninja aims to be an assembler.
なぜNinjaなのか?
他のbuild systemを高級な言語とするならば、Ninjaはアセンブラと言えます。
Ninja build files are human-readable but not especially convenient to write by hand. (See the generated build file used to build Ninja itself.) These constrained build files allow Ninja to evaluate incremental builds quickly.
Ninjaは人間が読解可能ですが、手で書くには適していません。(Ninjaをbuildするために使っている生成されたbuild fileを見てみてください。) これらの制約は、Ninjaが高速にincremental buildをするのに役立っています。

Kati

kati is an experimental GNU make clone. The main goal of this tool is to speed-up incremental build of Android.

Currently, kati does not offer a faster build by itself. It instead converts your Makefile to a ninja file.
Katiは、GNU makeの実験的なcloneです。Androidのincremental buildを高速化するのが目標のツールです。

現在は、Kati自身では高速化を実現しているわけではないです。代わりにMakefileをninja fileに変換しています。

Soong

Soong is a builder for Android that uses Blueprint to parse Blueprints files and Ninja to do the dependency tracking and subprocess management.

Soong itself is responsible for converting the modules read by Blueprint into build rules, which will be written to a build.ninja file by Blueprint.
Soongは、Androidのためのbuilderです。Blueprintを使って、Blueprints fileをparseし、(Ninja manifestを生成し)、Ninjaを使ってdependencyをtrackし、subprocessの管理をします。

Soong自身は、Blueprintによって読まれたmoduleをbuild rule ("build.ninja" file)に変換する役割を持ちます。

go

言わずと知れたgo https://golang.org/

Go is an open source programming language that makes it easy to build simple, reliable, and efficient software.
GOは、open sourceなプログラミング言語です。シンプルで、信頼がおけ、効率的なソフトウェアを簡単に書くことができます。
2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2