/[gentoo-x86]/app-doc/php-docs/php-docs-20101029.ebuild
Gentoo

Contents of /app-doc/php-docs/php-docs-20101029.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Sat Oct 30 10:14:24 2010 UTC (3 years, 8 months ago) by olemarkus
Branch: MAIN
CVS Tags: HEAD
Version bump. Also fixes bug 343289

(Portage version: 2.1.9.11/cvs/Linux x86_64)

1 # Copyright 1999-2010 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/app-doc/php-docs/php-docs-20101022.ebuild,v 1.1 2010/10/29 09:31:47 olemarkus Exp $
4
5 EAPI="3"
6
7 DESCRIPTION="HTML documentation for PHP"
8 HOMEPAGE="http://www.php.net/download-docs.php"
9
10 MY_PN="php_manual"
11
12 LICENSE="GPL-2"
13 SLOT="0"
14 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
15 IUSE=""
16
17 RESTRICT="strip binchecks"
18
19 LANGS="en de es fa fr ja pl pt_BR ro tr"
20 for lang in ${LANGS} ; do
21 IUSE="${IUSE} linguas_${lang}"
22 SRC_URI="${SRC_URI}
23 linguas_${lang}? ( http://olemarkus.org/~olemarkus/gentoo/${MY_PN}_${lang}-${PV}.tar.gz )"
24 done
25
26 # Set English to default
27 IUSE="${IUSE/linguas_en/+linguas_en}"
28
29 S=${WORKDIR}
30
31 src_unpack() {
32 for lang in ${LANGS} ; do
33 if use linguas_${lang} ; then
34 mkdir ${lang}
35 pushd ${lang} >/dev/null
36 unpack ${MY_PN}_${lang}-${PV}.tar.gz || die "unpack failed on ${lang}"
37 popd >/dev/null
38 fi
39 done
40 }
41
42 pkg_preinst() {
43 # remove broken/stale symlink created by previous ebuilds
44 [[ -L ${EROOT}/usr/share/php-docs ]] && rm -f "${EROOT}"/usr/share/php-docs
45 }
46
47 src_install() {
48 dodir /usr/share/doc/${PF}
49
50 for lang in ${LANGS} ; do
51 if use linguas_${lang} ; then
52 ebegin "Installing ${lang} manual, will take a while"
53 cp -R "${WORKDIR}"/${lang} "${ED}"/usr/share/doc/${PF} || die "cp failed on ${lang}"
54 eend $?
55 fi
56 done
57
58 einfo "Creating symlink to PHP manual at /usr/share/php-docs"
59 dosym /usr/share/doc/${PF} /usr/share/php-docs
60 }

  ViewVC Help
Powered by ViewVC 1.1.20