Lines 179-186
Link Here
|
179 |
php_init_slot_env ${slot} |
179 |
php_init_slot_env ${slot} |
180 |
|
180 |
|
181 |
# Let's put the default module away |
181 |
# Let's put the default module away |
182 |
insinto "${EXT_DIR}" |
182 |
insinto "${EXT_DIR#${EPREFIX}}" |
183 |
newins "modules/${PHP_EXT_NAME}.so" "${PHP_EXT_NAME}.so" || die "Unable to install extension" |
183 |
newins "modules/${PHP_EXT_NAME}$(get_modname)" "${PHP_EXT_NAME}$(get_modname)" || die "Unable to install extension" |
184 |
|
184 |
|
185 |
local doc |
185 |
local doc |
186 |
for doc in ${DOCS} ; do |
186 |
for doc in ${DOCS} ; do |
Lines 204-215
Link Here
|
204 |
php_init_slot_env() { |
204 |
php_init_slot_env() { |
205 |
libdir=$(get_libdir) |
205 |
libdir=$(get_libdir) |
206 |
|
206 |
|
207 |
PHPIZE="/usr/${libdir}/${1}/bin/phpize" |
207 |
PHPIZE="${EPREFIX}/usr/${libdir}/${1}/bin/phpize" |
208 |
PHPCONFIG="/usr/${libdir}/${1}/bin/php-config" |
208 |
PHPCONFIG="${EPREFIX}/usr/${libdir}/${1}/bin/php-config" |
209 |
PHPCLI="/usr/${libdir}/${1}/bin/php" |
209 |
PHPCLI="${EPREFIX}/usr/${libdir}/${1}/bin/php" |
210 |
PHPCGI="/usr/${libdir}/${1}/bin/php-cgi" |
210 |
PHPCGI="${EPREFIX}/usr/${libdir}/${1}/bin/php-cgi" |
211 |
PHP_PKG="$(best_version =dev-lang/php-${1:3}*)" |
211 |
PHP_PKG="$(best_version =dev-lang/php-${1:3}*)" |
212 |
PHPPREFIX="/usr/${libdir}/${slot}" |
212 |
PHPPREFIX="${EPREFIX}/usr/${libdir}/${slot}" |
213 |
EXT_DIR="$(${PHPCONFIG} --extension-dir 2>/dev/null)" |
213 |
EXT_DIR="$(${PHPCONFIG} --extension-dir 2>/dev/null)" |
214 |
PHP_CURRENTSLOT=${1:3} |
214 |
PHP_CURRENTSLOT=${1:3} |
215 |
|
215 |
|
Lines 226-232
Link Here
|
226 |
PHPINIFILELIST="" |
226 |
PHPINIFILELIST="" |
227 |
local x |
227 |
local x |
228 |
for x in ${PHPSAPILIST} ; do |
228 |
for x in ${PHPSAPILIST} ; do |
229 |
if [[ -f "/etc/php/${x}-${1}/php.ini" ]] ; then |
229 |
if [[ -f "${EPREFIX}/etc/php/${x}-${1}/php.ini" ]] ; then |
230 |
PHPINIFILELIST="${PHPINIFILELIST} etc/php/${x}-${1}/ext/${PHP_EXT_NAME}.ini" |
230 |
PHPINIFILELIST="${PHPINIFILELIST} etc/php/${x}-${1}/ext/${PHP_EXT_NAME}.ini" |
231 |
fi |
231 |
fi |
232 |
done |
232 |
done |
Lines 250-256
Link Here
|
250 |
local file |
250 |
local file |
251 |
if [[ "${PHP_EXT_INI}" = "yes" ]] ; then |
251 |
if [[ "${PHP_EXT_INI}" = "yes" ]] ; then |
252 |
for file in ${PHPINIFILELIST}; do |
252 |
for file in ${PHPINIFILELIST}; do |
253 |
php-ext-source-r2_addextension "${PHP_EXT_NAME}.so" "${file}" |
253 |
php-ext-source-r2_addextension "${PHP_EXT_NAME}$(get_modname)" "${file}" |
254 |
done |
254 |
done |
255 |
fi |
255 |
fi |
256 |
|
256 |
|
Lines 272-278
Link Here
|
272 |
done |
272 |
done |
273 |
|
273 |
|
274 |
# Add support for installing PHP files into a version dependant directory |
274 |
# Add support for installing PHP files into a version dependant directory |
275 |
PHP_EXT_SHARED_DIR="/usr/share/php/${PHP_EXT_NAME}" |
275 |
PHP_EXT_SHARED_DIR="${EPREFIX}/usr/share/php/${PHP_EXT_NAME}" |
276 |
done |
276 |
done |
277 |
} |
277 |
} |
278 |
|
278 |
|