summaryrefslogtreecommitdiff
path: root/media-libs/giflib
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-03-24 10:19:03 +0000
committerV3n3RiX <venerix@redcorelinux.org>2018-03-24 10:19:03 +0000
commitb279bbe94522565b8feb19b8e5f377d3ea76f157 (patch)
treee4790abc54cd850232f7d7de49e371fdfe8976c7 /media-libs/giflib
parentc5283d322accc6097afec74eab24550829788bab (diff)
gentoo resync : 24.03.2018
Diffstat (limited to 'media-libs/giflib')
-rw-r--r--media-libs/giflib/Manifest2
-rw-r--r--media-libs/giflib/files/giflib-5.1.4-reallocarray-export.patch129
-rw-r--r--media-libs/giflib/giflib-5.1.4-r1.ebuild75
3 files changed, 206 insertions, 0 deletions
diff --git a/media-libs/giflib/Manifest b/media-libs/giflib/Manifest
index 7410d68f1a1e..3f6877f3c06b 100644
--- a/media-libs/giflib/Manifest
+++ b/media-libs/giflib/Manifest
@@ -1,10 +1,12 @@
AUX giflib-4.1.6-gif2rle.patch 764 BLAKE2B af377785f83dcd5c2c4382eb2d490ccc01000aa2a1ef8f306c7e0284857de02765a714fea73870ac6226331a88e422bd8afd3b0ec90b7f3e225bcabf079dc32e SHA512 6714906d49a0c285c1fb642a81c092378042ec06be6c4d7c586459e80bb010423fe4b9801124b71c945fd118d99432869bc180bfa32a6c3c29bcfb6b4c5a027f
AUX giflib-4.1.6-giffix-null-Extension-fix.patch 693 BLAKE2B b0faee004c9cbb95839cb047de902500b1c46f6d3185fc061fb99b0759a57512cb030ca965bb927c68c642ecd72a714260c288b19d24404a6b4cb022ba41094b SHA512 9006c85529735a84afaddddbb06b25cb2b7eff64574edea693d75171c6b2bb7a666e498920a9abca2b28290e4c601b6eb6eecc6ea1b0e6b8602fd4a55863338f
+AUX giflib-5.1.4-reallocarray-export.patch 5770 BLAKE2B 6e4b4015a7e1d1a1f35644ecde4a3638243de562f8ffda755ccc56b878aa503771725e7cab348638b5a00b10de96e551ee6b7a0a0b50ee6269b3165b676f3c4d SHA512 4cde35f05b18229da3835742ca555dc73dc489e534913486b4752a1c4a02e3c0c31b221283f433cf55083c31b14ed67f54a47b8481d25f8855742f9251baf717
DIST giflib-4.1.6.tar.bz2 506050 BLAKE2B 154c95425a570a822447d1fc5bddbecf31fd81473e18d49fdeb93e72ade7541197fc6147b2d4cdf6857b3326b2f4c40e01f026041369242f4e9fbe892cc8e150 SHA512 f47954218ed7d3415cc195a1031a688fcb7dd2bc2b394491830e6b5f5332903ed7c4433b795cd3da9ac53bfc969fe94bec2a4e66b15c0385c732c01b1b7e5057
DIST giflib-5.0.6.tar.bz2 621073 BLAKE2B ae162c281755cae4d00bcbd07273f7c7488ae67c42fef819abae1011eddf801bc4525e326417d3e8a036b18b75d7064de59ceda370e5ded956b22d319c67d3a9 SHA512 117e20319f2df32bdf094678cdececad2b6f33a40baff172d4df68ade86547825ebca81186071bff51e60126692df84dbd7bb5cc4877ba68448f7c47a2cc2491
DIST giflib-5.1.4.tar.bz2 639703 BLAKE2B 5176fbd94c37a86a7f7a3964b6b5f2637d76ba5d40e594a0db52a3a09e22b915a0388fc9bd2f1446dcf66b3b9c0d76741583e4d5d3f7362fa3997e8b26503fc4 SHA512 32b5e342056c210e6478e9cb3b6ceec9594dcfaf34feea1eb4dad633a081ed4465bceee578c19165907cb47cb83912ac359ceea666a8e07dbbb5420f9928f96d
EBUILD giflib-4.1.6-r2.ebuild 1381 BLAKE2B 53da805ac9c0e6641536fb57b772c9921c4e41441fddfd0e53a6b2d00e76eac38e0f6a53fbfa3a8b13058c5ae8885b5212d62b8a7eec5afef6c13b2c40048803 SHA512 51e54c7163c24477b664add2201347df4e41dc819f8e2b444810dc7c0b5cc6766f3e0176bd073188fc5ec953fd09b55b5066082ca307ac7552df164905dcecdd
EBUILD giflib-4.1.6-r3.ebuild 1609 BLAKE2B fa19054072551719fc111d0ba1c8df029d5f47649500fd9859c328915a5335e36c098075c2d2c9954bd3f2a1c9435d0dee7308fc36499963d09d255170b40e54 SHA512 e138e276d2504904e3bed4e478cf492fdf663805a50fd4ae510b90c6160a6d3a591214eb738cc7ec545818fb88b7f36f7699ee0b6c5464af199e3a699b805fed
EBUILD giflib-5.0.6.ebuild 1219 BLAKE2B b4fd9c6b45c9cba3b5ffbcacc4a378ce73dbb6d5bc15d7de8c43248ec997463bb8ee9637edc48f98ac541c9e7b152f40bfecbdeaded007f80c5acf1d88972546 SHA512 b46fd57c3ec565cb8f39c885d0f0eb7e4a3fd6a64779f1abea9be3dc8f56feb554b3546c5564081169d91ce8a1e18ef4ad644837df90085629d149866f1870b1
+EBUILD giflib-5.1.4-r1.ebuild 1609 BLAKE2B da2fe5ae5983d27cd42fb1ded6b2ded6715f78d9ee42c1502aaa0380078c1d40abf372c720c40b3c72b1395282ec6016722616838edccf6f7c59be2c0dc64948 SHA512 beded9c6943664b953fc05e934024b72d530c75f53097636a2be1d1ab2d0d8e1e62d32be98b4ea12a6e7c1671a44f1d2ba56795b7f98b42af123f85224975a4f
EBUILD giflib-5.1.4.ebuild 1541 BLAKE2B 69bda497857d80d0e29632d4f485ca97e42812c1dd789f0e0c28fa0cf7b400da28e73a73cc6aa4fdcce0d8b62a22c86f2c2f9fb52cd204c1243de6e5bc9a8c7f SHA512 a663761cd299ede6e929b4d1c4ec1835c07bd59ca54d2fcb8aaddce4fc6e184b1ddf79128238d13ea4af9b56c91fdaa2198ecaf49bcdc2d4910f271acd6c360d
MISC metadata.xml 444 BLAKE2B 50913e89623c9855de9b3344c4f7a9f6266b42d99ab88cd4c6be63b8fb00a984dc05b89efbac92ed2b5980e9bed163473925a88384a61b3887ef86473f89b216 SHA512 10f7b2069a73ae9d488fba9febb6b8edcab5f278e1d68ef5b998037f02de5de81d07983b66f3c4ac8a59fa9a4836b92a909c66a4c1188a97aa03174cf4f546cf
diff --git a/media-libs/giflib/files/giflib-5.1.4-reallocarray-export.patch b/media-libs/giflib/files/giflib-5.1.4-reallocarray-export.patch
new file mode 100644
index 000000000000..08d4f3d3d4ed
--- /dev/null
+++ b/media-libs/giflib/files/giflib-5.1.4-reallocarray-export.patch
@@ -0,0 +1,129 @@
+From 9805c76d4f76c77aad9f285e81f4090cdf661fac Mon Sep 17 00:00:00 2001
+From: Sebastian Pipping <sebastian@pipping.org>
+Date: Wed, 14 Mar 2018 21:18:14 +0100
+Subject: [PATCH] Address clash of export reallocarray with glibc
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+.. by not exporting that internal symbol any more,
+and renaming the function in code and where it's used
+
+Bug: https://bugs.gentoo.org/637438
+
+Compile error was:
+
+/usr/include/gif_lib.h:248:51: error: declaration of ‘void* reallocarray(void*, size_t, size_t)’ has a different exception specifier
+ reallocarray(void *optr, size_t nmemb, size_t size);
+ ^
+[..]
+/usr/include/stdlib.h:443:14: error: from previous declaration ‘void* reallocarray(void*, size_t, size_t) throw ()’
+ extern void *reallocarray (void *__ptr, size_t __nmemb, size_t __size)
+---
+ lib/dgif_lib.c | 4 ++--
+ lib/gif_lib.h | 3 ---
+ lib/gifalloc.c | 10 +++++-----
+ lib/openbsd-reallocarray.c | 2 +-
+ 4 files changed, 8 insertions(+), 11 deletions(-)
+
+diff --git a/lib/dgif_lib.c b/lib/dgif_lib.c
+index 66a1d6a..f0e0385 100644
+--- a/lib/dgif_lib.c
++++ b/lib/dgif_lib.c
+@@ -396,7 +396,7 @@ DGifGetImageDesc(GifFileType *GifFile)
+
+ if (GifFile->SavedImages) {
+ SavedImage* new_saved_images =
+- (SavedImage *)reallocarray(GifFile->SavedImages,
++ (SavedImage *)openbsd_reallocarray(GifFile->SavedImages,
+ (GifFile->ImageCount + 1), sizeof(SavedImage));
+ if (new_saved_images == NULL) {
+ GifFile->Error = D_GIF_ERR_NOT_ENOUGH_MEM;
+@@ -1108,7 +1108,7 @@ DGifSlurp(GifFileType *GifFile)
+ if (ImageSize > (SIZE_MAX / sizeof(GifPixelType))) {
+ return GIF_ERROR;
+ }
+- sp->RasterBits = (unsigned char *)reallocarray(NULL, ImageSize,
++ sp->RasterBits = (unsigned char *)openbsd_reallocarray(NULL, ImageSize,
+ sizeof(GifPixelType));
+
+ if (sp->RasterBits == NULL) {
+diff --git a/lib/gif_lib.h b/lib/gif_lib.h
+index 078930c..7914a69 100644
+--- a/lib/gif_lib.h
++++ b/lib/gif_lib.h
+@@ -244,9 +244,6 @@ extern ColorMapObject *GifUnionColorMap(const ColorMapObject *ColorIn1,
+ GifPixelType ColorTransIn2[]);
+ extern int GifBitSize(int n);
+
+-extern void *
+-reallocarray(void *optr, size_t nmemb, size_t size);
+-
+ /******************************************************************************
+ Support for the in-core structures allocation (slurp mode).
+ ******************************************************************************/
+diff --git a/lib/gifalloc.c b/lib/gifalloc.c
+index 3b51868..1394cfa 100644
+--- a/lib/gifalloc.c
++++ b/lib/gifalloc.c
+@@ -188,7 +188,7 @@ GifUnionColorMap(const ColorMapObject *ColorIn1,
+
+ /* perhaps we can shrink the map? */
+ if (RoundUpTo < ColorUnion->ColorCount) {
+- GifColorType *new_map = (GifColorType *)reallocarray(Map,
++ GifColorType *new_map = (GifColorType *)openbsd_reallocarray(Map,
+ RoundUpTo, sizeof(GifColorType));
+ if( new_map == NULL ) {
+ GifFreeMapObject(ColorUnion);
+@@ -232,7 +232,7 @@ GifAddExtensionBlock(int *ExtensionBlockCount,
+ if (*ExtensionBlocks == NULL)
+ *ExtensionBlocks=(ExtensionBlock *)malloc(sizeof(ExtensionBlock));
+ else {
+- ExtensionBlock* ep_new = (ExtensionBlock *)reallocarray
++ ExtensionBlock* ep_new = (ExtensionBlock *)openbsd_reallocarray
+ (*ExtensionBlocks, (*ExtensionBlockCount + 1),
+ sizeof(ExtensionBlock));
+ if( ep_new == NULL )
+@@ -325,7 +325,7 @@ GifMakeSavedImage(GifFileType *GifFile, const SavedImage *CopyFrom)
+ if (GifFile->SavedImages == NULL)
+ GifFile->SavedImages = (SavedImage *)malloc(sizeof(SavedImage));
+ else
+- GifFile->SavedImages = (SavedImage *)reallocarray(GifFile->SavedImages,
++ GifFile->SavedImages = (SavedImage *)openbsd_reallocarray(GifFile->SavedImages,
+ (GifFile->ImageCount + 1), sizeof(SavedImage));
+
+ if (GifFile->SavedImages == NULL)
+@@ -355,7 +355,7 @@ GifMakeSavedImage(GifFileType *GifFile, const SavedImage *CopyFrom)
+ }
+
+ /* next, the raster */
+- sp->RasterBits = (unsigned char *)reallocarray(NULL,
++ sp->RasterBits = (unsigned char *)openbsd_reallocarray(NULL,
+ (CopyFrom->ImageDesc.Height *
+ CopyFrom->ImageDesc.Width),
+ sizeof(GifPixelType));
+@@ -369,7 +369,7 @@ GifMakeSavedImage(GifFileType *GifFile, const SavedImage *CopyFrom)
+
+ /* finally, the extension blocks */
+ if (sp->ExtensionBlocks != NULL) {
+- sp->ExtensionBlocks = (ExtensionBlock *)reallocarray(NULL,
++ sp->ExtensionBlocks = (ExtensionBlock *)openbsd_reallocarray(NULL,
+ CopyFrom->ExtensionBlockCount,
+ sizeof(ExtensionBlock));
+ if (sp->ExtensionBlocks == NULL) {
+diff --git a/lib/openbsd-reallocarray.c b/lib/openbsd-reallocarray.c
+index aa70686..b922b01 100644
+--- a/lib/openbsd-reallocarray.c
++++ b/lib/openbsd-reallocarray.c
+@@ -27,7 +27,7 @@
+ #define MUL_NO_OVERFLOW ((size_t)1 << (sizeof(size_t) * 4))
+
+ void *
+-reallocarray(void *optr, size_t nmemb, size_t size)
++openbsd_reallocarray(void *optr, size_t nmemb, size_t size)
+ {
+ if ((nmemb >= MUL_NO_OVERFLOW || size >= MUL_NO_OVERFLOW) &&
+ nmemb > 0 && SIZE_MAX / nmemb < size) {
+--
+2.16.2
+
diff --git a/media-libs/giflib/giflib-5.1.4-r1.ebuild b/media-libs/giflib/giflib-5.1.4-r1.ebuild
new file mode 100644
index 000000000000..a5fce8fa5fee
--- /dev/null
+++ b/media-libs/giflib/giflib-5.1.4-r1.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2018 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 )"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-reallocarray-export.patch
+)
+
+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
+}