Building a ZENIQ Smart Chain node
zeniqsmartd is the ZENIQ Smart Chain full-node client. It is a
Tendermint ABCI application running
an Ethereum-compatible EVM, and it serves the JSON-RPC API.
Most developers never need to run their own node — the public
https://api.zeniq.network endpoint is enough. Build
from source when you want a private endpoint, an archive/index node, or to run a
validator.
zeniqsmartd is a cgo build: it links C/C++ libraries (RocksDB and the
evmone-based EVM), so you need a C/C++ toolchain in addition to Go. A helper
script, build.sh, compiles the C dependencies from source and then builds the
binary.
Source layout
The client is split across four sibling Go modules, each its own repository under github.com/zeniqsmart:
| Repository | Role |
|---|---|
zeniq-smart-chain | The application: ABCI app, JSON-RPC, staking, cross-chain importer, and the zeniqsmartd binary |
evm-zeniq-smart-chain | EVM engine + C++ evmwrap/evmone bridge |
ads-zeniq-smart-chain | Authenticated Merkle world-state store |
db-zeniq-smart-chain | Block/transaction/log history + query index |
zeniq-smart-chain references the other three modules with replace => ../<dir>
directives, so the four repositories must be checked out side by side
using exactly the names above. Renaming a directory breaks the build.
Prerequisites
- Go 1.23 or newer
- A C/C++ toolchain:
gcc,g++,make,cmake,git
On Ubuntu:
sudo apt update
sudo apt install -y build-essential cmake git
Install Go from go.dev/dl and make sure go is on your
PATH.
Clone the four repositories side by side
mkdir smart-chain-dev && cd smart-chain-dev
git clone https://github.com/zeniqsmart/ads-zeniq-smart-chain
git clone https://github.com/zeniqsmart/db-zeniq-smart-chain
git clone https://github.com/zeniqsmart/evm-zeniq-smart-chain
git clone https://github.com/zeniqsmart/zeniq-smart-chain
You should end up with:
smart-chain-dev/
├── ads-zeniq-smart-chain/
├── db-zeniq-smart-chain/
├── evm-zeniq-smart-chain/
└── zeniq-smart-chain/
Build
From the application module, source build.sh (source it, don't just run it —
it exports the cgo build flags into your shell):
cd zeniq-smart-chain
. ./build.sh
build.sh will, in order:
- Export
CGO_CFLAGS/CGO_LDFLAGSpointing at the compiled C dependencies. - Build the C dependencies (RocksDB and friends) from source into
build/. - Enable the
replacedirectives that wire in the three sibling modules. - Build the
evmone-based EVM bridge (libevmwrap.a). go buildthe client.
The result is the binary at build/zeniqsmartd:
./build/zeniqsmartd version
Because the C dependencies are compiled from source, a very new GCC/CMake may
need minor flags (e.g. CMake ≥ 4 policy compatibility, or -include cstdint for
RocksDB under GCC 13+). If a dependency fails to compile, check the project's
deps.sh — the known workarounds live there.
Initialise and run
Initialising, configuring (app.toml, config.toml, genesis.json, seeds/peers)
and starting the node is covered by the
zeniq-smart-chain repository README.
In outline:
./build/zeniqsmartd init <your-moniker>
# edit ~/.zeniqsmartd config, set peers/seeds
./build/zeniqsmartd start
Once the node is synced it serves the same JSON-RPC API as the public endpoints, at your configured host and port.