To build from the sources, first you'll need to fork and clone the repository from GitHub. Once you have a local copy, procede with the building process.

Requirements

Xapiand is written in C++14, it makes use of libev (which is included in the codebase), it has the following build requirements:

Dependencies

The only external dependencies for building it are:

Building process

Get the Sources

First download and untar the Xapiand official distribution or clone the repository from https://github.com/Kronuz/Xapiand.git

~/ $ git clone -b master --single-branch --depth 1 \
  "https://github.com/Kronuz/Xapiand.git"

Prepare the Build

~/ $ cd Xapiand
~/Xapiand $ mkdir build
~/Xapiand $ cd build

Configure the Build

~/Xapiand/build $ cmake -GNinja ..

Build, Test and Install

~/Xapiand/build $ ninja
~/Xapiand/build $ ninja check
~/Xapiand/build $ ninja install

Notes


#### Address Sanitizer (ASAN)

* For developing and debugging, generally you'd want to enable the
  *Address Sanitizer*, tracebacks in exceptions and debugging symbols,
  so you'll have to **Configure the Build** using something like:
    ```sh
~/Xapiand/build $ brew switch xapian ASAN
~/Xapiand/build $ cmake -GNinja -DASAN=ON -DCMAKE_BUILD_TYPE=Debug -DTRACEBACKS=ON ..

Thread Sanitizer (TSAN)

macOS specifics

  1. Simply installing Xcode will not install all of the command line developer tools, the first time you must execute xcode-select --install in Terminal before trying to build.

  2. You need CMake installed brew install cmake.