Files
BMLFS/build-scripts/aom.build
2024-08-09 11:58:03 -05:00

61 lines
1.9 KiB
Bash

#! /bin/bash
# AOM
# Source: https://storage.googleapis.com/aom-releases/libaom-3.9.1.tar.gz
#
# $BUILD = Directory to temporarily install
# $PKGS = Directory to store built packages
#
# DEPS
# Required: CMake, yasm
# Recommended: NONE
# Optional: NONE
#
# Source does not unpack into a directory
#patch -Np1 -i ../patches/aom-alpine/fix-stack-size-e53da0b.patch
case $(uname -m) in
arm*) export ECONF="-DENABLE_NEON=OFF" ;;
esac &&
mkdir BUILD && cd BUILD &&
# If building with clang-17, add flags:
CFLAGS="-Wno-implicit-function-declaration " \
cmake -DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DBUILD_SHARED_LIBS=True \
-DENABLE_NASM=ON \
-DENABLE_TESTS=OFF \
-DCMAKE_BUILD_TYPE=Release $ECONF ..
read -p "Compile?" && make -j2 &&
unset ECONF &&
sudo -S make DESTDIR=$BUILD install &&
cd $BUILD && sudo -S mkdir -v ${BUILD}/install &&
cat > /tmp/slack-desc << "EOF"
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':' except on otherwise blank lines.
|-----handy-ruler------------------------------------------------------|
aom: aom (Open Source Video Codec)
aom:
aom: AOMedia Video 1 (AV1) is designed to be the successor to VP9 and
aom: also to eventually be a direct competitor for HEVC/H.265.
aom: This Slackbuild builds the 'reference' encoder aomenc as well as
aom: the 'reference' decoder aomdec.
aom:
aom: Homepage: https://aomedia.googlesource.com/aom
aom:
aom:
aom:
EOF
sudo -S mv -v /tmp/slack-desc install/ &&
sudo -S makepkg -l y -c n $PKGS/aom-3.9.1-$PSUFFIX &&
sudo -S rm -rf ${BUILD}/*