summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2004-06-30 15:51:26 +0000
committerMike Frysinger <vapier@gentoo.org>2004-06-30 15:51:26 +0000
commit8d0cd98ad79fc66a5ad68a745bd1eb593201b0f6 (patch)
tree48e465f40a62e9ac97877b4abe56a6579c50f46c /media-libs
parentsync IUSE (+build, -uclibc) (diff)
downloadhistorical-8d0cd98ad79fc66a5ad68a745bd1eb593201b0f6.tar.gz
historical-8d0cd98ad79fc66a5ad68a745bd1eb593201b0f6.tar.bz2
historical-8d0cd98ad79fc66a5ad68a745bd1eb593201b0f6.zip
ver bump #55584 and rename
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/gd/ChangeLog191
-rw-r--r--media-libs/gd/Manifest20
-rw-r--r--media-libs/gd/files/1.8.4-dec-alpha-compiler.diff21
-rw-r--r--media-libs/gd/files/1.8.4-jpeg-inc.patch17
-rw-r--r--media-libs/gd/files/digest-gd-1.8.4-r21
-rw-r--r--media-libs/gd/files/digest-gd-2.0.232
-rw-r--r--media-libs/gd/files/digest-gd-2.0.262
-rw-r--r--media-libs/gd/gd-1.8.4-r2.ebuild92
-rw-r--r--media-libs/gd/gd-2.0.23.ebuild60
-rw-r--r--media-libs/gd/gd-2.0.26.ebuild54
-rw-r--r--media-libs/gd/metadata.xml27
11 files changed, 487 insertions, 0 deletions
diff --git a/media-libs/gd/ChangeLog b/media-libs/gd/ChangeLog
new file mode 100644
index 000000000000..3e19ce2e155e
--- /dev/null
+++ b/media-libs/gd/ChangeLog
@@ -0,0 +1,191 @@
+# ChangeLog for media-libs/libgd
+# Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/gd/ChangeLog,v 1.1 2004/06/30 15:51:26 vapier Exp $
+
+*gd-1.8.4-r2 (30 Jun 2004)
+
+ 30 Jun 2004; Mike Frysinger <vapier@gentoo.org> +metadata.xml,
+ +files/1.8.4-dec-alpha-compiler.diff, +files/1.8.4-jpeg-inc.patch,
+ +gd-1.8.4-r2.ebuild, +gd-2.0.23.ebuild, +gd-2.0.26.ebuild:
+ Version bump and rename #55584 by Haroon Rafique.
+
+ 07 Jun 2004; Aron Griffis <agriffis@gentoo.org> libgd-1.8.4-r2.ebuild:
+ Fix use invocation
+
+ 11 May 2004; Michael McCabe <randy@gentoo.org> libgd-2.0.23.ebuild:
+ Added s390 keywords
+
+*libgd-2.0.23 (07 May 2004)
+
+ 07 May 2004; Mike Frysinger <vapier@gentoo.org> +libgd-2.0.23.ebuild:
+ Version bump #50302 by Daniel Webert
+
+ 24 Mar 2004; Michael Sterrett <mr_bones_@gentoo.org> libgd-1.8.4-r2.ebuild:
+ don't use deprecated ? : use syntax
+
+ 04 Mar 2004; Gustavo Zacarias <gustavoz@gentoo.org> libgd-2.0.22.ebuild:
+ stable on sparc
+
+ 17 Feb 2004; Aron Griffis <agriffis@gentoo.org> libgd-2.0.22.ebuild:
+ stable on alpha and ia64
+
+ 09 Feb 2004; <augustus@gentoo.org> libgd-2.0.22.ebuild:
+ Added ~amd64 keyword.
+
+*libgd-2.0.22 (02 Feb 2004)
+
+ 02 Feb 2004; Mike Frysinger <vapier@gentoo.org> :
+ Version bump #40219 by Diego Garcia.
+
+ 24 Jan 2004; <gustavoz@gentoo.org> libgd-2.0.15-r1.ebuild:
+ marked stable on sparc
+
+ 10 Jan 2004; <agriffis@gentoo.org> libgd-1.8.4-r2.ebuild:
+ stable on ia64
+
+*libgd-2.0.17-r1 (31 Dec 2003)
+
+ 31 Dec 2003; Mike Frysinger <vapier@gentoo.org> :
+ Port the gif patch so as to not break some php installs.
+
+*libgd-2.0.17 (27 Dec 2003)
+
+ 27 Dec 2003; Mike Frysinger <vapier@gentoo.org> :
+ Version bump + optionalize jpeg/png/xpm/freetype #36271.
+
+*libgd-1.8.4-r2 (30 Jun 2003)
+
+ 24 Nov 2003; Aron Griffis <agriffis@gentoo.org> libgd-1.8.4-r2.ebuild:
+ Stable on alpha
+
+ 02 Oct 2003; Mike Frysinger <vapier@gentoo.org> :
+ Make jpeg support optional again and fix it so that it'll actually
+ compile when jpeg is not present #23648.
+
+ 10 Jul 2003; Christian Birchinger <joker@gentoo.org> libgd-1.8.4-r2.ebuild:
+ Added sparc stable keyword
+
+ 06 Jul 2003; Guy Martin <gmsoft@gentoo.org> libgd-1.8.4-r2.ebuild :
+ Marked stable on hppa.
+
+ 30 Jun 2003; Daniel Ahlberg <aliz@gentoo.org> libgd-1.8.4-r2.ebuild :
+ Force jpeg support or else analog fails to build if libgd is built without jpeg support.
+
+*libgd-2.0.15-r1 (26 Jun 2003)
+
+ 26 Jun 2003; Mike Frysinger <vapier@gentoo.org> :
+ mmm SLOT goodiness.
+
+*libgd-2.0.15 (17 Jun 2003)
+
+ 17 Jun 2003; Mike Frysinger <vapier@gentoo.org> :
+ Version bumped + grab gif patch from orig site.
+
+*libgd-2.0.12 (14 Apr 2003)
+
+ 14 Apr 2003; Mike Frysinger <vapier@gentoo.org> :
+ Version bumped + comment out gif patch till Nich can update.
+
+*libgd-2.0.11-r1 (20 Mar 2003)
+
+ 20 Mar 2003; Graham Forest <vladimir@gentoo.org> libgd-2.0.11-r1.ebuild:
+ Removed usage of pic USE flag
+
+*libgd-2.0.11 (23 Feb 2003)
+
+ 20 Mar 2003; Guy Martin <gmsoft@gentoo.org> libgd-2.0.11.ebuild, libgd-1.8.4.ebuild :
+ Added ~hppa to KEYWORDS.
+
+ 23 Feb 2003; Nicholas Wourms <dragon@gentoo.org> libgd-2.0.11.ebuild files/gd-2.0.11-gif-support.patch.bz2 :
+ Added patch for gif support when USE="gif". Added ~arch keywords to
+ correspond to the keywords from 1.8.4. This package also needed to be
+ elibtoolized. Also, this gd requires a modern libpng and freetype,
+ otherwise output won't look right. Changed dependancies to reflect
+ this.
+
+ 23 Feb 2003; Mike Frysinger <vapier@gentoo.org> :
+ Version bumpage.
+
+*libgd-2.0.1 (09 Sep 2002)
+
+ 14 Sep 2002; <mcummings@gentoo.org> :
+ bzip'd patch and moved to mirror
+
+ 09 Sep 2002; <mcummings@gentoo.org> :
+ Fixes bugs with perl versions using gd; corrects a few compile options
+
+*libgd-1.8.4-r1 (26 Jun 2003)
+
+ 26 Jun 2003; Mike Frysinger <vapier@gentoo.org> :
+ Added local USE flag 'ttf' to determine whether user wants
+ to use freetype-2.x (truetype) or freetype-1.x (ttf). Since
+ ttf is a local USE flag, we defer choice to ttf.
+
+ 26 Jun 2003; Mike Frysinger <vapier@gentoo.org> :
+ mmm SLOT goodiness.
+
+*libgd-1.8.4 (18 Feb 2003)
+
+ 24 May 2003; Tavis Ormandy <taviso@gentoo.org> libgd-1.8.3-r6.ebuild,
+ libgd-1.8.4.ebuild, files/gd-1.8.3-dec-alpha-compiler.diff,
+ files/gd-1.8.4-dec-alpha-compiler.diff:
+ makring alpha, also ccc fixes.
+
+ 18 May 2003; Martin Holzer <mholzer@gentoo.org> libgd-1.8.3-r6.ebuild,
+ libgd-1.8.4.ebuild:
+ Added USE flags. Closes #21059.
+
+ 20 Mar 2003; Guy Martin <gmsoft@gentoo.org> libgd-1.8.3-r6.ebuild :
+ Added hppa to KEYWORDS.
+
+ 18 Feb 2003; Robert Coie <rac@gentoo.org>; libgd-1.8.4.ebuild :
+ Based off of 1.8.3-r6, changed library defines HAVE_JPEG and
+ HAVE_PNG to HAVE_LIBJPEG and HAVE_LIBPNG to reflect upstream name
+ changes.
+
+*libgd-1.8.3-r6 (15 Jan 2003)
+
+ 07 Feb 2003; Brandon Low <lostlogic@gentoo.org>; libgd-1.8.3-r6.ebuild :
+ Fix to work with userpriv properly.
+
+ 04 Feb 2003; Seemant Kulleen <seemant@gentoo.org> libgd-1.8.3-r6.ebuild :
+ Removed dependency on sed-4 because it is buggy on ppc. Switched to
+ normal gnu-sed syntax. Closes bug #15022 by Rajiv Manglani
+ <rajiv@gentoo.org>
+
+ 15 Jan 2003; Brandon Low <lostlogic@gentoo.org> libgd-1.8.3-r6.ebuild:
+ Drop dependency on supersed, switch to >=sed-4.0. This is unstable on the
+ ppc pending the stability of sed-4 on the ppc.
+
+*libgd-1.8.3-r5 (12 Apr 2002)
+
+ 22 Apr 2003; Brandon Low <lostlogic@gentoo.org> libgd-1.8.3-r5.ebuild:
+ Change supersed dependencies
+
+ 22 Oct 2002; Seemant Kulleen <seemant@gentoo.org> libgd-1.8.3-r5.ebuid :
+ jpeg, X, and truetype turned into USE dependent support.
+
+ 07 Aug 2002; Mark Guertin <gerk@gentoo.org> :
+ Added ppc to keywords
+
+ 12 Apr 2002; Spider <spider@gentoo.org> libgd-1.8.3-r5.ebuild :
+ Updating revision with new libpng
+
+*libgd-1.8.3-r4 (03 Apr 2002)
+
+ 03 Apr 2002; Bruce A. Locke <blocke@shivan.org> libgd-1.8.3-r4.ebuild :
+ Quick fix for glibc circular dependencies.
+
+*libgd-1.8.3-r3 (27 Mar 2002)
+
+ 27 Mar 2002; Seemant Kulleen <seemant@gentoo.org> libgd-1.8.3-r3.ebuild :
+ Updated ebuild to modern syntax, and ungzipped HTML docs.
+
+*libgd-1.8.3-r2 (01 Feb 2002)
+
+ 01 Feb 2002; G.Bevin <gbevin@gentoo.org> ChangeLog :
+ Added initial ChangeLog which should be updated whenever the package is
+ updated in any way. This changelog is targetted to users. This means that the
+ comments should well explained and written in clean English. The details about
+ writing correct changelogs are explained in the skel.ChangeLog file which you
+ can find in the root directory of the portage repository.
diff --git a/media-libs/gd/Manifest b/media-libs/gd/Manifest
new file mode 100644
index 000000000000..7e0eed7f0a16
--- /dev/null
+++ b/media-libs/gd/Manifest
@@ -0,0 +1,20 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+MD5 5fc853fe46b82de1f4bda80b09121f3f ChangeLog 6602
+MD5 2a7f57d892474d14e4e077e4b1f49d57 gd-2.0.23.ebuild 1540
+MD5 312563b7288a2111976b24b0865d9df8 metadata.xml 1227
+MD5 0f2659489b21a96a49f5b75617710975 gd-2.0.26.ebuild 1371
+MD5 38d2090dfc2c201d4ae077164fb40e2c gd-1.8.4-r2.ebuild 2208
+MD5 09cc9995071652c954638c7ed2590dee files/1.8.4-jpeg-inc.patch 419
+MD5 0ec35953b2aff28b9684345befc9dc13 files/digest-gd-2.0.23 133
+MD5 1b0c2bb216ba3a29f024514a934ca995 files/digest-gd-1.8.4-r2 60
+MD5 c700ef06f9532087e4f27487633179a9 files/1.8.4-dec-alpha-compiler.diff 725
+MD5 e170e167d4c3799d6a5acba599bdc9f2 files/digest-gd-2.0.26 133
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.9.8 (GNU/Linux)
+
+iD8DBQFA4uGYHTu7gpaalycRArtIAJ9xJY9+465udel2QZLWpNuRI1SqjgCgtnyL
+3pHekRMUvpphZbsF/QHKsqE=
+=7DqB
+-----END PGP SIGNATURE-----
diff --git a/media-libs/gd/files/1.8.4-dec-alpha-compiler.diff b/media-libs/gd/files/1.8.4-dec-alpha-compiler.diff
new file mode 100644
index 000000000000..b63aeb62f709
--- /dev/null
+++ b/media-libs/gd/files/1.8.4-dec-alpha-compiler.diff
@@ -0,0 +1,21 @@
+diff -ru gd-1.8.3.orig/gd.c gd-1.8.3/gd.c
+--- gd-1.8.3.orig/gd.c 2000-06-03 20:26:12.000000000 +0100
++++ gd-1.8.3/gd.c 2003-05-24 20:04:41.000000000 +0100
+@@ -1,6 +1,3 @@
+-#ifndef _OSD_POSIX /* _OSD_POSIX defines *alloc() in stdlib.h */
+-#include <malloc.h>
+-#endif /*_OSD_POSIX*/
+ #include <stdio.h>
+ #include <math.h>
+ #include <string.h>
+diff -ru gd-1.8.3.orig/gdcache.h gd-1.8.3/gdcache.h
+--- gd-1.8.3.orig/gdcache.h 2000-06-03 20:26:12.000000000 +0100
++++ gd-1.8.3/gdcache.h 2003-05-24 20:04:55.000000000 +0100
+@@ -40,7 +40,6 @@
+ /* header */
+ /*********************************************************/
+
+-#include <malloc.h>
+ #ifndef NULL
+ #define NULL (void *)0
+ #endif
diff --git a/media-libs/gd/files/1.8.4-jpeg-inc.patch b/media-libs/gd/files/1.8.4-jpeg-inc.patch
new file mode 100644
index 000000000000..ed0b9615a04f
--- /dev/null
+++ b/media-libs/gd/files/1.8.4-jpeg-inc.patch
@@ -0,0 +1,17 @@
+--- gd_jpeg.c.orig 2003-10-08 10:24:43.000000000 -0400
++++ gd_jpeg.c 2003-10-08 10:24:57.000000000 -0400
+@@ -23,12 +23,12 @@
+ #include <limits.h>
+ #include <string.h>
+ /* 1.8.1: remove dependency on jinclude.h */
+-#include "jpeglib.h"
+-#include "jerror.h"
+ #include "gd.h"
+ #include "gdhelpers.h"
+
+ #ifdef HAVE_LIBJPEG
++#include "jpeglib.h"
++#include "jerror.h"
+
+ static const char * const GD_JPEG_VERSION = "2.0";
+
diff --git a/media-libs/gd/files/digest-gd-1.8.4-r2 b/media-libs/gd/files/digest-gd-1.8.4-r2
new file mode 100644
index 000000000000..e41c6df5c626
--- /dev/null
+++ b/media-libs/gd/files/digest-gd-1.8.4-r2
@@ -0,0 +1 @@
+MD5 2aef76e79f206f9798233f025f5dd28d gd-1.8.4.tar.gz 257631
diff --git a/media-libs/gd/files/digest-gd-2.0.23 b/media-libs/gd/files/digest-gd-2.0.23
new file mode 100644
index 000000000000..82fb9d6e6629
--- /dev/null
+++ b/media-libs/gd/files/digest-gd-2.0.23
@@ -0,0 +1,2 @@
+MD5 3bcd6daef3eb7b31ddc68a7d54b98c15 gd-2.0.23.tar.gz 544497
+MD5 a9979fcbabb0768ce0702a4ca9970e95 patch_gd2.0.21_gif_040120.gz 64932
diff --git a/media-libs/gd/files/digest-gd-2.0.26 b/media-libs/gd/files/digest-gd-2.0.26
new file mode 100644
index 000000000000..ca0b9362d582
--- /dev/null
+++ b/media-libs/gd/files/digest-gd-2.0.26
@@ -0,0 +1,2 @@
+MD5 e212bd6239be2e2941d2620b4df2da98 gd-2.0.26.tar.gz 557381
+MD5 41633ecdb514ebda7b6a3e11c0d18c44 patch_gd2.0.26_gif_040622.gz 64928
diff --git a/media-libs/gd/gd-1.8.4-r2.ebuild b/media-libs/gd/gd-1.8.4-r2.ebuild
new file mode 100644
index 000000000000..33327d8f412e
--- /dev/null
+++ b/media-libs/gd/gd-1.8.4-r2.ebuild
@@ -0,0 +1,92 @@
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/gd/gd-1.8.4-r2.ebuild,v 1.1 2004/06/30 15:51:26 vapier Exp $
+
+inherit eutils gcc
+
+DESCRIPTION="A graphics library for fast image creation"
+HOMEPAGE="http://www.boutell.com/gd/"
+SRC_URI="http://www.boutell.com/gd/http/${P}.tar.gz"
+
+LICENSE="as-is | BSD"
+SLOT="0"
+KEYWORDS="x86 ppc sparc hppa amd64 alpha ia64"
+IUSE="X truetype freetype-version-1 jpeg"
+
+DEPEND="media-libs/libpng
+ jpeg? ( media-libs/jpeg )
+ X? ( virtual/x11 )
+ freetype-version-1? ( =media-libs/freetype-1* )
+ !freetype-version-1? (
+ truetype? ( =media-libs/freetype-2* )
+ )"
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+
+ local compopts
+ local libsopts
+ local incopts
+
+ use alpha \
+ && [ "$(gcc-getCC)" == "ccc" ] \
+ && epatch ${FILESDIR}/${PV}-dec-alpha-compiler.diff
+
+ use X \
+ && compopts="${compopts} -DHAVE_XPM" \
+ && libsopts="${libsopts} -lXpm -lX11"
+ use jpeg \
+ && compopts="${compopts} -DHAVE_LIBJPEG" \
+ && libsopts="${libsopts} -ljpeg" \
+ || epatch ${FILESDIR}/${PV}-jpeg-inc.patch
+
+ compopts="${compopts} -DHAVE_LIBPNG"
+ libsopts="${libsopts} -lpng"
+
+ if use freetype-version-1 ; then
+ compopts="${compopts} -DHAVE_LIBTTF"
+ libsopts="${libsopts} -lttf"
+ incopts="-I/usr/include/freetype"
+ elif use truetype ; then
+ compopts="${compopts} -DHAVE_LIBFREETYPE"
+ libsopts="${libsopts} -lfreetype"
+ incopts="-I/usr/include/freetype2"
+ fi
+
+ sed -i \
+ -e "s:^\(CFLAGS\)=.*:\1=${CFLAGS} ${compopts} :" \
+ -e "s:^\(LIBS\)=.*:\1=-lm -lgd -lz ${libsopts}:" \
+ -e "s:^\(INCLUDEDIRS\)=:\1=${incopts} :" \
+ -e "s:\(COMPILER=\)gcc:\1${CC:-gcc}:" \
+ Makefile || die
+}
+
+src_compile() {
+ emake || die
+}
+
+src_install() {
+ dodir /usr/{bin,lib,include/gd-1}
+ make \
+ INSTALL_LIB=${D}/usr/lib \
+ INSTALL_BIN=${D}/usr/bin \
+ INSTALL_INCLUDE=${D}/usr/include/gd-1 \
+ install || die
+ preplib /usr
+
+ dodoc readme.txt
+ dohtml -r ./
+
+ # now make it slotable
+ mv ${D}/usr/lib/libgd{,1}.a
+ if `has_version =media-libs/gd-2*` ; then
+ rm -rf ${D}/usr/bin
+ else
+ dosym libgd1.a /usr/lib/libgd.a
+ cd ${D}/usr/include/gd-1/
+ for f in * ; do
+ dosym gd-1/${f} /usr/include/${f}
+ done
+ fi
+}
diff --git a/media-libs/gd/gd-2.0.23.ebuild b/media-libs/gd/gd-2.0.23.ebuild
new file mode 100644
index 000000000000..53ecdb314332
--- /dev/null
+++ b/media-libs/gd/gd-2.0.23.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/gd/gd-2.0.23.ebuild,v 1.1 2004/06/30 15:51:26 vapier Exp $
+
+inherit eutils
+
+GIF_PATCH=patch_gd2.0.21_gif_040120
+DESCRIPTION="A graphics library for fast image creation"
+HOMEPAGE="http://www.boutell.com/gd/ http://www.rime.com.au/gd/"
+SRC_URI="http://www.boutell.com/gd/http/${P}.tar.gz
+ gif? ( http://downloads.rhyme.com.au/gd/${GIF_PATCH}.gz )"
+
+LICENSE="as-is | BSD"
+SLOT="2"
+KEYWORDS="x86 ppc sparc mips alpha arm hppa amd64 ia64 s390"
+IUSE="jpeg png X truetype gif"
+
+DEPEND="jpeg? ( >=media-libs/jpeg-6b )
+ png? ( >=media-libs/libpng-1.2.5 sys-libs/zlib )
+ truetype? ( >=media-libs/freetype-2.1.5 )
+ X? ( virtual/x11 )"
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+ use gif && epatch ${WORKDIR}/${GIF_PATCH}
+}
+
+src_compile() {
+ local myconf=""
+ use truetype \
+ && myconf="${myconf} --with-freetype=yes" \
+ || myconf="${myconf} --with-freetype=no"
+ use png \
+ && myconf="${myconf} --with-png=yes" \
+ || myconf="${myconf} --with-png=no"
+ econf \
+ `use_with png` \
+ `use_with jpeg` \
+ `use_with X xpm` \
+ --includedir=/usr/include/gd-2 \
+ ${myconf} \
+ || die
+ emake || die
+}
+
+src_install() {
+ emake DESTDIR=${D} install || die
+ dodoc INSTALL README*
+ dohtml -r ./
+
+ # make it slotable
+ mv ${D}/usr/lib/libgd{,2}.a
+ dosed 's:libgd\.a:libgd2.a:' /usr/lib/libgd.la
+ dosym libgd2.a /usr/lib/libgd.a
+ cd ${D}/usr/include/gd-2/
+ for f in * ; do
+ dosym gd-2/${f} /usr/include/${f}
+ done
+}
diff --git a/media-libs/gd/gd-2.0.26.ebuild b/media-libs/gd/gd-2.0.26.ebuild
new file mode 100644
index 000000000000..ae18e1dce1bf
--- /dev/null
+++ b/media-libs/gd/gd-2.0.26.ebuild
@@ -0,0 +1,54 @@
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/gd/gd-2.0.26.ebuild,v 1.1 2004/06/30 15:51:26 vapier Exp $
+
+inherit eutils
+
+GIF_PATCH=patch_gd2.0.26_gif_040622
+DESCRIPTION="A graphics library for fast image creation"
+HOMEPAGE="http://www.boutell.com/gd/ http://www.rime.com.au/gd/"
+SRC_URI="http://www.boutell.com/gd/http/${P}.tar.gz
+ gif? ( http://downloads.rhyme.com.au/gd/${GIF_PATCH}.gz )"
+
+LICENSE="as-is | BSD"
+SLOT="2"
+KEYWORDS="~x86 ~ppc ~sparc ~mips ~alpha ~arm ~hppa ~amd64 ~ia64 ~s390"
+IUSE="jpeg png X truetype gif"
+
+DEPEND="jpeg? ( >=media-libs/jpeg-6b )
+ png? ( >=media-libs/libpng-1.2.5 sys-libs/zlib )
+ truetype? ( >=media-libs/freetype-2.1.5 )
+ X? ( virtual/x11 )"
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+ use gif && epatch ${WORKDIR}/${GIF_PATCH}
+}
+
+src_compile() {
+ econf \
+ `use_with png` \
+ `use_with truetype freetype` \
+ `use_with jpeg` \
+ `use_with X xpm` \
+ --includedir=/usr/include/gd-2 \
+ ${myconf} \
+ || die
+ emake || die
+}
+
+src_install() {
+ emake DESTDIR=${D} install || die
+ dodoc INSTALL README*
+ dohtml -r ./
+
+ # make it slotable
+ mv ${D}/usr/lib/libgd{,2}.a
+ dosed 's:libgd\.a:libgd2.a:' /usr/lib/libgd.la
+ dosym libgd2.a /usr/lib/libgd.a
+ cd ${D}/usr/include/gd-2/
+ for f in * ; do
+ dosym gd-2/${f} /usr/include/${f}
+ done
+}
diff --git a/media-libs/gd/metadata.xml b/media-libs/gd/metadata.xml
new file mode 100644
index 000000000000..d60bed021d59
--- /dev/null
+++ b/media-libs/gd/metadata.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>no-herd</herd>
+<maintainer>
+ <email>vapier@gentoo.org</email>
+ <name>Mike Frysinger</name>
+</maintainer>
+<longdescription>
+gd is a graphics library. It allows your code to quickly draw images complete
+with lines, arcs, text, multiple colors, cut and paste from other images, and
+flood fills, and write out the result as a PNG or JPEG file. This is particularly
+useful in World Wide Web applications, where PNG and JPEG are two of the formats
+accepted for inline images by most browsers.
+
+gd is not a paint program. If you are looking for a paint program, you are
+looking in the wrong place. If you are not a programmer, you are looking in the
+wrong place, unless you are installing a required library in order to run an
+application.
+
+gd does not provide for every possible desirable graphics operation. It is not
+necessary or desirable for gd to become a kitchen-sink graphics package, but
+version 2.0 does include most frequently requested features, including both
+truecolor and palette images, resampling (smooth resizing of truecolor images)
+and so forth.
+</longdescription>
+</pkgmetadata>