6.2 KiB
Installer (Ubuntu)
Status
The preferred fresh-host workflow for the 2.0 branch is currently
contrib/agrarian-build-menu.sh, with the direct helper scripts
contrib/build-linux.sh, contrib/build-linux-wallet.sh, and
contrib/build-win64-wallet.sh used for repeatable scripted builds. This
installer document is retained for the older installer/agrarian-installer.sh
CLI and should be treated as secondary until that installer is revalidated
against the current Qt 6.8.3/OpenSSL 3.5.6/Boost 1.91.0/Expat 2.8.0/FreeType
2.14.3 depends baseline.
Overview
The Agrarian installer is installer/agrarian-installer.sh. It automates the Ubuntu build steps by:
- Building the deterministic
depends/prefix (make -C depends HOST=... USE_WALLET=... -j...). - Configuring the project with the depends
config.siteand prefix. - Building the daemon and CLI utilities (via
--action daemonor--action all). - Building the Qt wallet on Linux hosts (via
--action qt, or--action allwhen Qt is enabled). - Cross-compiling Qt wallets for Windows targets (via
--action qt --qt-target ...).
It does not:
- Install system packages (it only checks for required toolchains and prints an
apt-getcommand if missing). - Run
make installor copy binaries into/usr/local. - Package platform installers (e.g., Windows/macOS wallet bundles).
- Run or configure the daemon after the build.
Quick Start (Ubuntu/Debian)
Clone the repo and enter it (standard git clone workflow), then:
Show installer help:
./installer/agrarian-installer.sh --help
Build the daemon (runs depends, configure, then make -C src agrariand):
./installer/agrarian-installer.sh --action daemon
Build the Qt wallet on Linux (runs depends Qt target when HOST is Linux, then make -C src/qt agrarian-qt):
./installer/agrarian-installer.sh --action qt
Build Qt wallets for cross targets (examples):
./installer/agrarian-installer.sh --action qt --qt-target win64
./installer/agrarian-installer.sh --action qt --qt-target win32
./installer/agrarian-installer.sh --action qt --qt-target all
Use contrib/agrarian-build-menu.sh for the current ARM64 daemon and native
ARM64 Qt wallet flows. The legacy installer document is kept as secondary
reference and should not be treated as the release authority for ARM builds.
Expected outputs:
- Depends prefix:
depends/<host-triplet>/ - Daemon:
src/agrariand - CLI utilities (when using
--action allor a full top-level build):src/agrarian-cli,src/agrarian-tx - Qt wallet (Linux):
src/qt/agrarian-qt - Qt wallet (Windows):
src/qt/agrarian-qt.exe
Run the daemon:
./src/agrariand
Common Installer Options
--action <depends|daemon|qt|all>
dependsbuilds only thedepends/prefix.daemonbuilds the daemon (src/agrariand). If depends are missing, the installer builds them first.qtbuilds the Qt wallet (src/qt/agrarian-qt). If depends are missing, the installer builds them first.allbuilds depends and then runs top-levelmakein the repo root.
--qt-target <native|win64|win32|all>
nativeuses--hostas-is (default).win64maps tox86_64-w64-mingw32.win32maps toi686-w64-mingw32.allbuilds native + the Windows cross targets listed above.
--host <triplet>
- Sets the build host triplet (default:
x86_64-pc-linux-gnu). - Passed to
dependsasHOST=<triplet>.
--wallet <0|1>
- Controls wallet support.
- Passed to
dependsasUSE_WALLET=<0|1>. - When
--wallet 0, the installer also adds--disable-walletduringconfigure.
--dry-run
- Prints the commands the installer would run, without executing them.
NO_QT=1 in depends
- The installer does not expose
NO_QT. - If you need to skip Qt in depends, run it manually:
make -C depends HOST=x86_64-pc-linux-gnu NO_QT=1
Troubleshooting
Boost library naming/layout (the -mt suffix)
- Depends builds may produce Boost libs with suffixes like
libboost_thread-gcc-mt-1_91.a. - The installer checks for
libboost_thread*.aandlibboost_system*.a, so it tolerates-mtand versioned names. - If you are configuring manually, keep
--with-boost=<depends-prefix>(the installer sets this for you) to avoid system Boost fallback.
config.site and PATH pitfalls
- The installer configures with
CONFIG_SITE=depends/<host>/share/config.site. - Current helper builds use native host tools from
depends/build/<build-host>/bin. Do not overwritePATHwith a minimal value; ensure/usr/binand other system paths remain available. - If
config.siteis missing, rebuild depends:
./installer/agrarian-installer.sh --action depends
Qt pkg-config files missing in the depends prefix
The installer requires these .pc files in depends/<host>/(lib|share)/pkgconfig:
- Native Ubuntu Qt6 path:
Qt6Core.pc,Qt6Gui.pc,Qt6Network.pc,Qt6Widgets.pc - Windows cross-build Qt6 path:
Qt6Core.pc,Qt6Gui.pc,Qt6Network.pc,Qt6Widgets.pc
Fix by rebuilding depends with Qt enabled:
./installer/agrarian-installer.sh --action qt
Forcing rebuilds
- Use
--reset-dependsto deletedepends/work,depends/built, anddepends/<host>, then re-run the installer action you need. - If you need a fresh depends build without deleting the prefix, re-run the depends build (same command the installer prints on failure):
make -C depends HOST=<host> USE_WALLET=<wallet> -j<JOBS>
Qt Cross-Compilation Packages (Ubuntu/Debian)
Install the common Linux build tools (from depends/README.md):
sudo apt-get install make automake cmake curl git g++-multilib libtool binutils-gold bsdmainutils pkg-config python3 patch bzip2 xz-utils
Then install toolchains per target:
- win64:
g++-mingw-w64-x86-64(seedoc/build-windows.md) - win32:
g++-mingw-w64-i686(seedoc/build-windows.md) - aarch64 daemon builds through
contrib/agrarian-build-menu.shuseg++-aarch64-linux-gnuandbinutils-aarch64-linux-gnu
If any toolchain binaries are missing, the installer prints a single apt-get install command that includes the required packages for the selected Qt targets.