Skip to content

ripple/xbridge_witness

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Witness Server for XRPL Sidechains

This is the Witness Server for XLS-38d Cross-Chain bridge project. "Witness Servers" validate transfers between "door accounts" that connect a locking chain to each issuing chain by listening for transactions on one or both of the chains and signing attestations to prove certain events happened on a chain.

Branches

  • develop: The latest set of unreleased features, and the most common starting point for contributions.
  • release: The latest beta release or release candidate.
  • main: The latest stable release.

Release process:

  • Bump version in BuildInfo.cpp and add -rcX suffix. (for example "1.0.0-rc1"). Name this commit "Version x.x.x-rcX".
  • Merge develop branch into release.
  • Create a git tag for release candidate. (for example "1.0.0-rc1")
  • From now only fixes can be commited/merged into the release branch
  • After a week of usage and tests, update the version by removing -rcX suffix.
  • Merge release into main.
  • Create tag for released version. (for example "1.0.0")
  • Draft a new release. (See https://github.com/ripple/xbridge_witness/releases)

Additional documentation

Minimum Requirements

Compiler Version
GCC 11
Clang 13
Apple clang 15

Build and run

  1. Create a build directory and cd into it.
mkdir .build && cd .build
  1. Configure Conan.

Add Ripple's Artifactory as a Conan remote to source the libxrpl Conan package.

conan remote add --insert 0 conan-non-prod http://18.143.149.228:8081/artifactory/api/conan/conan-non-prod
Optional local development of xrpl library

The Conan xrpl recipe is also available by checking out the rippled source and exporting the recipe locally.

git clone https://github.com/XRPLF/rippled.git
cd rippled 
conan export .
conan profile update settings.cppstd=20 default
conan profile update settings.compiler.libcxx=libstdc++11 default

Example Conan profiles

Linux

  [settings]
  arch=x86_64
  arch_build=x86_64
  os=Linux
  os_build=Linux
  build_type=Release
  compiler=gcc
  compiler.cppstd=20
  compiler.libcxx=libstdc++11
  compiler.version=11

macOS

On macOS you may get an error from Boost which requires adding some CMake flags to your Conan profile.

conan profile update 'env.CXXFLAGS="-DBOOST_ASIO_DISABLE_CONCEPTS"' default
conan profile update 'conf.tools.build:cxxflags+=["-DBOOST_ASIO_DISABLE_CONCEPTS"]' default
[settings]
os=Macos
os_build=Macos
arch=armv8
arch_build=armv8
compiler=apple-clang
compiler.version=15
build_type=Release
compiler.cppstd=20
compiler.libcxx=libc++
[options]
[conf]
tools.build:cxxflags=['-DBOOST_ASIO_DISABLE_CONCEPTS']
[build_requires]
[env]
CXXFLAGS=-DBOOST_ASIO_DISABLE_CONCEPTS
  1. Run Conan to install and/or build dependencies.
conan install .. \
  --output-folder . \
  --build missing \
  --settings build_type=Release
  1. Configure CMake.
cmake .. \
  -DCMAKE_BUILD_TYPE=Release \
  -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake
  1. Build with CMake.
cmake --build --parallel $(nproc)
  1. Run the unit tests.
./xbridge_witnessd --unittest

Check the documentation for configuration examples.

Additional help

Additional help for Conan/CMake issues may be found in rippled's build instructions.

Feel free to open an issue if you have a feature request or something doesn't work as expected.