- Using Ninja
- Configure your environment to use Ninja
- Build Programs
- Android using Ninja
- Windows uses
- Skills
- Problem
Ninja's original intention is Ninja, Ninja Turtle Ninja, here is used by Google to their compilation system, the goal is to replace make and other builders, because they feel that the other builders are too slow, for which they have to compare, for Chrome and other tens of thousands of files of the oversized program, With Ninja, the compilation starts almost immediately, and make takes almost 10 seconds to start compiling.
Ninja Another feature, in fact, is not his mother's characteristics, is independent of the compilation system input files, I want to ask Google God, is not cmake CMakeList.txt it?
Google compares other compilation systems to high-level languages, and tries to design it as a lower-level assembler to optimize compilation performance from the command plane. Ninja's build file is for people to read, but not particularly handy for handwriting. These features allow her to quickly evaluate incremental builds. After all, not every time you have to start from scratch.
Ninjia's underlying features make her more suitable for embedding powerful build systems. With Gyp (haha, CMakeLists.txt), Ninja can build chrome and V8, node. js, and more. With CMake, Ninja can build LLVM (virtual machines), KDE desktops, and so on.
How to get ninja?
On GitHub: Git clone git://github.com/martine/ninja.git
Or we can do this on the Debian/ubuntu: Apt-get install Ninja-build
This article is original, reproduced please indicate the source, offenders must investigate
Focus on the public platform: the Programmer Interaction Alliance (coder_online), you can get the first original technical articles, and (Java/c/c++/android/windows/linux) technology Daniel Friends, online communication programming experience, get programming basics, Solve programming problems. Programmer Interactive Alliance, Developer's own home.
Section reference: Https://code.google.com/p/chromium/wiki/NinjaBuild
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
How do I compile our program using the Ninja compilation system?