Installation
This guide covers building NullClaw from source with detailed instructions for all platforms, optimization options, and advanced configuration.Prerequisites
Required Dependencies
- macOS
- Linux
- Windows
- ARM/Edge
Verify Zig Installation
Building from Source
1
Clone the repository
2
Choose your build profile
NullClaw supports multiple build profiles optimized for different use cases:
Recommended: Use
ReleaseSmall for production deployments to achieve the advertised 678 KB binary size.3
Configure build options
Memory Backend Selection
Choose which memory backends to include:base/minimal: Basic file and memory backendssqlite: SQLite-backed memory with vector + FTS5 search (default)lucid: Lucid memory backend (requires SQLite)redis: Redis backend (requires Redis client library)lancedb: LanceDB vector store (requires SQLite)postgres: PostgreSQL backend (requires libpq)all: All available backends
Channel Selection
Include only the channels you need:cli, telegram, discord, slack, whatsapp, matrix, mattermost, irc, imessage, email, lark, dingtalk, line, onebot, qq, maixcam, signal, nostr, web4
Build the binary
Run the build:Build output:The compiled binary is at:
zig-out/bin/nullclaw5
Verify the build
Platform-Specific Builds
Cross-Compilation
Zig makes cross-compilation trivial:Static Binary (Fully Portable)
Create a fully static binary with no dynamic dependencies:Binary Size Optimization
Aggressive Size Reduction
For absolute minimum binary size:Build Options Reference
Frombuild.zig, these optimizations are automatically applied for ReleaseSmall:
Installation Methods
System-Wide Installation
- Unix-like (macOS/Linux)
- Linux (systemwide, respects XDG)
- Windows
- Development (PATH only)
Container Deployment
Verification
Post-Installation Checks
1
Check binary size
2
Check startup time
3
Run system diagnostics
- Zig version compatibility
- Binary integrity
- System dependencies
- Configuration validity
4
Run test suite (optional)
From the source directory:Expected: 3,230+ tests passing, 0 failures, 0 memory leaks
Benchmark Your Build
Measure performance and resource usage:Development Setup
For contributors and developers:1
Clone with full history
2
Install development tools
pre-commit: Runszig fmt --checkpre-push: Runs full test suite
3
Build in development mode
4
Format code
Troubleshooting
Build Failures
SQLite vendored checksum mismatch
SQLite vendored checksum mismatch
Error:
error: VendoredSqliteChecksumMismatchCause: Vendored SQLite files were modified or corruptedSolution:Invalid channels/engines option
Invalid channels/engines option
Error:
error: unknown channel 'foo' in -Dchannels listSolution: Check the available options:Out of memory during build
Out of memory during build
Error:
error: OutOfMemorySolution: Build on a machine with more RAM, or use a smaller configuration:Cross-compilation failures
Cross-compilation failures
Error:
error: unable to find native system library 'c'Solution: Install cross-compilation toolchain:Runtime Issues
Command not found after installation
Command not found after installation
Error:
bash: nullclaw: command not foundSolution: Verify PATH or use absolute path:Next Steps
Quick Start
Configure and run your first agent
Configuration
Learn about config.json and provider setup
Development Guide
Contribute to NullClaw or add custom providers
Deployment
Deploy NullClaw in production environments
For advanced build configurations and vtable interface development, see the Development Guide and AGENTS.md in the repository.