main shrub/shinobi / doc / shin.1
SHINOBI(1) General Commands Manual SHINOBI(1)

shinpublic domain makefile compiler

shin [-age] [-G ninja | dot | compcmd] [-M posix2024 | posix2008 | gnu] [-C dir] [-f file] [VAR=value ...] [target ...]

The shin utility takes a makefile as input, and outputs an alternative representation of said makefile's build graph to a file. The default backend is for the ninja build system.

The options are as follows:

Print the abstract syntax tree to stdout and exit.
Print the build graph to stdout and exit.
generator
Specify the output generator. Valid generators are ninja (default, outputs to build.ninja), dot (outputs to build.dot for graphviz), and compdb (outputs to compile_commands.json).
mode
Select the accepted dialect for the input makefile. Valid modes are gnu (default), posix2024, and posix2008.
dir
Change to dir before reading the makefile.
file
Read the makefile from file instead of the default Makefile, GNUmakefile or makefile.
Override environment variables when expanding makefile variables.

Variable assignments of the form VAR=value can be specified on the command line and will override makefile definitions. One or more target arguments specifies the goals to build; if none are specified, the default goal from the makefile is used. even when a goal is specified, the entire build graph is still processed, not just the target goal. if using the ninja generator, the target goal will not be the default target in the generated file, and will have it's original name.

make(1), samu(1)

The makefile format parsed by shin aims to follow the most up to date POSIX make specification (IEEE Std 1003.1-2024) with extensions and changes from GNU make. when in posix2008 mode, it aims to strictly comply with IEEE Std 1003.1-2008, without any extensions. when in posix2024 mode, it aims to strictly comply with IEEE Std 1003.1-2024, without any extensions.

May 14, 2026 Linux 6.18.35-0-lts