summaryrefslogtreecommitdiffstats
path: root/libraries/libavif
diff options
context:
space:
mode:
author Vijay Marcel <vijaymarcel@outlook.com>2023-01-06 15:35:16 +0000
committer Willy Sudiarto Raharjo <willysr@slackbuilds.org>2023-01-07 08:13:38 +0700
commitd188f67b8401a800643ece4342d51e24c8d1e0d7 (patch)
tree532ff19ff1923b1191c5ba978a0a25bb93127ff6 /libraries/libavif
parentf8eb8867ee26ab481e906477ac5f32302ecf2095 (diff)
downloadslackbuilds-d188f67b8401a800643ece4342d51e24c8d1e0d7.tar.gz
slackbuilds-d188f67b8401a800643ece4342d51e24c8d1e0d7.tar.xz
libraries/libavif: Updated for version 20221216_93035c1.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'libraries/libavif')
-rw-r--r--libraries/libavif/README21
-rw-r--r--libraries/libavif/changelog22
-rw-r--r--libraries/libavif/libavif.SlackBuild53
-rw-r--r--libraries/libavif/libavif.info6
4 files changed, 96 insertions, 6 deletions
diff --git a/libraries/libavif/README b/libraries/libavif/README
index c51c31dd2b..ae08322017 100644
--- a/libraries/libavif/README
+++ b/libraries/libavif/README
@@ -1,3 +1,24 @@
This library aims to be a portable C implementation of
AV1 image file format.It can encode and decode all AOM
supported YUV formats and bit depths.
+
+It builds an decoder avifdec and encoder avifenc.
+avifdec can convert from avif to jpeg or png image.
+avifenc can encode jpeg or png to avif image.
+
+usage:
+-------
+
+avifdec [-options] input.avif output.jpeg|jpeg|png|y4m
+
+avifdec -h will show help
+
+avifenc [-options] input.jpg|jpeg|png|y4m output.avif
+
+avifenc -h will show help
+
+Note For 32-bit users:
+-----------------------
+
+Pandoc is an optional dependency since man pages
+are disabled by default for 32-bit users.
diff --git a/libraries/libavif/changelog b/libraries/libavif/changelog
new file mode 100644
index 0000000000..793fcf0ae4
--- /dev/null
+++ b/libraries/libavif/changelog
@@ -0,0 +1,22 @@
+Changelog for libavif slackbuild script
+--------------------------------------------------------------------
+
+01/10/2022:
+
+Added to slackbuilds.org
+
+06/01/2023:
+
+Updated README
+Updated to github commit 93035c1
+
+Pandoc is used by libavif to build manpages. If you don't need
+manpages don't install pandoc and change the appropriate
+build option.
+
+For x86 architecture pandoc will be an optional dependency.
+pandoc needs to be built from sources for x86 architecture
+since it takes much time to build, I'm not building
+the manpages by default. If you need manpages
+install pandoc and then customize the slackbuild script by
+changing the build option for manpages from OFF to ON.
diff --git a/libraries/libavif/libavif.SlackBuild b/libraries/libavif/libavif.SlackBuild
index 7b3872614f..047e9ed350 100644
--- a/libraries/libavif/libavif.SlackBuild
+++ b/libraries/libavif/libavif.SlackBuild
@@ -25,11 +25,11 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=libavif
-VERSION=${VERSION:-20220922_d0f2fee}
+VERSION=${VERSION:-20221216_93035c1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
-GITNAM=${GITNAM:-d0f2fee5e879c003d2860971b41433a69cb2170d}
+GITNAM=${GITNAM:-93035c173c934813b16751872fbe2f535aa7086b}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -82,11 +82,16 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+
+if [ "$ARCH" = "x86_64" ]; then
+
+echo "Builing for x86_64 Architecture"
+
cmake -B build -S $TMP/$PRGNAM-$GITNAM \
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
-DBUILD_SHARED_LIBS:BOOL=ON \
- -DAVIF_ENABLE_WERROR:BOOL=OFF \
+ -DAVIF_ENABLE_WERROR:BOOL=ON \
-DAVIF_CODEC_AOM:BOOL=ON \
-DAVIF_CODEC_AOM_DECODE:BOOL=ON \
-DAVIF_CODEC_AOM_ENCODE:BOOL=ON \
@@ -115,6 +120,48 @@ find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | gr
find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
+elif [ "$ARCH" = "i586" ]; then
+
+echo "Builing for x86 Architecture"
+echo "No man pages will be built for x86 architecture, Refer README and changelog for details"
+echo "If you need Man Pages for x86 architecture you have to build pandoc from sources"
+
+cmake -B build -S $TMP/$PRGNAM-$GITNAM \
+ -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
+ -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
+ -DBUILD_SHARED_LIBS:BOOL=ON \
+ -DAVIF_ENABLE_WERROR:BOOL=ON \
+ -DAVIF_CODEC_AOM:BOOL=ON \
+ -DAVIF_CODEC_AOM_DECODE:BOOL=ON \
+ -DAVIF_CODEC_AOM_ENCODE:BOOL=ON \
+ -DAVIF_CODEC_DAV1D:BOOL=ON \
+ -DAVIF_CODEC_LIBGAV1:BOOL=OFF \
+ -DAVIF_CODEC_RAV1E:BOOL=OFF \
+ -DAVIF_CODEC_SVT:BOOL=ON \
+ -DAVIF_BUILD_APPS:BOOL=ON \
+ -DAVIF_BUILD_TESTS:BOOL=OFF \
+ -DAVIF_ENABLE_GTEST:BOOL=OFF \
+ -DAVIF_BUILD_MAN_PAGES:BOOL=OFF \
+ -DCMAKE_INSTALL_PREFIX:PATH=/usr \
+ -DCMAKE_INSTALL_LIBDIR:PATH=/usr/lib${LIBDIRSUFFIX} \
+ -DCMAKE_INSTALL_BINDIR:PATH=/usr/bin \
+ -DCMAKE_INSTALL_MANDIR=/usr/man \
+ -DCMAKE_BUILD_TYPE=Release
+
+make -C build
+make -C build install DESTDIR=$PKG
+
+rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la
+
+find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+
+else
+
+echo "Unsupported Architecture, Aborting the build process ....."
+
+fi
+
find $PKG -name perllocal.pod -o -name ".packlist" -o -name "*.bs" | xargs rm -f || true
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
diff --git a/libraries/libavif/libavif.info b/libraries/libavif/libavif.info
index f8347e9537..26ab8d6cb2 100644
--- a/libraries/libavif/libavif.info
+++ b/libraries/libavif/libavif.info
@@ -1,8 +1,8 @@
PRGNAM="libavif"
-VERSION="20220922_d0f2fee"
+VERSION="20221216_93035c1"
HOMEPAGE="https://github.com/AOMediaCodec/libavif"
-DOWNLOAD="https://github.com/AOMediaCodec/libavif/archive/d0f2fee/libavif-d0f2fee5e879c003d2860971b41433a69cb2170d.tar.gz"
-MD5SUM="ecf67adb5311da2554183dcc6cb59a67"
+DOWNLOAD="https://github.com/AOMediaCodec/libavif/archive/93035c1/libavif-93035c173c934813b16751872fbe2f535aa7086b.tar.gz"
+MD5SUM="4788b4ca1eee83b3350fd7a61c4209cd"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="aom dav1d svt-av1 libyuv pandoc-bin"