-
Notifications
You must be signed in to change notification settings - Fork 100
Build
The software is hosted at GitHub under: https://github.com/fraunhoferhhi/vvdec
To clone the project use:
git clone https://github.com/fraunhoferhhi/vvdec
The software uses CMake to create platform-specific build files. A working CMake installation is required for building the software. Download CMake from http://www.cmake.org/ and install it.
The following targets are supported: Windows (Visual Studio), Linux (gcc) and MacOS (clang).
In order to compile the software the following software is needed to build VVdeC:
- CMake 3.13 or higher
- Linux: gcc-5.0 or higher
- MacOS: Xcode (for arm based devices(M1,m2) ninja build is needed)
- Windows: Visual Studio 15 2017 or higher
- Windows: gnuwin32 ( to provide make for Windows)
To simplify the build process a Makefile with predefined targets is available.
Please be aware of that the Makefile is only a frontend to CMake.
To build the VVdeC decoder applications open a terminal and change into the project directory.
-
build statically linked release version:
make release
-
build statically linked debug version:
make debug
-
build dynamically linked debug version:
make debug-shared
-
create statically linked release version and install local to 'install':
make install-release
ormake install-r
-
create statically linked release version and install to default system location '/usr/local'):
sudo make install-release install-prefix=/usr/local
-
create dynamically linked release version and install to default system location '/usr/local'):
sudo make install-release-shared install-prefix=/usr/local
-
clean all build files:
make realclean
To see all available commands and aliases check the Makefile
Open a command prompt on your system and change into the root directory of this project.
Use one of the following CMake commands to configure the project. Feel free to change the commands to satisfy your needs
-
Linux Release static sample:
cmake -S . -B build/release-static -DCMAKE_BUILD_TYPE=Release
-
Linux Debug static sample:
cmake -S . -B build/debug-static -DCMAKE_BUILD_TYPE=Debug
-
MacOS-X Xcode sample:
cmake -S . -B build/release-static -DCMAKE_BUILD_TYPE=Release -G "Xcode"
-
Windows sample:
cmake -S . -B build/release-static -DCMAKE_BUILD_TYPE=Release -G "Visual Studio 15 2017 Win64"
After the configure step build the project:
-
build release static:
cmake --build build/release-static -j
-
install (locally):
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build/release-shared -j
cmake --build build/release-static --target install
-
install into system( e.g. /usr/local):
cmake -S . -B build/release-shared -DCMAKE_INSTALL_PREFIX=/usr/local -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=1
cmake --build build/release-shared -j
cmake --build build/release-shared --target install
Attention:
The sample application vvdecapp
is not installed by default anymore.
To install the application use -DVVDEC_INSTALL_VVDECAPP=ON
in cmake (install-vvdecapp=1
for make)
- clean project:
rm -rf build bin lib install
The top-level CMakeLists.txt contains some special build options that can be used for the build process. Some of the major options for makefile or plain cmake can be found in the following table:
CMake option | Makefile option | Default | Description |
---|---|---|---|
CMAKE_VERBOSE_MAKEFILE | verbose | Off | set cmake verbose mode |
CMAKE_INSTALL_PREFIX | install-prefix | - | set install location |
CMAKE_TOOLCHAIN_FILE | toolchainfile | - | set special toolchain file (e.g. minGW) |
VVDEC_INSTALL_VVDECAPP | install-vvdecapp | Off | install vvdecapp (default: library and headers only) |
VVDEC_ENABLE_LINK_TIME_OPT | disable-lto | Off (LTO On) | use link time optimization |
VVDEC_OPT_TARGET_ARCH | enable-arch | - | set architecture specific optimization |
VVDEC_ENABLE_X86_SIMD | On | enable optimzed SIMD code (also on non-x86 through SIMDe) | |
VVDEC_ENABLE_BUILD_TYPE_POSTFIX | enable-build-type-postfix | Off | set build type postfix for apps and libs |
VVDEC_ENABLE_BITSTREAM_DOWNLOAD | enable-bitstream-download | Off | download conformance bitstreams for testing |
VVDEC_ENABLE_WERROR | enable-werror | On | instructs the build process to fail if any warning are encountered |
Example using Makefile:
make release verbose=1 disable-lto=1 toolchainfile=cmake/toolchains/x86_64-w64-mingw32-gcc-posix-ubuntu2004.cmake
Example using CMake:
cmake -S . -B build/release-static -DCMAKE_VERBOSE_MAKEFILE=ON -DVVENC_ENABLE_LINK_TIME_OPT=OFF \
-DCMAKE_TOOLCHAIN_FILE=cmake/toolchains/x86_64-w64-mingw32-gcc-posix-ubuntu2004.cmake -DCMAKE_BUILD_TYPE=Release
If you are having trouble building or running VVdeC on architectures other than the officially supported ones, try setting -DVVDEC_ENABLE_X86_SIMD=OFF
.
The software contains a simple test-suite testing the decoder conformance against the official set of conformance test sequences 1. To run the test-suite, the project must be built enabling the download of the test-sequences:
make <target> enable-bitstream-download=1
The actual test can then be run by calling:
make test-all
SIMDe is a fast and portable implementation of SIMD intrinsics on hardware which doesn't natively support them, such as calling SSE functions on ARM.
The external library is available under MIT license at https://github.com/simd-everywhere/simde.
Please see COPYING for the terms of use of the contents of this library.
- [1] J. Boyce, E. Alshina, F. Bossen, K. Kawamura, I. Moccagatta, and W. Wan, “Conformance testing for versatile video coding (Draft 6),” document JVET-U2008, Joint Video Experts Team (JVET), Jan. 2021.