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

Contents of /app-doc/php-docs/php-docs-20071125-r2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.7 - (show annotations) (download)
Tue Dec 11 16:54:25 2007 UTC (6 years, 4 months ago) by nixnut
Branch: MAIN
CVS Tags: HEAD
Changes since 1.6: +2 -2 lines
Stable on ppc wrt bug 201438
(Portage version: 2.1.4_rc9)

1 # Copyright 1999-2007 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-20071125-r2.ebuild,v 1.6 2007/12/11 09:19:05 vapier Exp $
4
5 EAPI="1"
6
7 DESCRIPTION="HTML documentation for PHP"
8 HOMEPAGE="http://www.php.net/download-docs.php"
9
10 LICENSE="GPL-2"
11 SLOT="0"
12 KEYWORDS="alpha amd64 arm hppa ia64 ppc ppc64 s390 sh sparc x86 ~x86-fbsd"
13 IUSE="+linguas_en"
14 SRC_URI="linguas_en? ( http://dev.gentooexperimental.org/~jakub/distfiles/${P}_en.tar.gz
15 mirror://gentoo/${P}_en.tar.gz )"
16
17 RESTRICT="strip binchecks"
18
19 LANGS="cs da de el es fi fr he hu it ja ko nl pl pt_BR ro ru sk sv zh_CN zh_TW"
20 for lang in ${LANGS} ; do
21 IUSE="${IUSE} linguas_${lang}"
22 SRC_URI="${SRC_URI}
23 linguas_${lang}? ( http://dev.gentooexperimental.org/~jakub/distfiles/${P}_${lang}.tar.gz
24 mirror://gentoo/${P}_${lang}.tar.gz )"
25 done
26
27 S=${WORKDIR}
28
29 src_unpack() {
30 for lang in en ${LANGS} ; do
31 if use linguas_${lang} ; then
32 mkdir ${lang}
33 pushd ${lang} >/dev/null
34 unpack ${P}_${lang}.tar.gz || die "unpack failed on ${lang}"
35 popd >/dev/null
36 fi
37 done
38 }
39
40 pkg_preinst() {
41 # remove broken/stale symlink created by previous ebuilds
42 [[ -L ${ROOT}/usr/share/php-docs ]] && rm -f "${ROOT}"/usr/share/php-docs
43 }
44
45 src_install() {
46 dodir /usr/share/doc/${PF}
47
48 for lang in en ${LANGS} ; do
49 if use linguas_${lang} ; then
50 ebegin "Installing ${lang} manual, will take a while"
51 cp -R "${WORKDIR}"/${lang} "${D}"/usr/share/doc/${PF} || die "cp failed on ${lang}"
52 eend $?
53 fi
54 done
55
56 einfo "Creating symlink to PHP manual at /usr/share/php-docs"
57 dosym /usr/share/doc/${PF} /usr/share/php-docs
58 }

  ViewVC Help
Powered by ViewVC 1.1.20