NOTE: This commit only tested on Linux (Ubuntu 18.04). Windows build may not work as expected. * Use meson >= 0.47.0 cause we use install_man function * Add three helper Python script: * CopyFile.py: To copy file * CreateSymlink.py: To make symlink (both Windows and Unix) * GetZstdLibraryVersion.py: Parse lib/zstd.h to get zstd version These help emulating equivalent functions in CMake and Makefile. * Use subdir from meson to split meson.build * Add contrib build * Fix other build * Add new build options * build_programs: Enable programs build * build_contrib: Enable contrib build * build_tests: Enable tests build * use_static_runtime: Link to static run-time libraries on MSVC * zlib_support: Enable zlib support * lzma_support: Enable lzma support
This Meson project is provided with no guarantee and maintained by Dima Krasner dima@dimakrasner.com.
It outputs one libzstd
, either shared or static, depending on
default_library
option.
How to build
cd
to this meson directory (zstd/contrib/meson
) and type:
meson --buildtype=release --strip --prefix=/usr builddir
cd builddir
ninja # to build
ninja install # to install
You might want to install it in staging directory:
DESTDIR=./staging ninja install
To configure the build, use:
meson configure
See man meson(1).