Skip to content

Latest commit

 

History

History
42 lines (29 loc) · 1.2 KB

Build_zstd.md

File metadata and controls

42 lines (29 loc) · 1.2 KB

Building zstd

Generate the binary by following the steps below, and copy it to the External/zstd/lib folder depending on the platform.

Windows

  1. Install the following Visual Studio 2017 components:

    • Windows SDK 8.1
    • Windows Universal CRT SDK
  2. Download zstd v1.5.2 and extract to a folder.

  3. Go to where zstd was extracted and execute the following:

$ cd build\VS2010
$ devenv zstd.sln /upgrade
$ msbuild zstd.sln /p:Configuration=Release /p:Platform=x64

Mac

  1. Install Homebrew
  2. Install zstd via Homebrew and confirm that its version is 1.5.2.
    $ brew install zstd
    $ zstd --version
    

libzstd.a will be installed under /opt/homebrew/Cellar/zstd/1.5.2/lib folder by default.

Linux

  1. Download zstd v1.5.2 and extract to a folder.
  2. Go to where zstd was extracted and execute the following:
$ cd build/cmake
$ cmake . -DCMAKE_POSITION_INDEPENDENT_CODE=ON && cmake --build .

libzstd.a will be generated under build/cmake/lib folder