x11-misc/xplanet: Version bump.
authorJeroen Roovers <jer@gentoo.org>
Mon, 11 Apr 2016 05:30:56 +0000 (07:30 +0200)
committerJeroen Roovers <jer@gentoo.org>
Mon, 11 Apr 2016 05:41:01 +0000 (07:41 +0200)
Package-Manager: portage-2.2.28

x11-misc/xplanet/Manifest
x11-misc/xplanet/files/xplanet-1.3.1-giflib.patch [new file with mode: 0644]
x11-misc/xplanet/xplanet-1.3.1.ebuild [new file with mode: 0644]

index d52d658b4f6e95105aaefdd139f96ef63b7db14d..0382efbfec5e33548e2ce8f78b3eb782e3c58d53 100644 (file)
@@ -1 +1,2 @@
 DIST xplanet-1.3.0.tar.gz 1227385 SHA256 44fb742bb93e5661ea8b11ccabcc12896693e051f3dd5083c9227224c416b442 SHA512 c9f0db21c457d0702f8b1fb6d632838f45e80ea45b9cade80d6ab0ae956fdca03cfeed9582548c69b349a354afc27308309656d7e06ac46bc416c3e1038f8efd WHIRLPOOL e4fe013eeef4868d28f8a53c194f54865dd4cf29137936eb609352fba4a3481e0a6db9664944cb67d9e7896b150b5e640c95136e6b9f33dc4810591316d0371a
+DIST xplanet-1.3.1.tar.gz 1236035 SHA256 4380d570a8bf27b81fb629c97a636c1673407f4ac4989ce931720078a90aece7 SHA512 06ce3187fbd364f4ccee768fceca559690c905c870e2fb25ca32453ce09c564ba3455ec539f1e3da177de23a0611f767b375efe2e10b601d09313c0d068e35e0 WHIRLPOOL 4c40fac4056654aa195f9955053d2dfba6791e8e2021673f05c334163ee5b1d842e6101447228844573ed41a88f37c0fd96df633716bddeb55c8940941621ad9
diff --git a/x11-misc/xplanet/files/xplanet-1.3.1-giflib.patch b/x11-misc/xplanet/files/xplanet-1.3.1-giflib.patch
new file mode 100644 (file)
index 0000000..b4d6fb9
--- /dev/null
@@ -0,0 +1,55 @@
+--- a/src/libimage/gif.c
++++ b/src/libimage/gif.c
+@@ -20,6 +20,7 @@
+ 
+ #include <stdio.h>
+ #include <stdlib.h>
++#include <stdbool.h>
+ #include <string.h>
+ 
+ #include <gif_lib.h>
+@@ -179,7 +180,11 @@
+       }
+     }
+     
++#if GIFLIB_MAJOR >= 5
++    if (DGifCloseFile(GifFile, NULL) == GIF_ERROR) {
++#else
+     if (DGifCloseFile(GifFile) == GIF_ERROR) {
++#endif
+       return(0);
+     }
+ 
+@@ -240,7 +245,7 @@
+  *   Also non of the parameter are allocated by this routine.
+  *   This function returns GIF_OK if succesfull, GIF_ERROR otherwise.
+  ******************************************************************************/
+-static int
++int
+ QuantizeBuffer(unsigned int Width,
+                unsigned int Height,
+                int *ColorMapSize,
+@@ -493,7 +498,11 @@
+ static void QuitGifError(GifFileType *GifFile)
+ {
+     fprintf(stderr, "Error writing GIF file\n");
++#if GIFLIB_MAJOR >= 5
++    if (GifFile != NULL) EGifCloseFile(GifFile, NULL);
++#else
+     if (GifFile != NULL) EGifCloseFile(GifFile);
++#endif
+ }
+ 
+ int 
+@@ -589,7 +598,11 @@
+       Ptr += width;
+     }
+ 
++#if GIFLIB_MAJOR >= 5
++    if (EGifCloseFile(GifFile, NULL) == GIF_ERROR)
++#else
+     if (EGifCloseFile(GifFile) == GIF_ERROR)
++#endif
+ 
+     {
+       QuitGifError(GifFile);
diff --git a/x11-misc/xplanet/xplanet-1.3.1.ebuild b/x11-misc/xplanet/xplanet-1.3.1.ebuild
new file mode 100644 (file)
index 0000000..726ebc0
--- /dev/null
@@ -0,0 +1,78 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+inherit base flag-o-matic
+
+DESCRIPTION="Render images of the earth into the X root window"
+HOMEPAGE="http://xplanet.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
+IUSE="gif jpeg png tiff truetype X"
+
+RDEPEND="gif? ( >media-libs/giflib-4.2 )
+       jpeg? ( virtual/jpeg )
+       png? (
+               media-libs/libpng:0
+               media-libs/netpbm
+               )
+       tiff? ( media-libs/tiff:0 )
+       truetype? (
+               media-libs/freetype:2
+               x11-libs/pango
+               )
+       X? (
+               x11-libs/libX11
+               x11-libs/libXext
+               x11-libs/libXScrnSaver
+               x11-libs/libXt
+               )"
+DEPEND="${RDEPEND}
+       truetype? ( virtual/pkgconfig )
+       X? (
+               x11-proto/scrnsaverproto
+               x11-proto/xproto
+               )"
+
+DOCS="AUTHORS ChangeLog NEWS README TODO"
+
+PATCHES=( "${FILESDIR}"/${P}-giflib.patch )
+
+src_configure() {
+       # econf says 'checking pnm.h presence... no'
+       use png && append-cppflags -I/usr/include/netpbm
+
+       local myconf
+
+       use X \
+               && myconf+=" --with-x --with-xscreensaver" \
+               || myconf+=" --with-x=no --with-xscreensaver=no"
+
+       use gif \
+               && myconf+=" --with-gif" \
+               || myconf+=" --with-gif=no"
+
+       use jpeg \
+               && myconf+=" --with-jpeg" \
+               || myconf+=" --with-jpeg=no"
+
+       use tiff \
+               && myconf+=" --with-tiff" \
+               || myconf+=" --with-tiff=no"
+
+       use png \
+               && myconf+=" --with-png --with-pnm" \
+               || myconf+=" --with-png=no --with-pnm=no"
+
+       use truetype \
+               && myconf+=" --with-freetype --with-pango" \
+               || myconf+=" --with-freetype=no --with-pango=no"
+
+       econf \
+               --with-cspice=no \
+               ${myconf}
+}