summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Black <dragonheart@gentoo.org>2006-07-04 09:06:04 +0000
committerDaniel Black <dragonheart@gentoo.org>2006-07-04 09:06:04 +0000
commitb04cfb80c2b3cfc38151f531581965580cecfc07 (patch)
treef2915d10371c894a2e8c4603a03e78ee8eec0cfc /x11-misc/electricsheep
parentFixed RDEPEND wrt bug #134781; fixed header (diff)
downloadgentoo-2-b04cfb80c2b3cfc38151f531581965580cecfc07.tar.gz
gentoo-2-b04cfb80c2b3cfc38151f531581965580cecfc07.tar.bz2
gentoo-2-b04cfb80c2b3cfc38151f531581965580cecfc07.zip
patch from upstream to use >=libpng-1.2.10 as per bug #137059.
(Portage version: 2.1.1_pre2-r1)
Diffstat (limited to 'x11-misc/electricsheep')
-rw-r--r--x11-misc/electricsheep/ChangeLog10
-rw-r--r--x11-misc/electricsheep/electricsheep-2.6.7-r1.ebuild87
-rw-r--r--x11-misc/electricsheep/files/digest-electricsheep-2.6.7-r13
-rw-r--r--x11-misc/electricsheep/files/electricsheep-2.6.7-libpng-1.2.10.patch123
4 files changed, 222 insertions, 1 deletions
diff --git a/x11-misc/electricsheep/ChangeLog b/x11-misc/electricsheep/ChangeLog
index bc14f315a546..73150dc44cac 100644
--- a/x11-misc/electricsheep/ChangeLog
+++ b/x11-misc/electricsheep/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for x11-misc/electricsheep
# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/x11-misc/electricsheep/ChangeLog,v 1.33 2006/06/29 06:44:00 dragonheart Exp $
+# $Header: /var/cvsroot/gentoo-x86/x11-misc/electricsheep/ChangeLog,v 1.34 2006/07/04 09:06:04 dragonheart Exp $
+
+*electricsheep-2.6.7-r1 (04 Jul 2006)
+
+ 04 Jul 2006; Daniel Black <dragonheart@gentoo.org>
+ +files/electricsheep-2.6.7-libpng-1.2.10.patch,
+ +electricsheep-2.6.7-r1.ebuild:
+ patch from upstream to use >=libpng-1.2.10 as per bug #137059. Thanks to Ed
+ and Mike
29 Jun 2006; Daniel Black <dragonheart@gentoo.org>
electricsheep-2.6.7.ebuild:
diff --git a/x11-misc/electricsheep/electricsheep-2.6.7-r1.ebuild b/x11-misc/electricsheep/electricsheep-2.6.7-r1.ebuild
new file mode 100644
index 000000000000..73ec285d52ec
--- /dev/null
+++ b/x11-misc/electricsheep/electricsheep-2.6.7-r1.ebuild
@@ -0,0 +1,87 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/x11-misc/electricsheep/electricsheep-2.6.7-r1.ebuild,v 1.1 2006/07/04 09:06:04 dragonheart Exp $
+
+inherit eutils flag-o-matic kde-functions
+
+DESCRIPTION="realize the collective dream of sleeping computers from all over the internet"
+HOMEPAGE="http://electricsheep.org/"
+SRC_URI="http://electricsheep.org/${P}.tar.gz"
+IUSE="kde"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~sparc ~x86"
+
+RDEPEND="|| ( ( x11-libs/libXv
+ x11-libs/libICE
+ x11-libs/libSM
+ )
+ virtual/x11
+ )
+ dev-libs/expat
+ net-misc/curl
+ media-libs/jpeg
+ >=media-libs/libpng-1.2.10
+ media-libs/libsdl
+ virtual/libc
+ sys-libs/zlib"
+
+DEPEND="${RDEPEND}
+ || ( ( x11-proto/xextproto
+ x11-libs/libXt
+ )
+ virtual/x11
+ )
+ sys-apps/groff
+ dev-lang/perl
+ >=sys-apps/sed-4
+ media-libs/libmpeg2
+ sys-apps/gawk
+ sys-apps/grep
+ sys-devel/libtool"
+
+src_unpack() {
+ unpack ${A}
+ # Detect PIC requirement from direct from compiler instead of
+ # macro PIC.
+ sed -i -e 's/def PIC/def __PIC__/' ${S}/mpeg2dec/src/cpu_accel.c
+ epatch ${FILESDIR}/${P}-cflagsfix.patch
+ cd ${S}
+ epatch ${FILESDIR}/${P}-libpng-1.2.10.patch
+}
+
+# Also detects and ties in sys-libs/slang, media-libs/aalib media-libs/svgalib and nas
+# if they exist on the user machine although these aren't deps.
+
+src_install() {
+
+
+ # prevent writing for xscreensaver
+ sed -i "s/^install-data-local:$/install-data-local:\nmy-install-data-local:/" \
+ Makefile || die "sed Makefile failed"
+
+ # install the xscreensaver config file
+ insinto /usr/share/xscreensaver/config
+ doins electricsheep.xml
+
+ make install DESTDIR="${D}" || die "make install failed"
+
+ dodir /usr/share/electricsheep
+ if [ ! -f "${ROOT}/usr/share/electricsheep/electricsheep-uniqueid" ]
+ then
+ "${D}/usr/bin/uniqueid" > \
+ "${D}/usr/share/electricsheep/electricsheep-uniqueid"
+ fi
+
+ if use kde;
+ then
+ set-kdedir
+ insinto /usr/share/applications
+ doins "${FILESDIR}/${PN}.desktop"
+ insinto "${KDEDIR}//share/applnk/System/ScreenSavers"
+ doins "${FILESDIR}/${PN}.desktop"
+ fi
+
+ # remove header files that are installed over libmpeg2
+ rm -rf "${D}/usr/include"
+}
diff --git a/x11-misc/electricsheep/files/digest-electricsheep-2.6.7-r1 b/x11-misc/electricsheep/files/digest-electricsheep-2.6.7-r1
new file mode 100644
index 000000000000..4d907db17fd0
--- /dev/null
+++ b/x11-misc/electricsheep/files/digest-electricsheep-2.6.7-r1
@@ -0,0 +1,3 @@
+MD5 1a484c9b7ef8c7843bf3ba608753ac00 electricsheep-2.6.7.tar.gz 1387836
+RMD160 b842ec3761294bb6501127daf9fc377752bd830d electricsheep-2.6.7.tar.gz 1387836
+SHA256 f7b91f7a81a556a213543ab76c9595a738dd931fe2bc2acac6b704b5d09253f0 electricsheep-2.6.7.tar.gz 1387836
diff --git a/x11-misc/electricsheep/files/electricsheep-2.6.7-libpng-1.2.10.patch b/x11-misc/electricsheep/files/electricsheep-2.6.7-libpng-1.2.10.patch
new file mode 100644
index 000000000000..8f41e1f296c5
--- /dev/null
+++ b/x11-misc/electricsheep/files/electricsheep-2.6.7-libpng-1.2.10.patch
@@ -0,0 +1,123 @@
+--- electricsheep/client/flam3/png.c 2005/07/20 06:06:16 1.8
++++ electricsheep/client/flam3/png.c 2006/06/26 19:36:49 1.9
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <png.h>
++#include <setjmp.h>
+
+ #include "img.h"
+
+@@ -67,7 +68,7 @@
+ unsigned char sig_buf [SIG_CHECK_SIZE];
+ png_struct *png_ptr;
+ png_info *info_ptr;
+- png_byte **png_image;
++ png_byte **png_image = NULL;
+ int linesize, x, y;
+ unsigned char *p, *q;
+
+@@ -85,6 +86,16 @@
+ fprintf (stderr, "cannot allocate LIBPNG structure\n");
+ return 0;
+ }
++ if (setjmp(png_jmpbuf(png_ptr))) {
++ if (png_image) {
++ for (y = 0 ; y < info_ptr->height ; y++)
++ free (png_image[y]);
++ free (png_image);
++ }
++ png_destroy_read_struct(&png_ptr, &info_ptr, (png_infopp)NULL);
++ perror("reading file");
++ return;
++ }
+ info_ptr = png_create_info_struct (png_ptr);
+ if (info_ptr == NULL) {
+ png_destroy_read_struct (&png_ptr, (png_infopp)NULL, (png_infopp)NULL);
+@@ -155,9 +166,7 @@
+ for (y = 0 ; y < info_ptr->height ; y++)
+ free (png_image[y]);
+ free (png_image);
+- png_read_destroy (png_ptr, info_ptr, (png_info *)0);
+- free (png_ptr);
+- free (info_ptr);
++ png_destroy_read_struct (&png_ptr, &info_ptr, (png_infopp)NULL);
+
+ return q;
+ }
+--- electricsheep/client/mpeg2dec/libvo/video_out_x11.c 2005/07/20 03:03:00 1.6
++++ electricsheep/client/mpeg2dec/libvo/video_out_x11.c 2006/06/26 19:36:49 1.7
+@@ -39,6 +39,8 @@
+ #include <X11/extensions/XShm.h>
+ #include <inttypes.h>
+ #include <sys/time.h>
++#include <png.h>
++#include <setjmp.h>
+
+ #include "vroot.h"
+ #include <sys/types.h>
+@@ -124,8 +126,6 @@
+ tv_rate = tv_end;
+ }
+
+-#include <png.h>
+-
+ static char *overlay_luma = NULL;
+ static char *overlay_alpha = NULL;
+ static int overlay_width;
+@@ -165,7 +165,7 @@
+ unsigned char sig_buf [SIG_CHECK_SIZE];
+ png_struct *png_ptr;
+ png_info *info_ptr;
+- png_byte **png_image;
++ png_byte **png_image = NULL;
+ int linesize, x, y;
+ unsigned char *p, *q;
+
+@@ -183,6 +183,16 @@
+ fprintf (stderr, "cannot allocate LIBPNG structure\n");
+ return;
+ }
++ if (setjmp(png_jmpbuf(png_ptr))) {
++ if (png_image) {
++ for (y = 0 ; y < info_ptr->height ; y++)
++ free (png_image[y]);
++ free (png_image);
++ }
++ png_destroy_read_struct(&png_ptr, &info_ptr, (png_infopp)NULL);
++ perror("reading file");
++ return;
++ }
+ info_ptr = png_create_info_struct (png_ptr);
+ if (info_ptr == NULL) {
+ png_destroy_read_struct (&png_ptr, (png_infopp)NULL, (png_infopp)NULL);
+@@ -271,10 +281,7 @@
+ for (y = 0 ; y < info_ptr->height ; y++)
+ free (png_image[y]);
+ free (png_image);
+- png_read_destroy (png_ptr, info_ptr, (png_info *)0);
+- free (png_ptr);
+- free (info_ptr);
+-
++ png_destroy_read_struct (&png_ptr, &info_ptr, (png_infopp)NULL);
+ }
+
+ static void overlay_read_ppm(FILE *fin)
+@@ -535,6 +542,8 @@
+ instance->corner_x = (w - instance->width)/2;
+ instance->corner_y = (h - instance->height)/2;
+ } else if (window_id == -1) {
++ XTextProperty xname;
++ char *nm = "Electric Sheep";
+ /* create a window the same size as the video */
+ instance->window =
+ XCreateWindow (instance->display,
+@@ -544,6 +553,8 @@
+ InputOutput, instance->vinfo.visual,
+ (CWBackPixmap | CWBackingStore | CWBorderPixel |
+ CWEventMask | CWColormap), &attr);
++ XStringListToTextProperty(&nm, 1, &xname);
++ XSetWMName(instance->display, instance->window, &xname);
+ } else {
+ /* zoomed to fit the window specified on the command line */
+ XWindowAttributes xgwa;