/[gentoo-x86]/media-libs/gd/gd-2.0.35-r3.ebuild
Gentoo

Contents of /media-libs/gd/gd-2.0.35-r3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.18 - (show annotations) (download)
Sat May 5 08:02:43 2012 UTC (2 years, 3 months ago) by jdhore
Branch: MAIN
Changes since 1.17: +2 -2 lines
dev-util/pkgconfig -> virtual/pkgconfig

(Portage version: 2.2.0_alpha101/cvs/Linux i686)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/media-libs/gd/gd-2.0.35-r3.ebuild,v 1.17 2012/04/26 21:37:16 aballier Exp $
4
5 EAPI="2"
6
7 inherit autotools eutils
8
9 DESCRIPTION="A graphics library for fast image creation"
10 HOMEPAGE="http://libgd.org/ http://www.boutell.com/gd/"
11 SRC_URI="http://libgd.org/releases/${P}.tar.bz2"
12
13 LICENSE="as-is BSD"
14 SLOT="2"
15 KEYWORDS="alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
16 IUSE="fontconfig jpeg png static-libs truetype xpm zlib"
17
18 RDEPEND="fontconfig? ( media-libs/fontconfig )
19 jpeg? ( virtual/jpeg )
20 png? ( >=media-libs/libpng-1.2:0 )
21 truetype? ( >=media-libs/freetype-2.1.5 )
22 xpm? ( x11-libs/libXpm x11-libs/libXt )
23 zlib? ( sys-libs/zlib )"
24 DEPEND="${RDEPEND}
25 virtual/pkgconfig"
26
27 src_prepare() {
28 epatch "${FILESDIR}"/${P}-libpng14.patch #305101
29 epatch "${FILESDIR}"/${P}-maxcolors.patch #292130
30 epatch "${FILESDIR}"/${P}-fontconfig.patch #363367
31 epatch "${FILESDIR}"/${P}-libpng-pkg-config.patch
32
33 # Avoid programs we never install
34 local make_sed=( -e '/^noinst_PROGRAMS/s:noinst:check:' )
35 use png || make_sed+=( -e '/_PROGRAMS/s:(gdparttopng|gdtopng|gd2topng|pngtogd|pngtogd2|webpng)::g' )
36 use zlib || make_sed+=( -e '/_PROGRAMS/s:(gd2topng|gd2copypal|gd2togif|giftogd2|gdparttopng|pngtogd2)::g' )
37 sed -i -r "${make_sed[@]}" Makefile.am || die
38
39 cat <<-EOF > acinclude.m4
40 m4_ifndef([AM_ICONV],[m4_define([AM_ICONV],[:])])
41 EOF
42
43 eautoreconf
44 }
45
46 src_configure() {
47 export ac_cv_lib_z_deflate=$(usex zlib)
48 # we aren't actually {en,dis}abling X here ... the configure
49 # script uses it just to add explicit -I/-L paths which we
50 # don't care about on Gentoo systems.
51 econf \
52 --without-x \
53 $(use_enable static-libs static) \
54 $(use_with fontconfig) \
55 $(use_with png) \
56 $(use_with truetype freetype) \
57 $(use_with jpeg) \
58 $(use_with xpm)
59 }
60
61 src_install() {
62 emake DESTDIR="${D}" install || die
63 dodoc INSTALL README*
64 dohtml -r ./
65 use static-libs || rm -f "${D}"/usr/*/libgd.la
66 }

  ViewVC Help
Powered by ViewVC 1.1.20