summaryrefslogtreecommitdiff
path: root/media-libs/libavif
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-09-30 17:27:54 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-09-30 17:27:54 +0100
commitf70a1bfc721336d4fc7dfb711c2f518a6b18cf16 (patch)
treee907cb121b30e3c1df1710719c0ddf4029597a47 /media-libs/libavif
parentdb063b515939ab15261136b24e4bc44386335c0c (diff)
gentoo resync : 30.09.2020
Diffstat (limited to 'media-libs/libavif')
-rw-r--r--media-libs/libavif/Manifest4
-rw-r--r--media-libs/libavif/libavif-0.8.1.ebuild73
-rw-r--r--media-libs/libavif/libavif-9999.ebuild73
-rw-r--r--media-libs/libavif/metadata.xml23
4 files changed, 173 insertions, 0 deletions
diff --git a/media-libs/libavif/Manifest b/media-libs/libavif/Manifest
new file mode 100644
index 000000000000..d6333be538eb
--- /dev/null
+++ b/media-libs/libavif/Manifest
@@ -0,0 +1,4 @@
+DIST libavif-0.8.1.tar.gz 2915941 BLAKE2B 40030a5a002e68231adf48ecc6e8012f7ec53506770872fc79dfd73496fa3a214c10cf5fb5826f145fe1f881adf2a3ecca13c33989b2f048aa72e455ab6950e0 SHA512 03692fbba49fde08d76cebb847d0404a81113824e9e65edc6a0977f323d060c394d111e2a7647788fa3115f3ae80b0fc92d4fe5be53852e6734b96a8f1c1a078
+EBUILD libavif-0.8.1.ebuild 1659 BLAKE2B 67a47e9825f0372ac63c63c3995e21f9de3fd7c678a8ea509cf1fd474165ba5de133532e3e30c6786178622bdedfa311e692cd5c0a4ab5798694e50f59b44765 SHA512 69bfed41583ee92e65078db7a63ba01012722c0b064949999bfe33e1284a1842e1e2d8a32d75222fb3b6598ba844db5bc515d56c90f80f0db26605502d4549a6
+EBUILD libavif-9999.ebuild 1616 BLAKE2B 6fd97427b007b3ef0e892505eafd538cfd7eb13879fa6d5817608e4dfb027983b283b830b8a5a6fdaad10e764a3281f41a5a382286e27ffaa8db530d5f776749 SHA512 80003f7397e70ce3a50281c508fe43c96745a0c24b316a6f2f9b4abbfd6ff4312c2c3edf506d9325c5732c8ed379b050b503a9124ed62a4f3dcd6cf1c0d3bfc8
+MISC metadata.xml 887 BLAKE2B 07dd6586bb1553346742120a8a79e89df0df54b7d88673f2b05e04523ba9158dc1bb8ce43fe4202eabc053e039d44db886f2ddb22047cc76e240cd917313adc3 SHA512 ad588808bf4fbfb7065053a5178df233a106b4dd57191aab3439b620238aca08370099f2618c21126a0358c7100f572b499461eddb01770b8a270aed43e82a91
diff --git a/media-libs/libavif/libavif-0.8.1.ebuild b/media-libs/libavif/libavif-0.8.1.ebuild
new file mode 100644
index 000000000000..4d120a5e644b
--- /dev/null
+++ b/media-libs/libavif/libavif-0.8.1.ebuild
@@ -0,0 +1,73 @@
+# Copyright 2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake gnome2-utils
+
+DESCRIPTION="Library for encoding and decoding .avif files"
+HOMEPAGE="https://github.com/AOMediaCodec/libavif"
+SRC_URI="https://github.com/AOMediaCodec/libavif/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+IUSE="+aom dav1d examples extras gdk-pixbuf rav1e"
+
+DEPEND="media-libs/libpng
+ sys-libs/zlib
+ virtual/jpeg
+ aom? ( >=media-libs/libaom-2.0.0 )
+ dav1d? ( media-libs/dav1d )
+ gdk-pixbuf? ( x11-libs/gdk-pixbuf:2 )
+ rav1e? ( media-video/rav1e[capi] )"
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+REQUIRED_USE="|| ( aom dav1d )"
+
+src_configure() {
+ local mycmakeargs=(
+ -DBUILD_SHARED_LIBS=ON
+ -DAVIF_CODEC_AOM=$(usex aom ON OFF)
+ -DAVIF_CODEC_DAV1D=$(usex dav1d ON OFF)
+ -DAVIF_CODEC_LIBGAV1=OFF
+ -DAVIF_CODEC_RAV1E=$(usex rav1e ON OFF)
+
+ # Use system libraries.
+ -DAVIF_LOCAL_ZLIBPNG=OFF
+ -DAVIF_LOCAL_JPEG=OFF
+
+ -DAVIF_BUILD_EXAMPLES=$(usex examples ON OFF)
+ -DAVIF_BUILD_APPS=$(usex extras ON OFF)
+ -DAVIF_BUILD_TESTS=$(usex extras ON OFF)
+
+ -DAVIF_BUILD_GDK_PIXBUF=$(usex gdk-pixbuf ON OFF)
+ )
+
+ cmake_src_configure
+}
+
+pkg_preinst() {
+ if use gdk-pixbuf ; then
+ gnome2_gdk_pixbuf_savelist
+ fi
+}
+
+pkg_postinst() {
+ if ! use aom && ! use rav1e ; then
+ ewarn "aom and rav1e flags are not set,"
+ ewarn "libavif will work in read-only mode."
+ ewarn "Enable aom or rav1e flag if you want to save .AVIF files."
+ fi
+
+ if use gdk-pixbuf ; then
+ gnome2_gdk_pixbuf_update
+ fi
+}
+
+pkg_postrm() {
+ if use gdk-pixbuf ; then
+ gnome2_gdk_pixbuf_update
+ fi
+}
diff --git a/media-libs/libavif/libavif-9999.ebuild b/media-libs/libavif/libavif-9999.ebuild
new file mode 100644
index 000000000000..ffaba14b1959
--- /dev/null
+++ b/media-libs/libavif/libavif-9999.ebuild
@@ -0,0 +1,73 @@
+# Copyright 2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake git-r3 gnome2-utils
+
+DESCRIPTION="Library for encoding and decoding .avif files"
+HOMEPAGE="https://github.com/AOMediaCodec/libavif"
+EGIT_REPO_URI="https://github.com/AOMediaCodec/libavif.git"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS=""
+IUSE="+aom dav1d examples extras gdk-pixbuf rav1e"
+
+DEPEND="media-libs/libpng
+ sys-libs/zlib
+ virtual/jpeg
+ aom? ( >=media-libs/libaom-2.0.0 )
+ dav1d? ( media-libs/dav1d )
+ gdk-pixbuf? ( x11-libs/gdk-pixbuf:2 )
+ rav1e? ( media-video/rav1e[capi] )"
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+REQUIRED_USE="|| ( aom dav1d )"
+
+src_configure() {
+ local mycmakeargs=(
+ -DBUILD_SHARED_LIBS=ON
+ -DAVIF_CODEC_AOM=$(usex aom ON OFF)
+ -DAVIF_CODEC_DAV1D=$(usex dav1d ON OFF)
+ -DAVIF_CODEC_LIBGAV1=OFF
+ -DAVIF_CODEC_RAV1E=$(usex rav1e ON OFF)
+
+ # Use system libraries.
+ -DAVIF_LOCAL_ZLIBPNG=OFF
+ -DAVIF_LOCAL_JPEG=OFF
+
+ -DAVIF_BUILD_EXAMPLES=$(usex examples ON OFF)
+ -DAVIF_BUILD_APPS=$(usex extras ON OFF)
+ -DAVIF_BUILD_TESTS=$(usex extras ON OFF)
+
+ -DAVIF_BUILD_GDK_PIXBUF=$(usex gdk-pixbuf ON OFF)
+ )
+
+ cmake_src_configure
+}
+
+pkg_preinst() {
+ if use gdk-pixbuf ; then
+ gnome2_gdk_pixbuf_savelist
+ fi
+}
+
+pkg_postinst() {
+ if ! use aom && ! use rav1e ; then
+ ewarn "aom and rav1e flags are not set,"
+ ewarn "libavif will work in read-only mode."
+ ewarn "Enable aom or rav1e flag if you want to save .AVIF files."
+ fi
+
+ if use gdk-pixbuf ; then
+ gnome2_gdk_pixbuf_update
+ fi
+}
+
+pkg_postrm() {
+ if use gdk-pixbuf ; then
+ gnome2_gdk_pixbuf_update
+ fi
+}
diff --git a/media-libs/libavif/metadata.xml b/media-libs/libavif/metadata.xml
new file mode 100644
index 000000000000..31ef145a4ce5
--- /dev/null
+++ b/media-libs/libavif/metadata.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>juippis@gentoo.org</email>
+ <name>Joonas Niilola</name>
+ </maintainer>
+ <maintainer type="person">
+ <email>dnovomesky@gmail.com</email>
+ <name>Daniel Novomesky</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+ <use>
+ <flag name="aom">Enable support for the AOM codec encoding and decoding</flag>
+ <flag name="dav1d">Enable support for the dav1d codec decoding</flag>
+ <flag name="extras">Build extra apps (avifenc, avifdec) and test files</flag>
+ <flag name="gdk-pixbuf">Build a gdk-pixbuf loader</flag>
+ <flag name="rav1e">Enable support for the rav1e codec encoding</flag>
+ </use>
+</pkgmetadata>