Gentoo Archives: gentoo-commits

From: "Raul Porcel (armin76)" <armin76@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-php5/jpgraph: ChangeLog jpgraph-2.3.ebuild
Date: Mon, 24 Dec 2007 14:45:41
Message-Id: E1J6oYf-00062L-It@stork.gentoo.org
1 armin76 07/12/24 14:45:33
2
3 Modified: ChangeLog
4 Added: jpgraph-2.3.ebuild
5 Log:
6 Version bump from the php-overlay
7 (Portage version: 2.1.3.19)
8
9 Revision Changes Path
10 1.27 dev-php5/jpgraph/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-php5/jpgraph/ChangeLog?rev=1.27&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-php5/jpgraph/ChangeLog?rev=1.27&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-php5/jpgraph/ChangeLog?r1=1.26&r2=1.27
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/dev-php5/jpgraph/ChangeLog,v
19 retrieving revision 1.26
20 retrieving revision 1.27
21 diff -u -r1.26 -r1.27
22 --- ChangeLog 14 Nov 2007 15:27:16 -0000 1.26
23 +++ ChangeLog 24 Dec 2007 14:45:33 -0000 1.27
24 @@ -1,6 +1,14 @@
25 # ChangeLog for dev-php5/jpgraph
26 # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/dev-php5/jpgraph/ChangeLog,v 1.26 2007/11/14 15:27:16 jer Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/dev-php5/jpgraph/ChangeLog,v 1.27 2007/12/24 14:45:33 armin76 Exp $
29 +
30 +*jpgraph-2.3 (24 Dec 2007)
31 +
32 + 24 Dec 2007; Raúl Porcel <armin76@g.o> +jpgraph-2.3.ebuild:
33 + Version bump from the php-overlay
34 +
35 + 21 Dec 2007; Jakub Moc <jakub@g.o> +jpgraph-2.3.ebuild:
36 + Version bump
37
38 14 Nov 2007; Jeroen Roovers <jer@g.o> jpgraph-2.2.ebuild:
39 Stable for HPPA (bug #198564).
40
41
42
43 1.1 dev-php5/jpgraph/jpgraph-2.3.ebuild
44
45 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-php5/jpgraph/jpgraph-2.3.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-php5/jpgraph/jpgraph-2.3.ebuild?rev=1.1&content-type=text/plain
47
48 Index: jpgraph-2.3.ebuild
49 ===================================================================
50 # Copyright 1999-2007 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/dev-php5/jpgraph/jpgraph-2.3.ebuild,v 1.1 2007/12/24 14:45:33 armin76 Exp $
53
54 inherit php-lib-r1 eutils
55
56 KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~sparc ~x86"
57
58 DESCRIPTION="Fully OO graph drawing library for PHP."
59 HOMEPAGE="http://www.aditus.nu/jpgraph/"
60 SRC_URI="http://hem.bredband.net/jpgraph2/${P}.tar.gz"
61 LICENSE="QPL-1.0"
62 SLOT="0"
63 IUSE="truetype"
64
65 DEPEND=""
66 RDEPEND="truetype? ( media-fonts/corefonts )"
67
68 need_php_by_category
69
70 [[ -z "${JPGRAPH_CACHEDIR}" ]] && JPGRAPH_CACHEDIR="/var/cache/jpgraph-php5/"
71
72 pkg_setup() {
73 has_php
74
75 # we need the PHP GD functionality
76 require_gd
77
78 # check to wich user:group the cache dir will go
79 if has_version "www-servers/apache" ; then
80 HTTPD_USER="apache"
81 HTTPD_GROUP="apache"
82 einfo "Configuring ${JPGRAPH_CACHEDIR} for Apache."
83 else
84 HTTPD_USER="${HTTPD_USER:-root}"
85 HTTPD_GROUP="${HTTPD_GROUP:-root}"
86 ewarn "No Apache webserver detected - ${JPGRAPH_CACHEDIR} will be"
87 ewarn "owned by ${HTTPD_USER}:${HTTPD_GROUP} instead."
88 ewarn "It this is not what you want, you can define"
89 ewarn "HTTPD_USER and HTTPD_GROUP variables and re-emerge ${PN}."
90 epause 3
91 fi
92 }
93
94 src_install() {
95 # some patches to adapt the config to Gentoo
96 einfo "Patching jpg-config.inc.php"
97
98 # patch 1:
99 # make jpgraph use the correct group for file permissions
100
101 sed -i "s|^DEFINE(\"CACHE_FILE_GROUP\",\"wwwadmin\");|DEFINE(\"CACHE_FILE_GROUP\",\"${HTTPD_GROUP}\");|" src/jpg-config.inc.php \
102 || die "sed failed in patch 1"
103
104 # patch 2:
105 # make jpgraph use the correct directory for caching
106
107 sed -i "s|.*DEFINE(\"CACHE_DIR\",\"/tmp/jpgraph_cache/\");|DEFINE(\"CACHE_DIR\",\"${JPGRAPH_CACHEDIR}\");|" src/jpg-config.inc.php \
108 || die "sed failed in patch 2"
109
110 # patch 3:
111 # make jpgraph use the correct directory for the corefonts if the truetype USE flag is set
112
113 if use truetype ; then
114 sed -i "s|.*DEFINE(\"TTF_DIR\",\"/usr/X11R6/lib/X11/fonts/truetype/\");|DEFINE(\"TTF_DIR\",\"/usr/share/fonts/corefonts/\");|" src/jpg-config.inc.php \
115 || die "sed failed in patch 3"
116 fi
117
118 # patch 4:
119 # disable READ_CACHE in jpgraph
120
121 sed -i "s|^DEFINE(\"READ_CACHE\",true);|DEFINE(\"READ_CACHE\",false);|" src/jpg-config.inc.php \
122 || die "sed failed in patch 4"
123
124 # install php files
125 einfo "Building list of files to install"
126 php-lib-r1_src_install src `cd src ; find . -type f -print`
127
128 # install documentation
129 einfo "Installing documentation"
130 dodoc-php README
131 insinto /usr/share/doc/${CATEGORY}/${PF}
132 doins -r docs/*
133
134 # setup the cache dir
135 einfo "Setting up the cache dir"
136 keepdir "${JPGRAPH_CACHEDIR}"
137 fowners ${HTTPD_USER}:${HTTPD_GROUP} "${JPGRAPH_CACHEDIR}"
138 fperms 750 "${JPGRAPH_CACHEDIR}"
139 }
140
141
142
143 --
144 gentoo-commits@g.o mailing list