summaryrefslogtreecommitdiff
path: root/media-libs/giflib
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /media-libs/giflib
reinit the tree, so we can have metadata
Diffstat (limited to 'media-libs/giflib')
-rw-r--r--media-libs/giflib/Manifest16
-rw-r--r--media-libs/giflib/files/giflib-4.1.6-gif2rle.patch18
-rw-r--r--media-libs/giflib/files/giflib-4.1.6-giffix-null-Extension-fix.patch15
-rw-r--r--media-libs/giflib/giflib-4.1.6-r2.ebuild56
-rw-r--r--media-libs/giflib/giflib-4.1.6-r3.ebuild58
-rw-r--r--media-libs/giflib/giflib-4.2.3-r1.ebuild58
-rw-r--r--media-libs/giflib/giflib-5.0.6.ebuild49
-rw-r--r--media-libs/giflib/giflib-5.1.3.ebuild53
-rw-r--r--media-libs/giflib/giflib-5.1.4.ebuild71
-rw-r--r--media-libs/giflib/metadata.xml14
10 files changed, 408 insertions, 0 deletions
diff --git a/media-libs/giflib/Manifest b/media-libs/giflib/Manifest
new file mode 100644
index 000000000000..b959aaae0946
--- /dev/null
+++ b/media-libs/giflib/Manifest
@@ -0,0 +1,16 @@
+AUX giflib-4.1.6-gif2rle.patch 764 SHA256 1a8772dea005ff557ebfeca06837ae77bd0728d397691ad19b2bb768530b3965 SHA512 6714906d49a0c285c1fb642a81c092378042ec06be6c4d7c586459e80bb010423fe4b9801124b71c945fd118d99432869bc180bfa32a6c3c29bcfb6b4c5a027f WHIRLPOOL 90a24c97c8c077f1e4bd3c79c1785b3cf129955a0a1ae98dafa460c482bd2e25e3a564757b2afc470159b140b4fac31cd809ad525dc6337842a50a8c958cf59f
+AUX giflib-4.1.6-giffix-null-Extension-fix.patch 693 SHA256 fbbe6cdb82837b5791e9743f1dc2f55ba2c6c16cc799f894571815750ea50bb5 SHA512 9006c85529735a84afaddddbb06b25cb2b7eff64574edea693d75171c6b2bb7a666e498920a9abca2b28290e4c601b6eb6eecc6ea1b0e6b8602fd4a55863338f WHIRLPOOL fb37d5cc0474e9f6041136eb7ac9da94683406c9234f2d24593d1a38fa646f88aea51b8b8561cdec977ebd98fe0c11e5f70c83a70b530aaaae091cce575d256c
+DIST giflib-4.1.6.tar.bz2 506050 SHA256 e1c1ced9c5bc8f93ef0faf0a8c7717abf784d10a7b270d2285e8e1f3b93f2bed SHA512 f47954218ed7d3415cc195a1031a688fcb7dd2bc2b394491830e6b5f5332903ed7c4433b795cd3da9ac53bfc969fe94bec2a4e66b15c0385c732c01b1b7e5057 WHIRLPOOL ee5c3c606dcc2a56151cfd8f9ec33ce6071fb433969df92fae5d51def5bdf974f6dcdb1acf7d83234967f0f5fd3822702822e1e6b274c2e6c39e3e324b54fe09
+DIST giflib-4.2.3.tar.bz2 560968 SHA256 0ac8d56726f77c8bc9648c93bbb4d6185d32b15ba7bdb702415990f96f3cb766 SHA512 f582fafa3ccb0f9ae6f040df0e33469a26fb275437f8615c39af613523ef5f3b09003ed3419f62880200606edfbe08b5aa3ba18a4d615ecd8da27331aec16b36 WHIRLPOOL b23ef64d227eb5219a9a1143cdafea6cb0aea12409fc18a686d5bf2d5241f97ac1c8f8bb76b0c99a5fd60fcff45fc092a2226a6b54ee24a2ec3841765a102447
+DIST giflib-5.0.6.tar.bz2 621073 SHA256 8909839ccbdfca75cfbe6a4db907b55978e11fb268a8f3cde24bd923a0f669ea SHA512 117e20319f2df32bdf094678cdececad2b6f33a40baff172d4df68ade86547825ebca81186071bff51e60126692df84dbd7bb5cc4877ba68448f7c47a2cc2491 WHIRLPOOL e9c0bce41f36c00a87ce119310f39ae9ba8af8b7fa029ce8481d9ed81aa9ef1e417fb7236d5e3ea0c93d7b40ce07876100515051628b504506ec0d1fffe00bad
+DIST giflib-5.1.3.tar.bz2 639420 SHA256 5096d27805283599b01074d487ad3f8e02bd26b84d759b9017be876ca3d5b81d SHA512 02c1fa3619e0bcd80db6ff12a5caf4c9e5ab370c7741956165fe6cc67fd15a00754d5a6e33dd9393e4754201ff60a4f1f0666026604a662bc0d120c6f13bb0e2 WHIRLPOOL 9141d31f228cf2914257d8c2eb8e791611a10a51c91dd41809f98d9c818377087101b75390d9a58aba798eebf98614983d5ff99b379f39e4c4d155f0711846a2
+DIST giflib-5.1.4.tar.bz2 639703 SHA256 df27ec3ff24671f80b29e6ab1c4971059c14ac3db95406884fc26574631ba8d5 SHA512 32b5e342056c210e6478e9cb3b6ceec9594dcfaf34feea1eb4dad633a081ed4465bceee578c19165907cb47cb83912ac359ceea666a8e07dbbb5420f9928f96d WHIRLPOOL 12f308335538fcf14eb95c7e76adfb8ecaf2f1fcdc051521a40ec65eccaa1520f11170bb4b879149ce9fdeb59ce4449a60b4e1290e685acc5e35b3bca8c0f693
+EBUILD giflib-4.1.6-r2.ebuild 1381 SHA256 5de94c7138d57ebe3da9b2e13c935bb3801c0a62229aea22885c8e2be3897c55 SHA512 51e54c7163c24477b664add2201347df4e41dc819f8e2b444810dc7c0b5cc6766f3e0176bd073188fc5ec953fd09b55b5066082ca307ac7552df164905dcecdd WHIRLPOOL 041a3cc8fbb87f80f86f99c02290912c1f9961fec7afc4bd83163f3fd77579adc268c41e1113d5ff1d43ea74e6bf66d35fb9438152e99495fd3343774fc43b3e
+EBUILD giflib-4.1.6-r3.ebuild 1609 SHA256 1b573c54d32d0fe37ab31d5691ab146919f7aaf7499b7a29b7db7c880e59330c SHA512 e138e276d2504904e3bed4e478cf492fdf663805a50fd4ae510b90c6160a6d3a591214eb738cc7ec545818fb88b7f36f7699ee0b6c5464af199e3a699b805fed WHIRLPOOL 0eb19a88a480455ff32ef4207776482ff8c9ff0792206b4296bf3dae41d595b73b52db43c6ea5b97dd2aa822b5c8e260e57e062b56dbd17be0c63395a88a54d9
+EBUILD giflib-4.2.3-r1.ebuild 1532 SHA256 bc4908ff0caf012fad3927c2702319ed972b1fa4771f3f4b5ac37919aeef83f0 SHA512 77f3d966d7c8045917a3e16b0b1a479693479414a57de6b812d1bd385773b25c7877caada33610b6a15dba63eae51a665d0ec175b1d5c3936a03e0220723d183 WHIRLPOOL 0e99ab35a571f2a1d29400b934b97b4f9284ad53128766ceda2c81954d626397783395a4516fd1725246fb87420caf82f7ca941166e20830499ddafa6d6f2fc8
+EBUILD giflib-5.0.6.ebuild 1219 SHA256 f0056b09bf7c54f8ca67be0101299ece8bff0930ce7787f198c92f7a4ef0e6b4 SHA512 b46fd57c3ec565cb8f39c885d0f0eb7e4a3fd6a64779f1abea9be3dc8f56feb554b3546c5564081169d91ce8a1e18ef4ad644837df90085629d149866f1870b1 WHIRLPOOL 13bf9b0f433db82c58a2a66cdcc5954a2128916eb91a61aef8dee77a2971f0513ea74980af88b738904e4f898bb4ae9e163d86be1fee654c2637132c0454c3ad
+EBUILD giflib-5.1.3.ebuild 1296 SHA256 81db04ba3465bc24cb5866743efde65715991240e02f9d8a8f985c145419277d SHA512 757931d3ac812703bc057f91f7f9cfdca7c1362d12b4986b170e26903f693e2c4556649df7319499a09ba4272d89be4a6482c20334bc387ec218417998b38fe3 WHIRLPOOL b385d7c29be0b06c10a0193124e59a55e05b270a09f45793e9252b8fde18da1f98419666d87c204304b6a1de743b9c05c3e4846855188a08682f9263c95d12c7
+EBUILD giflib-5.1.4.ebuild 1541 SHA256 8b23bc6eec9a53f40856faa56917cd1e2184bfec457c031f39d67b25eb3a6499 SHA512 a663761cd299ede6e929b4d1c4ec1835c07bd59ca54d2fcb8aaddce4fc6e184b1ddf79128238d13ea4af9b56c91fdaa2198ecaf49bcdc2d4910f271acd6c360d WHIRLPOOL 7e9543d95b933aad6add7b43f93c097af9f93485914f6e3cf5a9ceb692d32f585a8835e95cf51c3dd526df9ac33ea184375a55f85db9f0d14cfc6905ce638ca7
+MISC ChangeLog 5206 SHA256 7374160acd1e6bcf972573503159f9ab608ecfd681d5687037b6b9f3b09bf5b2 SHA512 946a7342a478cf8e4ff19b7c3af41e20d247ccc1f729df5a21f602fbfc4c202fb41adfe96023c32d5cf73fcdc4594200b2c7c135744ec452b22ac4413c95e0e9 WHIRLPOOL c207f41c640deb8f74b7e3f8b49bbbc6d92f12b7d5ee5a974792ce8812c82fd12c275e3f29bac04b5fb59099a3c5e54ba836a0e199d7f4ec0f9034ccecd9f8fe
+MISC ChangeLog-2015 11663 SHA256 5d9e5403d05cfbe4b205d407f0e9297068493854c577445c9b66879d855c6315 SHA512 010d1d3f2216cbd28e3b538fffdb661e6853f82285b9f9cce012872178043eb5f45affabfa03ce1f0ac40b84d21264520b2e6d603e8384a4cdef4c5c18e45ca5 WHIRLPOOL b8481819483d9bd2666283543f33997e9a2b6428e30806c1ac6957702399a77eddcbc1a193dd2ddf98b2599bf6853401457702f2c126bfaf87c3956c3c408a17
+MISC metadata.xml 444 SHA256 fce9168190b5f29cbcc0748e25719696cba8620d7ba1e35504d475bdf8a92451 SHA512 10f7b2069a73ae9d488fba9febb6b8edcab5f278e1d68ef5b998037f02de5de81d07983b66f3c4ac8a59fa9a4836b92a909c66a4c1188a97aa03174cf4f546cf WHIRLPOOL d7cf6f02c58afb7eeacb55f868e67e86b9f7f0af407ef15d380d0c037f5bce7d9277a673e5c2023a682d3c1e5cafd38d5069fcc7ecad4f64ddd2269a7f95141c
diff --git a/media-libs/giflib/files/giflib-4.1.6-gif2rle.patch b/media-libs/giflib/files/giflib-4.1.6-gif2rle.patch
new file mode 100644
index 000000000000..95334016648e
--- /dev/null
+++ b/media-libs/giflib/files/giflib-4.1.6-gif2rle.patch
@@ -0,0 +1,18 @@
+https://sourceforge.net/tracker/index.php?func=detail&aid=1829712&group_id=102202&atid=631304
+
+--- giflib/util/gif2rle.c
++++ giflib/util/gif2rle.c
+@@ -222,11 +222,8 @@
+ ColorMap = (GifFile->Image.ColorMap ?
+ GifFile->Image.ColorMap->Colors :
+ GifFile->SColorMap->Colors);
+- if (ColorMap == NULL) {
+- fprintf(stderr, "Gif Image does not have a colormap\n");
+- exit(EXIT_FAILURE);
+- }
+- ColorMapSize = 1 << ColorMap->BitsPerPixel;
++ ColorMapSize = 1 << (GifFile->Image.ColorMap ? GifFile->Image.ColorMap->BitsPerPixel :
++ GifFile->SColorMap->BitsPerPixel);
+ DumpScreen2Rle(ScreenBuffer, GifFile->SWidth, GifFile->SHeight);
+
+ if (DGifCloseFile(GifFile) == GIF_ERROR) {
diff --git a/media-libs/giflib/files/giflib-4.1.6-giffix-null-Extension-fix.patch b/media-libs/giflib/files/giflib-4.1.6-giffix-null-Extension-fix.patch
new file mode 100644
index 000000000000..3e99e66c0d15
--- /dev/null
+++ b/media-libs/giflib/files/giflib-4.1.6-giffix-null-Extension-fix.patch
@@ -0,0 +1,15 @@
+diff -ru giflib-4.1.6/util/giffix.c giflib-4.1.6.new/util/giffix.c
+--- giflib-4.1.6/util/giffix.c 2005-10-09 23:22:23.000000000 -0700
++++ giflib-4.1.6.new/util/giffix.c 2008-09-04 14:00:41.000000000 -0700
+@@ -181,8 +181,8 @@
+ /* Skip any extension blocks in file: */
+ if (DGifGetExtension(GifFileIn, &ExtCode, &Extension) == GIF_ERROR)
+ QuitGifError(GifFileIn, GifFileOut);
+- if (EGifPutExtension(GifFileOut, ExtCode, Extension[0],
+- Extension) == GIF_ERROR)
++ if (Extension && EGifPutExtension(GifFileOut, ExtCode,
++ Extension[0], Extension) == GIF_ERROR)
+ QuitGifError(GifFileIn, GifFileOut);
+
+ /* No support to more than one extension blocks, so discard: */
+
diff --git a/media-libs/giflib/giflib-4.1.6-r2.ebuild b/media-libs/giflib/giflib-4.1.6-r2.ebuild
new file mode 100644
index 000000000000..5886c855d548
--- /dev/null
+++ b/media-libs/giflib/giflib-4.1.6-r2.ebuild
@@ -0,0 +1,56 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=4
+
+inherit epatch epunt-cxx libtool
+
+DESCRIPTION="Library to handle, display and manipulate GIF images"
+HOMEPAGE="https://sourceforge.net/projects/giflib/"
+SRC_URI="mirror://sourceforge/giflib/${P}.tar.bz2"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="rle static-libs X"
+
+DEPEND="X? (
+ x11-libs/libXt
+ x11-libs/libX11
+ x11-libs/libICE
+ x11-libs/libSM
+ )
+ rle? ( media-libs/urt )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-gif2rle.patch
+ epatch "${FILESDIR}"/${P}-giffix-null-Extension-fix.patch
+ elibtoolize
+ epunt_cxx
+}
+
+src_configure() {
+ local myconf=""
+
+ # prevent circular depend #111455
+ if has_version media-libs/urt ; then
+ myconf="${myconf} $(use_enable rle)"
+ else
+ myconf="${myconf} --disable-rle"
+ fi
+
+ econf \
+ --disable-gl \
+ $(use_enable static-libs static) \
+ $(use_enable X x11) \
+ ${myconf}
+}
+
+src_install() {
+ default
+ # for static libs the .la file is required if build with +rle or +X
+ use static-libs || find "${ED}" -name '*.la' -exec rm -f {} +
+ dodoc AUTHORS BUGS ChangeLog NEWS ONEWS README TODO doc/*.txt
+ dohtml -r doc
+}
diff --git a/media-libs/giflib/giflib-4.1.6-r3.ebuild b/media-libs/giflib/giflib-4.1.6-r3.ebuild
new file mode 100644
index 000000000000..4376d54abfba
--- /dev/null
+++ b/media-libs/giflib/giflib-4.1.6-r3.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+inherit epatch epunt-cxx libtool ltprune multilib-minimal
+
+DESCRIPTION="Library to handle, display and manipulate GIF images"
+HOMEPAGE="https://sourceforge.net/projects/giflib/"
+SRC_URI="mirror://sourceforge/giflib/${P}.tar.bz2"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="rle static-libs X"
+
+RDEPEND="
+ rle? ( media-libs/urt )
+ X? ( >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}] )
+ abi_x86_32? (
+ !<=app-emulation/emul-linux-x86-baselibs-20140406-r1
+ !app-emulation/emul-linux-x86-baselibs[-abi_x86_32]
+ )"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-gif2rle.patch
+ epatch "${FILESDIR}"/${P}-giffix-null-Extension-fix.patch
+ sed -i '/X_PRE_LIBS/s:-lSM -lICE::' configure || die #483258
+ elibtoolize
+ epunt_cxx
+}
+
+multilib_src_configure() {
+ local myconf=()
+
+ # prevent circular depend #111455
+ if multilib_is_native_abi && has_version media-libs/urt ; then
+ myconf+=( $(use_enable rle) )
+ else
+ myconf+=( --disable-rle )
+ fi
+
+ ECONF_SOURCE=${S} \
+ econf \
+ --disable-gl \
+ $(use_enable static-libs static) \
+ $(use_enable X x11) \
+ "${myconf[@]}"
+}
+
+multilib_src_install_all() {
+ # for static libs the .la file is required if build with +rle or +X
+ use static-libs || prune_libtool_files --all
+
+ dodoc AUTHORS BUGS ChangeLog NEWS ONEWS README TODO doc/*.txt
+ dohtml -r doc
+}
diff --git a/media-libs/giflib/giflib-4.2.3-r1.ebuild b/media-libs/giflib/giflib-4.2.3-r1.ebuild
new file mode 100644
index 000000000000..78bc63666e88
--- /dev/null
+++ b/media-libs/giflib/giflib-4.2.3-r1.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+inherit autotools-multilib eutils
+
+DESCRIPTION="Library to handle, display and manipulate GIF images"
+HOMEPAGE="https://sourceforge.net/projects/giflib/"
+SRC_URI="mirror://sourceforge/giflib/${P}.tar.bz2"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="static-libs X"
+
+RDEPEND="X? ( >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}] )
+ abi_x86_32? (
+ !<=app-emulation/emul-linux-x86-baselibs-20140406-r1
+ !app-emulation/emul-linux-x86-baselibs[-abi_x86_32]
+ )"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+ # don't generate html docs
+ sed -i '/^SUBDIRS/s/doc//' Makefile.am || die
+
+ epatch "${FILESDIR}"/${PN}-4.1.6-giffix-null-Extension-fix.patch
+ sed -i \
+ -e 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' \
+ -e 's:${X_PRE_LIBS}::' \
+ configure.ac || die #486542,#483258
+ eautoreconf
+
+ sed -i '/X_PRE_LIBS/s:-lSM -lICE::' configure || die #483258
+}
+
+src_configure() {
+ local myeconfargs=(
+ $(use_enable static-libs static)
+ $(use_enable X x11)
+ )
+ autotools-multilib_src_configure
+}
+
+src_test() {
+ autotools-multilib_src_test -C tests
+}
+
+src_install() {
+ autotools-multilib_src_install
+
+ # for static libs the .la file is required if built with +X
+ use static-libs || prune_libtool_files --all
+
+ doman doc/*.1
+ dodoc doc/*.txt
+}
diff --git a/media-libs/giflib/giflib-5.0.6.ebuild b/media-libs/giflib/giflib-5.0.6.ebuild
new file mode 100644
index 000000000000..e666ee52225b
--- /dev/null
+++ b/media-libs/giflib/giflib-5.0.6.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+inherit eutils libtool autotools-multilib
+
+DESCRIPTION="Library to handle, display and manipulate GIF images"
+HOMEPAGE="https://sourceforge.net/projects/giflib/"
+SRC_URI="mirror://sourceforge/giflib/${P}.tar.bz2"
+
+LICENSE="MIT"
+SLOT="0/6"
+# Needs testing first.
+#KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="static-libs"
+
+RDEPEND="
+ abi_x86_32? (
+ !<=app-emulation/emul-linux-x86-baselibs-20140406-r1
+ !app-emulation/emul-linux-x86-baselibs[-abi_x86_32]
+ )"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+ elibtoolize
+}
+
+src_configure() {
+ local myeconfargs=(
+ # No need for xmlto as they ship generated files.
+ ac_cv_prog_have_xmlto=no
+
+ $(use_enable static-libs static)
+ )
+
+ autotools-multilib_src_configure
+}
+
+src_install() {
+ autotools-multilib_src_install
+
+ # for static libs the .la file is required if built with +X
+ use static-libs || prune_libtool_files --all
+
+ doman doc/*.1
+ dodoc doc/*.txt
+ dohtml -r doc
+}
diff --git a/media-libs/giflib/giflib-5.1.3.ebuild b/media-libs/giflib/giflib-5.1.3.ebuild
new file mode 100644
index 000000000000..2f3d325833e4
--- /dev/null
+++ b/media-libs/giflib/giflib-5.1.3.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit eutils libtool multilib-minimal
+
+DESCRIPTION="Library to handle, display and manipulate GIF images"
+HOMEPAGE="https://sourceforge.net/projects/giflib/"
+SRC_URI="mirror://sourceforge/giflib/${P}.tar.bz2"
+
+LICENSE="MIT"
+SLOT="0/7"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="static-libs"
+
+RDEPEND="
+ abi_x86_32? (
+ !<=app-emulation/emul-linux-x86-baselibs-20140406-r1
+ !app-emulation/emul-linux-x86-baselibs[-abi_x86_32]
+ )"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+ default
+ elibtoolize
+}
+
+multilib_src_configure() {
+ local myeconfargs=(
+ # No need for xmlto as they ship generated files.
+ ac_cv_prog_have_xmlto=no
+
+ $(use_enable static-libs static)
+ )
+
+ ECONF_SOURCE="${S}" \
+ econf "${myeconfargs[@]}"
+}
+
+multilib_src_install() {
+ default
+
+ # for static libs the .la file is required if built with +X
+ use static-libs || prune_libtool_files --all
+}
+
+multilib_src_install_all() {
+ doman doc/*.1
+ dodoc AUTHORS BUGS ChangeLog NEWS README TODO doc/*.txt
+ docinto html
+ dodoc -r doc/whatsinagif
+}
diff --git a/media-libs/giflib/giflib-5.1.4.ebuild b/media-libs/giflib/giflib-5.1.4.ebuild
new file mode 100644
index 000000000000..6f5a63608812
--- /dev/null
+++ b/media-libs/giflib/giflib-5.1.4.ebuild
@@ -0,0 +1,71 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit eutils libtool multilib-minimal
+
+DESCRIPTION="Library to handle, display and manipulate GIF images"
+HOMEPAGE="https://sourceforge.net/projects/giflib/"
+SRC_URI="mirror://sourceforge/giflib/${P}.tar.bz2"
+
+LICENSE="MIT"
+SLOT="0/7"
+KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="doc static-libs"
+
+RDEPEND="
+ abi_x86_32? (
+ !<=app-emulation/emul-linux-x86-baselibs-20140406-r1
+ !app-emulation/emul-linux-x86-baselibs[-abi_x86_32]
+ )"
+DEPEND="${RDEPEND}
+ doc? ( app-text/xmlto )"
+
+src_prepare() {
+ default
+ elibtoolize
+}
+
+multilib_src_configure() {
+ local myeconfargs=(
+ # No need for xmlto as they ship generated files.
+ ac_cv_prog_have_xmlto=no
+
+ $(use_enable static-libs static)
+ )
+
+ ECONF_SOURCE="${S}" \
+ econf "${myeconfargs[@]}"
+}
+
+multilib_src_compile() {
+ default
+
+ if use doc && multilib_is_native_abi; then
+ emake -C doc
+ fi
+}
+
+multilib_src_install() {
+ default
+
+ # for static libs the .la file is required if built with +X
+ use static-libs || prune_libtool_files --all
+
+ if use doc && multilib_is_native_abi; then
+ docinto html
+ dodoc doc/*.html
+ fi
+}
+
+multilib_src_install_all() {
+ doman doc/*.1
+ docinto
+ dodoc AUTHORS BUGS ChangeLog NEWS README TODO
+ if use doc; then
+ dodoc doc/*.txt
+ docinto html
+ dodoc -r doc/whatsinagif
+ fi
+}
diff --git a/media-libs/giflib/metadata.xml b/media-libs/giflib/metadata.xml
new file mode 100644
index 000000000000..e88f57a6700b
--- /dev/null
+++ b/media-libs/giflib/metadata.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>graphics@gentoo.org</email>
+ <name>Gentoo Graphics Project</name>
+ </maintainer>
+ <use>
+ <flag name="rle">Build converters for RLE format (utah raster toolkit)</flag>
+ </use>
+ <upstream>
+ <remote-id type="sourceforge">giflib</remote-id>
+ </upstream>
+</pkgmetadata>