anvil — reference
build system specification for invil/amboso
anvil |
[options] [tag]
[extra_args ...] [command]
|
anvil is a tag-driven build system
specification implemented by two compatible frontends:
- amboso
- POSIX shell reference implementation.
- invil
- Rust canonical implementation.
anvil orchestrates builds, tests, and
project initialization on top of make(1),
git(1), and optional build kernels.
A build is defined by:
- tag
- Optional identifier for a build configuration.
- mode
- Execution mode. Supported modes include:
base,
git,
test, and
testmacro.
- kern
- Build backend selector. Supported kernels include:
anvilC,
anvilPy,
and
custom.
If tag is omitted, the latest available tag
is selected using implementation-defined ordering.
-D
dir,
--amboso-dir=dir
- Directory for tag artifacts. Default: ./bin
-O
dir,
--stego-dir=dir
- Directory containing stego.lock. Default: current
directory.
-I
dir,
--builds-dir=dir
- Build output directory. Default: current directory.
-K
dir,
--kazoj-dir=dir
- Test directory root.
-S
name,
--source=name
- Set source name.
-E
name,
--execname=name
- Set output executable name.
-M
tag,
--maketag=tag
- Minimum tag requiring make-based build.
-a
version,
--anvil-version=version
- Set compatibility version. Default:
2.1.2
-k
kern,
--anvil-kern=kern
- Set build kernel. Default:
amboso-C
-G
dir,
--gen-c-header=dir
- Generate C header with build metadata and system information.
-T,
--test
- Enable test mode.
-B,
--base
- Enable base mode.
-g,
--git
- Enable git mode.
-t,
--testmacro
- Enable test macro mode.
-i,
--init
- Initialize or build all tags for current mode.
-p,
--purge
- Remove all build artifacts for current mode.
-d,
--delete
- Delete artifact for specified tag.
-b,
--build
- Build specified tag.
-r,
--run
- Run built artifact for specified tag.
-l,
--list
- List tags for current mode.
-L,
--list-all
- List tags for all modes.
-q,
--quiet
- Reduce output verbosity.
-s,
--silent
- Suppress most output.
-V
level,
--verbose=level
- Set verbosity level. Default:
3
-w,
--watch
- Report execution timing.
-J,
--logged
- Write output to anvil.log.
-P,
--no-color
- Disable colored output.
-F,
--force
- Force rebuild.
-R,
--no-rebuild
- Disable automatic make rebuild step.
-C
arg,
--config=arg
- Pass configuration argument to build system.
-Z
flags,
--cflags=flags
- Pass compiler flags for single-file builds.
-e,
--strict
- Disable extensions beyond amboso 2.0 semantics.
-X,
--ignore-gitcheck
- Ignore git mode validation.
-v,
--version
- Print version and exit.
-h,
--help
- Print help and exit.
-W,
--warranty
- Print warranty information.
-Y
time
- Set explicit start timestamp.
-z
- Run make pack target.
- test
[testname]
- Run all tests or a specific test.
- build
- Build latest or selected tag.
- init
- Initialize a new project.
- version
- Print version information.
- Rebuild
policy
- Build invokes make rebuild by default unless disabled
with
--no-rebuild.
- Logging
- When
--logged is enabled, output is written to
anvil.log.
- Strict
mode
- When
--strict is enabled, extensions beyond amboso
2.0 semantics are disabled.
- Config
precedence
- Command-line options override configuration file values.
- ./bin/
- Default directory for build artifacts.
- stego.lock
- Project configuration file.
- anvil.log
- Log output file.
- amboso
- Reference shell implementation defining baseline behavior.
- invil
- Canonical Rust implementation defining extended behavior.
Divergence between implementations is permitted only when
explicitly specified in this specification.