Compilers and runtimes
Choose the
right tool.
Nox detects tools from PATH and keeps language-specific invocation in Riders and executor backends.
Setup detects the native trio.
nox setup looks for a C compiler, linker, and archiver. C detection prefers cc, clang, then gcc; C++ uses c++, clang++, then g++; archives use ar or llvm-ar. Other Riders check their tool when their target is built.
cc -> clang -> gcc
c++ -> clang++ -> g++
ar -> llvm-arBuilt-in toolchain paths.
Ccc, clang, gccNative compile, link, static-library, and shared-library actions.
C++c++, clang++, g++Native C++ compile and link actions for .cpp, .cc, and .cxx.
RustrustcDirect Rust targets; Cargo is used for Rust executables with Cargo.toml.
Dldc2, dmd, gdcNative executable builds and temporary direct-file runs.
Gogogo build executable targets.
Javajavac, jarClass compilation followed by JAR packaging.
C#csc, mcsExecutable compilation through the detected compiler.
Swift / Zigswiftc / zigNative executable actions.
Python / JavaScriptpython3 / nodeSyntax checks and packaged target artifacts.
TypeScript / Kotlintsc / kotlincJavaScript transpilation or runnable JAR packaging.
Project flags and invocation flags.
Target flags, include_dirs, defines, and linker_flags stay with the target. Repeated --compile-flag values add flags to compiler invocations for setup or the current build.
nox setup build --compile-flag -Wall
nox build -C build --compile-flag -O2Failures name the dependency.
Nox does not silently switch to a different language backend. If a required compiler or runtime is absent, setup or build reports the missing toolchain. Install the tool and ensure it is visible through PATH, then run setup again when the configured native tool changed.