+# Copyright © 2020 Nick Bowler
+# License GPLv3+: GNU General Public License version 3 or any later version.
+# This is free software: you are free to change and redistribute it.
+# There is NO WARRANTY, to the extent permitted by law.
+
+EAPI=7
+
+inherit meson toolchain-funcs gnome2-utils multilib-minimal
+
+MY_PN=webp-pixbuf-loader
+MY_P=$MY_PN-$PV
+
+DESCRIPTION="WebP loader for GdkPixbuf"
+HOMEPAGE="https://github.com/aruiz/webp-pixbuf-loader/"
+SRC_URI="https://github.com/aruiz/webp-pixbuf-loader/archive/0.0.1.tar.gz -> $MY_P.tar.gz"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="media-libs/libwebp:=[$MULTILIB_USEDEP]
+ x11-libs/gdk-pixbuf[$MULTILIB_USEDEP]"
+DEPEND=$RDEPEND
+
+S=$WORKDIR/$MY_P
+
+multilib_src_configure () {
+ meson_src_configure
+}
+
+multilib_src_compile () {
+ meson_src_compile
+}
+
+multilib_src_install () {
+ local pkgconf=`tc-getPKG_CONFIG`
+ local moduledir=`$pkgconf --variable=gdk_pixbuf_moduledir gdk-pixbuf-2.0`
+
+ exeinto "$moduledir"
+ doexe libpixbufloader-webp.so
+}
+
+pkg_preinst () {
+ gnome2_gdk_pixbuf_savelist
+}
+
+pkg_postrm () {
+ gnome2_gdk_pixbuf_update
+}
+
+pkg_postinst () {
+ gnome2_gdk_pixbuf_update
+}