Knot Resolver is written for UNIX-like systems using modern C standards.
Beware that some 64-bit systems with LuaJIT 2.1 may be affected by
a problem
– Linux on x86_64 is unaffected but Linux on aarch64 is.

On reasonably new systems most of the dependencies can be resolved from packages,
here’s an overview for several platforms.

Debian/Ubuntu - Current stable doesn’t have new enough Meson
and libknot. Use repository above or build them yourself. Fresh list of dependencies can be found in Debian control file in our repo, search for “Build-Depends”.

CentOS/Fedora/RHEL/openSUSE - Fresh list of dependencies can be found in RPM spec file in our repo, search for “BuildRequires”.

FreeBSD - when installing from ports, all dependencies will install
automatically, corresponding to the selected options.

It’s possible to change the compilation with build options. These are useful to
packagers or developers who wish to customize the daemon behaviour, run
extended test suites etc. By default, these are all set to sensible values.

For complete list of build options create a build directory and run:

$ meson build_dir
$ meson configure build_dir

To customize project build options, use -Doption=value when creating
a build directory:

The following command runs all enabled tests. By default, only unit tests are enabled.

$ ninja -C build_dir
$ meson test -C build_dir

More comprehensive tests require you to install kresd into the configured
prefix before running the test suite. They also have to be explicitly enabled
by using either -Dconfig_tests=enabled for postinstall config tests, or
-Dextra_tests=enabled for all tests, including deckard tests. Please note
the latter also requires -Dsendmmsg=disabled.

If the target distro has externally managed (read-only) DNSSEC trust anchors
or root hints use this:

-Dkeyfile_default=/usr/share/dns/root.key

-Droot_hints=/usr/share/dns/root.hints

-Dmanaged_ta=disabled

In case you want to have automatically managed DNSSEC trust anchors instead,
set -Dmanaged_ta=enabled and make sure both keyfile_default file and
its parent directories are writable by kresd process (after package installation!).