summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMounir Lamouri <volkmar@gentoo.org>2010-03-24 23:33:58 +0000
committerMounir Lamouri <volkmar@gentoo.org>2010-03-24 23:33:58 +0000
commit6ebe03ea80978835d3c8dff51dec6112530b14e0 (patch)
treee9ee55e6e3412ac035e3fcbbe1356bc8b2fd5627 /media-libs/pnglite
parentVersion bump to 0.3.2. (diff)
downloadgentoo-2-6ebe03ea80978835d3c8dff51dec6112530b14e0.tar.gz
gentoo-2-6ebe03ea80978835d3c8dff51dec6112530b14e0.tar.bz2
gentoo-2-6ebe03ea80978835d3c8dff51dec6112530b14e0.zip
Initial commit.
Package required for teeworlds, bug 206287. (Portage version: 15511-svn/cvs/Linux i686)
Diffstat (limited to 'media-libs/pnglite')
-rw-r--r--media-libs/pnglite/ChangeLog10
-rw-r--r--media-libs/pnglite/files/pnglite-0.1.17-include-stdio.patch16
-rw-r--r--media-libs/pnglite/metadata.xml10
-rw-r--r--media-libs/pnglite/pnglite-0.1.17.ebuild53
4 files changed, 89 insertions, 0 deletions
diff --git a/media-libs/pnglite/ChangeLog b/media-libs/pnglite/ChangeLog
new file mode 100644
index 000000000000..9e6d60bc1607
--- /dev/null
+++ b/media-libs/pnglite/ChangeLog
@@ -0,0 +1,10 @@
+# ChangeLog for media-libs/pnglite
+# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/pnglite/ChangeLog,v 1.1 2010/03/24 23:33:57 volkmar Exp $
+
+*pnglite-0.1.17 (24 Mar 2010)
+
+ 24 Mar 2010; Mounir Lamouri <volkmar@gentoo.org> +pnglite-0.1.17.ebuild,
+ +files/pnglite-0.1.17-include-stdio.patch, +metadata.xml:
+ Initial commit. Package required for teeworlds, bug 206287
+
diff --git a/media-libs/pnglite/files/pnglite-0.1.17-include-stdio.patch b/media-libs/pnglite/files/pnglite-0.1.17-include-stdio.patch
new file mode 100644
index 000000000000..a29df412dd98
--- /dev/null
+++ b/media-libs/pnglite/files/pnglite-0.1.17-include-stdio.patch
@@ -0,0 +1,16 @@
+This patch comes from the Debian package.
+
+Index: pnglite-0.1.17/pnglite.h
+===================================================================
+--- pnglite-0.1.17.orig/pnglite.h 2008-04-18 17:15:07.000000000 +1000
++++ pnglite-0.1.17/pnglite.h 2008-04-18 17:15:18.000000000 +1000
+@@ -24,7 +24,8 @@
+ daniel.karling@gmail.com
+ */
+
+-
++
++#include <stdio.h>
+ #ifndef _PNGLITE_H_
+ #define _PNGLITE_H_
+
diff --git a/media-libs/pnglite/metadata.xml b/media-libs/pnglite/metadata.xml
new file mode 100644
index 000000000000..d44dc8ef07cc
--- /dev/null
+++ b/media-libs/pnglite/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>no-herd</herd>
+ <maintainer>
+ <email>volkmar@gentoo.org</email>
+ <name>Mounir Lamouri</name>
+ </maintainer>
+</pkgmetadata>
+
diff --git a/media-libs/pnglite/pnglite-0.1.17.ebuild b/media-libs/pnglite/pnglite-0.1.17.ebuild
new file mode 100644
index 000000000000..e3e1642bfb03
--- /dev/null
+++ b/media-libs/pnglite/pnglite-0.1.17.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/pnglite/pnglite-0.1.17.ebuild,v 1.1 2010/03/24 23:33:57 volkmar Exp $
+
+EAPI="2"
+
+inherit eutils flag-o-matic multilib toolchain-funcs
+
+DESCRIPTION="Small and simple library for loading and writing PNG images"
+HOMEPAGE="http://www.karlings.com/~danne/pnglite/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.zip"
+
+LICENSE="ZLIB"
+SLOT="0"
+KEYWORDS="~x86"
+IUSE="static-libs"
+
+RDEPEND="sys-libs/zlib"
+DEPEND="${RDEPEND}
+ app-arch/unzip"
+
+S=${WORKDIR}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-include-stdio.patch
+ sed -ie "s:\"../zlib/zlib.h\":<zlib.h>:" pnglite.c || die "sed failed"
+}
+
+src_compile() {
+ if use static-libs; then
+ emake ${PN}.o || die "make failed"
+ ar -cvq lib${PN}.a ${PN}.o || die "ar failed"
+ rm ${PN}.o || die "rm failed"
+ fi
+
+ append-flags -fPIC
+ emake ${PN}.o || die "make failed"
+ $(tc-getCC) ${LDFLAGS} -shared -Wl,-soname,lib${PN}.so.0 \
+ -o lib${PN}.so.0 ${PN}.o -lz || die "creating so file failed"
+}
+
+src_install() {
+ insinto /usr/include
+ doins ${PN}.h
+
+ dolib.so lib${PN}.so.0 || die "dolib failed"
+ if use static-libs; then
+ dolib.a lib${PN}.a || die "dolib failed"
+ fi
+
+ dosym lib${PN}.so.0 /usr/$(get_libdir)/lib${PN}.so \
+ || die "dosym failed"
+}