LinuxCommandLibrary

ninja

TLDR

Build project

$ ninja
copy
Build specific target
$ ninja [target]
copy
Build with multiple jobs
$ ninja -j [8]
copy
Clean build
$ ninja -t clean
copy
Dry run
$ ninja -n
copy
Verbose output
$ ninja -v
copy
Use specific build file
$ ninja -f [build.ninja]
copy
Show build graph
$ ninja -t graph [target]
copy

SYNOPSIS

ninja [options] [targets]

DESCRIPTION

ninja is a small, fast build system. It focuses on speed and correctness.
The tool processes build.ninja files. Usually generated by CMake or Meson.
ninja is fast build system.

PARAMETERS

TARGETS

Build targets.
-j N
Parallel jobs.
-f FILE
Build file.
-v
Verbose mode.
-n
Dry run.
-t TOOL
Run subtool.
--help
Display help information.

CAVEATS

Build files usually generated. Simpler than Make. Designed for speed.

HISTORY

Ninja was created by Evan Martin at Google for building Chrome, released in 2012.

SEE ALSO

cmake(1), meson(1), make(1)

Copied to clipboard