Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add build command lines to README.md #1924

Merged
merged 3 commits into from
Jan 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,39 @@ The remaining tests can be built by enabling the `AVIF_BUILD_TESTS` and
`AVIF_ENABLE_GTEST` CMake options. They require GoogleTest to be built locally
with ext/googletest.cmd or installed on the system.

### Command Lines

The following instructions can be used to build the libavif library and the
`avifenc` and `avifdec` tools.

#### Build using installed dependencies

To link against the already installed `aom`, `libjpeg` and `libpng` dependency
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest also adding the libsharpyuv-dev package: https://packages.debian.org/search?keywords=libsharpyuv-dev

I wrote #1937 to add libsharpyuv to the "Build everything from scratch" section.

libraries (recommended):

```sh
git clone -b v1.0.3 https://github.com/AOMediaCodec/libavif.git
cd libavif
cmake -S . -B build -DAVIF_CODEC_AOM=SYSTEM -DAVIF_BUILD_APPS=ON
cmake --build build --parallel
```

#### Build everything from scratch

For development and debugging purposes, or to generate fully static binaries:

```sh
git clone -b v1.0.3 https://github.com/AOMediaCodec/libavif.git
cd libavif/ext
./aom.cmd
./libyuv.cmd
./libjpeg.cmd
./zlibpng.cmd
cd ..
cmake -S . -B build -DBUILD_SHARED_LIBS=OFF -DAVIF_CODEC_AOM=LOCAL -DAVIF_LIBYUV=LOCAL -DAVIF_LOCAL_JPEG=ON -DAVIF_LOCAL_ZLIBPNG=ON -DAVIF_BUILD_APPS=ON
cmake --build build --parallel
```

## Prebuilt Library (Windows)

If you're building on Windows with Visual Studio 2022 and want to try out
Expand Down
Loading