This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
khosb/includes/pear/scripts/pecl.sh
2008-11-26 14:50:40 -08:00

29 lines
639 B
Bash

#!/bin/sh
# first find which PHP binary to use
if test "x$PHP_PEAR_PHP_BIN" != "x"; then
PHP="$PHP_PEAR_PHP_BIN"
else
if test "@php_bin@" = '@'php_bin'@'; then
PHP=php
else
PHP="@php_bin@"
fi
fi
# then look for the right pear include dir
if test "x$PHP_PEAR_INSTALL_DIR" != "x"; then
INCDIR=$PHP_PEAR_INSTALL_DIR
INCARG="-d include_path=$PHP_PEAR_INSTALL_DIR"
else
if test "@php_dir@" = '@'php_dir'@'; then
INCDIR=`dirname $0`
INCARG=""
else
INCDIR="@php_dir@"
INCARG="-d include_path=@php_dir@"
fi
fi
exec $PHP -C -n -q $INCARG -d output_buffering=1 -d safe_mode=0 $INCDIR/peclcmd.php "$@"