Installation¶
This guide covers how to install sigc on your system.
Prerequisites¶
Rust Toolchain¶
sigc is written in Rust and requires the Rust toolchain to build from source.
Follow the prompts and restart your terminal.
Download and run rustup-init.exe.
Windows Support
sigc is primarily developed on Linux/macOS. Windows users should use WSL2 for the best experience.
Verify your installation:
Installation Methods¶
Build from Source (Recommended)¶
Building from source ensures you have the latest features and optimizations for your system.
# Clone the repository
git clone https://github.com/skelf-Research/sigc.git
cd sigc
# Build in release mode
cargo build --release
# The binary is at ./target/release/sigc
Verify the build:
Add to PATH¶
To use sigc from anywhere, add it to your PATH:
Pre-built Binaries¶
Pre-built binaries are available for common platforms on the GitHub Releases page.
# Download for Linux x86_64
curl -L https://github.com/skelf-Research/sigc/releases/latest/download/sigc-linux-x86_64.tar.gz | tar xz
# Download for macOS (Apple Silicon)
curl -L https://github.com/skelf-Research/sigc/releases/latest/download/sigc-darwin-arm64.tar.gz | tar xz
Verify Installation¶
Run these commands to verify sigc is installed correctly:
# Check version
sigc --version
# Show help
sigc --help
# Compile a test file
echo 'data:
prices: load csv from "test.csv"
signal test:
emit prices
portfolio main:
weights = test
backtest from 2024-01-01 to 2024-12-31' > test.sig
sigc compile test.sig
Expected output:
INFO sigc: sigc v0.10.0
INFO sig_compiler: Parsing source
INFO sig_compiler: Parsed 1 data, 0 params, 1 signals, 1 portfolios
INFO sig_compiler: Lowered to 2 IR nodes
INFO sigc: Compilation complete: 2 nodes
Optional: Python Integration¶
To use sigc from Python (Jupyter notebooks, scripts), install the pysigc package:
Verify Python installation:
See Python Integration for detailed usage.
Optional: VS Code Extension¶
For the best development experience, install the VS Code extension:
Then install the generated sigc-0.1.0.vsix in VS Code.
See IDE Setup for detailed instructions.
Troubleshooting¶
Build Fails with "linker not found"¶
Install build essentials:
Build Fails with OpenSSL Errors¶
Install OpenSSL development headers:
"Command not found: sigc"¶
Ensure the binary is in your PATH:
# Check if sigc is in PATH
which sigc
# If not found, add it
export PATH="$PATH:/path/to/sigc/target/release"
Slow Build Times¶
Enable incremental compilation and use sccache:
# Install sccache
cargo install sccache
# Set as compiler wrapper
export RUSTC_WRAPPER=sccache
# Rebuild
cargo build --release
Next Steps¶
Now that sigc is installed, continue to:
- 5-Minute Quickstart - Run your first backtest
- Your First Strategy - Build a complete strategy
- IDE Setup - Configure VS Code