summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSeemant Kulleen <seemant@gentoo.org>2002-10-23 02:55:21 +0000
committerSeemant Kulleen <seemant@gentoo.org>2002-10-23 02:55:21 +0000
commit3eecb61273b5f884aba472210677be8b63b6debb (patch)
tree4bd2b8d7d99b096b400faeec99d698efd56950c6 /media-libs/libgd
parentsome fix0rs (diff)
downloadgentoo-2-3eecb61273b5f884aba472210677be8b63b6debb.tar.gz
gentoo-2-3eecb61273b5f884aba472210677be8b63b6debb.tar.bz2
gentoo-2-3eecb61273b5f884aba472210677be8b63b6debb.zip
use dependent stuffs
Diffstat (limited to 'media-libs/libgd')
-rw-r--r--media-libs/libgd/ChangeLog7
-rw-r--r--media-libs/libgd/libgd-1.8.3-r5.ebuild55
2 files changed, 43 insertions, 19 deletions
diff --git a/media-libs/libgd/ChangeLog b/media-libs/libgd/ChangeLog
index eab98f63eaa9..37294dfe51c9 100644
--- a/media-libs/libgd/ChangeLog
+++ b/media-libs/libgd/ChangeLog
@@ -1,6 +1,6 @@
# ChangeLog for media-libs/libgd
# Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL
-# $Header: /var/cvsroot/gentoo-x86/media-libs/libgd/ChangeLog,v 1.7 2002/09/14 12:39:18 mcummings Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/libgd/ChangeLog,v 1.8 2002/10/23 02:55:21 seemant Exp $
*libgd-2.0.1 (9 Sep 2002)
14 Sep 2002; <mcummings@gentoo.org> : bzip'd patch and moved to mirror
@@ -9,6 +9,11 @@
Fixes bugs with perl versions using gd; corrects a few compile options
*libgd-1.8.3-r5 (12 Apr 2002)
+
+ 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
diff --git a/media-libs/libgd/libgd-1.8.3-r5.ebuild b/media-libs/libgd/libgd-1.8.3-r5.ebuild
index ac2db43ab3d1..3cd13b66b427 100644
--- a/media-libs/libgd/libgd-1.8.3-r5.ebuild
+++ b/media-libs/libgd/libgd-1.8.3-r5.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2002 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/libgd/libgd-1.8.3-r5.ebuild,v 1.7 2002/10/05 05:39:15 drobbins Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/libgd/libgd-1.8.3-r5.ebuild,v 1.8 2002/10/23 02:55:21 seemant Exp $
IUSE="X"
@@ -14,27 +14,46 @@ SLOT="0"
LICENSE="as-is | BSD"
KEYWORDS="x86 ppc sparc sparc64"
-DEPEND=">=media-libs/jpeg-6b
- >=media-libs/libpng-1.0.7
- ~media-libs/freetype-1.3.1
- X? ( virtual/x11 )"
+DEPEND="sys-apps/supersed
+ media-libs/libpng
+ X? ( virtual/x11 )
+ jpeg? ( media-libs/jpeg )
+ truetype? ( =media-libs/freetype-1.3* )"
src_unpack() {
unpack ${A}
cd ${S}
- cp Makefile Makefile.orig
- if [ "`use X`" ]
+
+ local compopts
+ local libsopts
+
+ use X \
+ && compopts="${compopts} -DHAVE_XPM" \
+ && libsopts="${libsopts} -lXpm -lX11"
+
+ use jpeg \
+ && compopts="${compopts} -DHAVE_JPEG" \
+ && libsopts="${libsopts} -ljpeg"
+
+
+ compopts="${compopts} -DHAVE_PNG" \
+ libsopts="${libsopts} -lpng"
+
+ use truetype \
+ && compopts="${compopts} -DHAVE_LIBTTF" \
+ && libsopts="${libsopts} -lttf"
+
+ if use truetype
then
- sed -e "s/^\(CFLAGS\)=.*/\1=$CFLAGS -DHAVE_XPM -DHAVE_JPEG -DHAVE_LIBTTF -DHAVE_PNG /" \
- -e "s/^\(LIBS\)=.*/\1=-lm -lgd -lpng -lz -ljpeg -lttf -lXpm -lX11/" \
- -e "s/^\(INCLUDEDIRS\)=/\1=-I\/usr\/include\/freetype /" \
- Makefile.orig > Makefile
+ ssed -i -e "s:^\(CFLAGS\)=.*:\1=${CFLAGS} ${compopts} :" \
+ -e "s:^\(LIBS\)=.*:\1=-lm -lgd -lz ${libsopts}:" \
+ -e "s:^\(INCLUDEDIRS\)=:\1=-I/usr/include/freetype :" \
+ Makefile
else
- sed -e "s/^\(CFLAGS\)=.*/\1=$CFLAGS -DHAVE_JPEG -DHAVE_LIBTTF -DHAVE_PNG /" \
- -e "s/^\(LIBS\)=.*/\1=-lm -lgd -lpng -lz -ljpeg -lttf/" \
- -e "s/^\(INCLUDEDIRS\)=/\1=-I\/usr\/include\/freetype /" \
- Makefile.orig > Makefile
+ ssed -i -e "s:^\(CFLAGS\)=.*:\1=${CFLAGS} ${compopts} :" \
+ -e "s:^\(LIBS\)=.*:\1=-lm -lgd -lz ${libsopts}:" \
+ Makefile
fi
}
@@ -49,10 +68,10 @@ src_install() {
dodir /usr/{bin,lib,include}
- make \
- INSTALL_LIB=${D}/usr/lib \
+ make \
+ INSTALL_LIB=${D}/usr/lib \
INSTALL_BIN=${D}/usr/bin \
- INSTALL_INCLUDE=${D}/usr/include \
+ INSTALL_INCLUDE=${D}/usr/include \
install || die
preplib /usr