> ## Documentation Index
> Fetch the complete documentation index at: https://docs.usexfg.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Building from source

> Complete build instructions for developers on Linux, macOS, and Windows.

## Dependencies

| Dependency | Minimum version | Notes |
| - | - | - |
| CMake | 3.16 | Build system |
| GCC / Clang | GCC 7 / Clang 6 | C++17 required |
| Boost | 1.86 | All components (uses `io_context`) |
| OpenSSL | 3.0 | For SwapDaemon (supports 4.x) |
| secp256k1 | — | Elliptic curve crypto (system pkg or submodule) |
| Go | 1.24 | For swapxfg TUI only |

> [tab] Ubuntu / Debian
>
> ```bash theme={"dark"}
> sudo apt-get update
> sudo apt-get install -y \
>   build-essential cmake \
>   libboost-all-dev \
>   libssl-dev \
>   libsecp256k1-dev \
>   libjsoncpp-dev \
>   pkg-config
> ```

> [tab] macOS
>
> ```bash theme={"dark"}
> brew install cmake boost openssl@4 secp256k1 jsoncpp pkg-config
> # OpenSSL path for CMake:
> export OPENSSL_ROOT_DIR=$(brew --prefix openssl@4)
> ```

> [tab] Windows
>
> Install Visual Studio 2019+ with C++ workload. Install CMake, Boost (prebuilt binaries from boost.org), and OpenSSL (Win32/Win64 OpenSSL from slproweb.com).

## Build

```bash theme={"dark"}
git clone https://github.com/usexfg/fuego-suite.git
cd fuego-suite
mkdir build && cd build
cmake .. -DUSE_VENDORED_SECP256K1=OFF
make -j$(nproc)        # Linux
make -j$(sysctl -n hw.ncpu)  # macOS
```

Binaries are in `build/release/src/`:

* `fuegod` — daemon
* `fire_wallet` — CLI wallet
* `testnetd` — testnet daemon variant
* `xfg-swapd` — swap daemon (all pairs)
* `fuego-tui` — Go TUI (built separately)
* `swapxfg` — Go swap CLI/TUI (built separately)

## Build targets

```bash theme={"dark"}
make fuegod          # Daemon only
make fire_wallet     # Wallet only
make xfg-swapd       # Swap daemon only
```

## SwapDaemon dependencies

The swap daemon links OpenSSL via CMake imported targets (`OpenSSL::SSL`, `OpenSSL::Crypto`). If CMake cannot find OpenSSL:

```bash theme={"dark"}
cmake .. -DOPENSSL_ROOT_DIR=/usr/local/opt/openssl
```

## Go TUI (optional)

```bash theme={"dark"}
cd swapxfg
go build ./...
```

Requires Go 1.24+. The TUI connects to `fuegod` via HTTP RPC.

## Running tests

```bash theme={"dark"}
cd build
make tests
ctest --output-on-failure
```

Integration tests require a running testnet node. See `tests/EndToEnd/` for setup.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.