1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-27 21:29:02 +00:00
freebsd-ports/www/mod_php5/scripts/configure.php
Andreas Klemm 1e60a28d98 - update port to newest apache (1.3.1) and php (3.0.3) version
- change maintainer to Dirk Froemberg <ibex@physik.TU-Berlin.DE>, since
  he is now the driving force
- totally revamped configuration (dialog based as in ghostscript)
- make portlint happy (andreas@FreeBSD.ORG), APACHE_VER and PHP3_VER
  variable has to appear later in Makefile, not in front of DISTNAME
  and PKGNAME
Submitted by:	Dirk Froemberg <ibex@physik.TU-Berlin.DE>
1998-09-01 18:38:05 +00:00

63 lines
1.6 KiB
Bash

#!/bin/sh
if [ -f ${CURDIR}/Makefile.inc ]; then
exit
fi
/usr/bin/dialog --title "PHP configuration options" --clear \
--checklist "\n\
Please select desired options:" -1 -1 9 \
GD "GD library support" ON \
zlib "zlib library support" ON \
MySQL "MySQL database support" ON \
PostgresSQL "PostgresSQL database support" OFF \
mSQL "mSQL database support" OFF \
dBase "dBase database support" OFF 2> /tmp/checklist.tmp.$$
retval=$?
if [ -s /tmp/checklist.tmp.$$ ]; then
set `cat /tmp/checklist.tmp.$$`
fi
rm -f /tmp/checklist.tmp.$$
case $retval in
0) if [ -z "$*" ]; then
echo "Nothing selected"
fi
;;
1) echo "Cancel pressed."
exit 1
;;
esac
> ${CURDIR}/Makefile.inc
while [ "$1" ]; do
case $1 in
\"GD\")
echo "BUILD_DEPENDS+= \${PREFIX}/lib/libgd.a:\${PORTSDIR}/graphics/gd" >> ${CURDIR}/Makefile.inc
echo "PHP3_CONF_ARGS+= --with-gd" >> ${CURDIR}/Makefile.inc
;;
\"zlib\")
echo "PHP3_CONF_ARGS+= --with-zlib" >> ${CURDIR}/Makefile.inc
;;
\"MySQL\")
echo "BUILD_DEPENDS+= mysql:\${PORTSDIR}/databases/mysql" >> ${CURDIR}/Makefile.inc
echo "PHP3_CONF_ARGS+= --with-mysql=\${PREFIX}" >> ${CURDIR}/Makefile.inc
;;
\"PostgresSQL\")
echo "BUILD_DEPENDS+= \${PREFIX}/pgsql/bin/psql:\${PORTSDIR}/databases/postgresql" >> ${CURDIR}/Makefile.inc
echo "PHP3_CONF_ARGS+= --with-pgsql=\${PREFIX}/pgsql" >> ${CURDIR}/Makefile.inc
;;
\"mSQL\")
echo "BUILD_DEPENDS+= msql:\${PORTSDIR}/databases/msql" >> ${CURDIR}/Makefile.inc
echo "PHP3_CONF_ARGS+= --with-msql=\${PREFIX}" >> ${CURDIR}/Makefile.inc
;;
\"dBase\")
echo "PHP3_CONF_ARGS+= --with-dbase" >> ${CURDIR}/Makefile.inc
;;
esac
shift
done