Linux native compilation
Check out the source code using git:
git clone https://code.videolan.org/videolan/dav1d.git
Change to the dav1d directory and configure the build with meson:
cd dav1d meson build
To compile it, change to the
build directory and run ninja:
cd build ninja
Windows native compilation
Install msys2, follow the instructions on the page.
Open a mingw64 msys2 shell and install the required packages:
pacman -S git mingw-w64-x86_64-meson mingw-w64-x86_64-ninja gcc nasm
Then follow the Linux native compilation steps.
To run the tests, such as checkasm, use the meson test subcommand from the build dir:
meson test -v
The dav1d build has some options to change aspects of the build, additionally meson provides a number of convenient options too. These options can either be set on an already configure build by invoking
meson configure -Doption_name=value in the build dir or by passing them on the initial meson command that configures the build dir.
meson configure in the build dir shows the current configuration state. After changing a value, meson will automatically reconfigure as necessary on next ninja invocation.
Some useful meson options:
buildtype: Change the build type (
prefix: Change the prefix where dav1d will be installed
b_sanitize: Enable a sanitizer (
default_library: Change if a
staticlibrary should be built or
c_link_args=...to pass custom