1 |
commit: 9f596dd27b058117a4f255a1346aa7e9928a5844 |
2 |
Author: Brian Evans <grknight <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jun 11 15:20:47 2018 +0000 |
4 |
Commit: Brian Evans <grknight <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Jun 11 15:20:47 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9f596dd2 |
7 |
|
8 |
Drop dead php-pear-r1 eclass |
9 |
|
10 |
Signed-off-by: Brian Evans <grknight <AT> gentoo.org> |
11 |
|
12 |
eclass/php-pear-r1.eclass | 122 ---------------------------------------------- |
13 |
1 file changed, 122 deletions(-) |
14 |
|
15 |
diff --git a/eclass/php-pear-r1.eclass b/eclass/php-pear-r1.eclass |
16 |
deleted file mode 100644 |
17 |
index 990ba379694..00000000000 |
18 |
--- a/eclass/php-pear-r1.eclass |
19 |
+++ /dev/null |
20 |
@@ -1,122 +0,0 @@ |
21 |
-# Copyright 1999-2018 Gentoo Foundation |
22 |
-# Distributed under the terms of the GNU General Public License v2 |
23 |
- |
24 |
-# @DEAD |
25 |
-# @ECLASS: php-pear-r1.eclass |
26 |
-# @MAINTAINER: |
27 |
-# Gentoo PHP Team <php-bugs@g.o> |
28 |
-# @AUTHOR: |
29 |
-# Author: Tal Peer <coredumb@g.o> |
30 |
-# Author: Luca Longinotti <chtekk@g.o> |
31 |
-# @BLURB: Provides means for an easy installation of PEAR packages. |
32 |
-# @DESCRIPTION: |
33 |
-# This eclass provides means for an easy installation of PEAR packages. |
34 |
-# For more information on PEAR, see http://pear.php.net/ |
35 |
-# Note that this eclass doesn't handle dependencies of PEAR packages |
36 |
-# on purpose; please use (R)DEPEND to define them correctly! |
37 |
- |
38 |
-inherit multilib |
39 |
- |
40 |
-EXPORT_FUNCTIONS pkg_setup src_install |
41 |
- |
42 |
-case "${EAPI:-0}" in |
43 |
- 0|1|2|3|4) |
44 |
- PHP_DEPEND="dev-lang/php" |
45 |
- ;; |
46 |
- 5|6) |
47 |
- # Repoman will complain about the missing slot in newer EAPIs. |
48 |
- PHP_DEPEND="dev-lang/php:*" |
49 |
- ;; |
50 |
- *) |
51 |
- die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" |
52 |
- ;; |
53 |
-esac |
54 |
- |
55 |
-DEPEND="${PHP_DEPEND} |
56 |
- >=dev-php/pear-1.8.1" |
57 |
-RDEPEND="${DEPEND}" |
58 |
- |
59 |
-# @ECLASS-VARIABLE: PHP_PEAR_PKG_NAME |
60 |
-# @DESCRIPTION: |
61 |
-# Set this if the the PEAR package name differs from ${PN/PEAR-/} |
62 |
-# (generally shouldn't be the case). |
63 |
-[[ -z "${PHP_PEAR_PKG_NAME}" ]] && PHP_PEAR_PKG_NAME="${PN/PEAR-/}" |
64 |
- |
65 |
-fix_PEAR_PV() { |
66 |
- local tmp="${PV}" |
67 |
- tmp="${tmp/_/}" |
68 |
- tmp="${tmp/rc/RC}" |
69 |
- tmp="${tmp/beta/b}" |
70 |
- tmp="${tmp/alpha/a}" |
71 |
- PEAR_PV="${tmp}" |
72 |
-} |
73 |
- |
74 |
-# @ECLASS-VARIABLE: PEAR_PV |
75 |
-# @DESCRIPTION: |
76 |
-# Set in ebuild if the eclass ${PV} mangling breaks SRC_URI for alpha/beta/rc versions |
77 |
-[[ -z "${PEAR_PV}" ]] && fix_PEAR_PV |
78 |
- |
79 |
-PEAR_PN="${PHP_PEAR_PKG_NAME}-${PEAR_PV}" |
80 |
-: ${PHP_PEAR_URI:=pear.php.net} |
81 |
-: ${PHP_PEAR_CHANNEL:=${FILESDIR}/channel.xml} |
82 |
- |
83 |
-[[ -z "${SRC_URI}" ]] && SRC_URI="http://${PHP_PEAR_URI}/get/${PEAR_PN}.tgz" |
84 |
-[[ -z "${HOMEPAGE}" ]] && HOMEPAGE="http://${PHP_PEAR_URI}/${PHP_PEAR_PKG_NAME}" |
85 |
- |
86 |
-S="${WORKDIR}/${PEAR_PN}" |
87 |
- |
88 |
-# @FUNCTION: php-pear-lib-r1_pkg_setup |
89 |
-# @DESCRIPTION: |
90 |
-# Adds required PEAR channel if necessary |
91 |
-php-pear-r1_pkg_setup() { |
92 |
- if [[ -f $PHP_PEAR_CHANNEL ]]; then |
93 |
- pear channel-add $PHP_PEAR_CHANNEL || einfo "Ignore any errors about existing channels" |
94 |
- fi |
95 |
-} |
96 |
- |
97 |
-# @FUNCTION: php-pear-r1_src_install |
98 |
-# @DESCRIPTION: |
99 |
-# Takes care of standard install for PEAR packages. |
100 |
-php-pear-r1_src_install() { |
101 |
- # SNMP support |
102 |
- addpredict /usr/share/snmp/mibs/.index |
103 |
- addpredict /var/lib/net-snmp/ |
104 |
- addpredict /var/lib/net-snmp/mib_indexes |
105 |
- addpredict /session_mm_cli0.sem |
106 |
- |
107 |
- PHP_BIN="/usr/bin/php" |
108 |
- |
109 |
- cd "${S}" |
110 |
- |
111 |
- # metadata_dir needs to be set relative to ${D} for >=dev-php/PEAR-PEAR-1.10 |
112 |
- if [[ -f "${WORKDIR}"/package2.xml ]] ; then |
113 |
- mv -f "${WORKDIR}/package2.xml" "${S}" |
114 |
- if has_version '>=dev-php/PEAR-PEAR-1.7.0' ; then |
115 |
- local WWW_DIR="/usr/share/webapps/${PN}/${PVR}/htdocs" |
116 |
- peardev -d php_bin="${PHP_BIN}" -d www_dir="${WWW_DIR}" -d metadata_dir="/usr/share/php" \ |
117 |
- install --force --loose --nodeps --offline --packagingroot="${D}" \ |
118 |
- "${S}/package2.xml" || die "Unable to install PEAR package" |
119 |
- else |
120 |
- peardev -d php_bin="${PHP_BIN}" install --force --loose --nodeps --offline --packagingroot="${D}" \ |
121 |
- "${S}/package2.xml" || die "Unable to install PEAR package" |
122 |
- fi |
123 |
- else |
124 |
- mv -f "${WORKDIR}/package.xml" "${S}" |
125 |
- if has_version '>=dev-php/PEAR-PEAR-1.7.0' ; then |
126 |
- local WWW_DIR="/usr/share/webapps/${PN}/${PVR}/htdocs" |
127 |
- peardev -d php_bin="${PHP_BIN}" -d www_dir="${WWW_DIR}" -d metadata_dir="/usr/share/php" \ |
128 |
- install --force --loose --nodeps --offline --packagingroot="${D}" \ |
129 |
- "${S}/package.xml" || die "Unable to install PEAR package" |
130 |
- else |
131 |
- peardev -d php_bin="${PHP_BIN}" install --force --loose --nodeps --offline --packagingroot="${D}" \ |
132 |
- "${S}/package.xml" || die "Unable to install PEAR package" |
133 |
- fi |
134 |
- fi |
135 |
- |
136 |
- rm -Rf "${D}/usr/share/php/.channels" \ |
137 |
- "${D}/usr/share/php/.depdblock" \ |
138 |
- "${D}/usr/share/php/.depdb" \ |
139 |
- "${D}/usr/share/php/.filemap" \ |
140 |
- "${D}/usr/share/php/.lock" \ |
141 |
- "${D}/usr/share/php/.registry" |
142 |
-} |