Building xNVMe#

xNVMe builds and runs on Linux, FreeBSD and Windows. First, retrieve the xNVMe repository from GitHUB:

# Clone the xNVMe repos into the folder 'xnvme'
git clone xnvme


The xNVMe build-system uses meson/ninja and its subproject-feature with wraps, dependencies such as fio, libvfn, and SPDK are fetched by the build-system (meson), not as previously done via git-submodules.

Before you invoke the compilation, then ensure that you have the compiler, tools, and libraries needed. The Toolchain section describes what to install, and how, on rich a selection of Linux distributions, FreeBSD and Windows. For example on Debian do:

sudo ./xnvme/toolbox/pkgs/

With the source available, and toolchain up and running, then go ahead:

cd xnvme

# configure xNVMe and build dependencies (fio, libvfn, and SPDK/NVMe)
meson setup builddir
cd builddir

# build xNVMe
meson compile

# install xNVMe
meson install

# uninstall xNVMe
# meson --internal uninstall


Details on the build-errors can be seen by inspecting builddir/meson-logs/meson-log.txt.


In case you ran the meson-commands before installing, then you probably need to remove your builddir before re-running build commands.

In case you want to customize the build, e.g. install into a different location etc. then this is all handled by meson built-in options, in addition to those, then you can inspect meson_options.txt which contains build-options specific to xNVMe. Otherwise, with a successfully built and installed xNVMe, then jump to System Config and Building an xNVMe Program.