1998-09-01 18:38:05 +00:00
|
|
|
#!/bin/sh
|
1999-12-28 10:17:34 +00:00
|
|
|
# $FreeBSD$
|
1998-09-01 18:38:05 +00:00
|
|
|
|
1999-08-26 21:18:15 +00:00
|
|
|
if [ "${BATCH}" ]; then
|
1999-08-30 10:56:07 +00:00
|
|
|
${MKDIR} ${WRKDIRPREFIX}${CURDIR}
|
1999-08-26 21:18:15 +00:00
|
|
|
${TOUCH} ${WRKDIRPREFIX}${CURDIR}/Makefile.inc
|
|
|
|
exit
|
|
|
|
fi
|
1998-12-23 00:44:50 +00:00
|
|
|
if [ -f ${WRKDIRPREFIX}${CURDIR}/Makefile.inc ]; then
|
1998-09-01 18:38:05 +00:00
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
1998-09-30 18:16:08 +00:00
|
|
|
/usr/bin/dialog --title "configuration options" --clear \
|
1998-09-01 18:38:05 +00:00
|
|
|
--checklist "\n\
|
1999-06-30 09:56:39 +00:00
|
|
|
Please select desired options:" -1 -1 14 \
|
1998-09-30 18:16:08 +00:00
|
|
|
tuning "Apache: performance tuning" OFF \
|
|
|
|
modssl "Apache: SSL support" OFF \
|
2000-02-27 21:14:28 +00:00
|
|
|
GD "PHP: GD library support" OFF \
|
|
|
|
FreeType "PHP: TrueType font rendering (implies GD)" OFF \
|
1999-08-16 18:41:13 +00:00
|
|
|
zlib "PHP: zlib library support" ON \
|
|
|
|
mcrypt "PHP: Encryption support" OFF \
|
|
|
|
mhash "PHP: Crypto-hashing support" OFF \
|
|
|
|
pdflib "PHP: pdflib support (implies zlib)" OFF \
|
|
|
|
IMAP "PHP: IMAP support" OFF \
|
|
|
|
MySQL "PHP: MySQL database support" ON \
|
|
|
|
PostgreSQL "PHP: PostgreSQL database support" OFF \
|
|
|
|
mSQL "PHP: mSQL database support" OFF \
|
|
|
|
dBase "PHP: dBase database support" OFF \
|
|
|
|
OpenLDAP "PHP: OpenLDAP support" OFF \
|
1999-08-26 22:09:39 +00:00
|
|
|
SNMP "PHP: SNMP support" OFF \
|
1999-08-26 15:03:52 +00:00
|
|
|
XML "PHP: XML support" OFF \
|
1998-12-23 00:44:50 +00:00
|
|
|
2> /tmp/checklist.tmp.$$
|
1998-09-01 18:38:05 +00:00
|
|
|
|
|
|
|
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
|
|
|
|
|
1999-08-30 10:56:07 +00:00
|
|
|
${MKDIR} ${WRKDIRPREFIX}${CURDIR}
|
1999-07-03 09:50:42 +00:00
|
|
|
exec > ${WRKDIRPREFIX}${CURDIR}/Makefile.inc
|
1998-09-01 18:38:05 +00:00
|
|
|
|
|
|
|
while [ "$1" ]; do
|
|
|
|
case $1 in
|
1998-09-30 18:16:08 +00:00
|
|
|
\"tuning\")
|
2000-02-25 23:53:06 +00:00
|
|
|
echo "CFLAGS+= -O6 -funroll-loops -fstrength-reduce -fomit-frame-pointer -fexpensive-optimizations -ffast-math"
|
|
|
|
echo "OPTIM+= -DBUFFERED_LOGS -DFD_SETSIZE=1024"
|
|
|
|
echo "CONFIGURE_ENV+= OPTIM='\${OPTIM}'"
|
1998-09-30 18:16:08 +00:00
|
|
|
;;
|
1998-09-01 18:38:05 +00:00
|
|
|
\"GD\")
|
1999-12-27 22:13:06 +00:00
|
|
|
echo "LIB_DEPENDS+= gd.0:\${PORTSDIR}/graphics/gd"
|
2000-01-25 16:52:23 +00:00
|
|
|
echo "PHP_CONF_ARGS+= --with-gd=shared,\${PREFIX}"
|
2000-02-27 21:14:28 +00:00
|
|
|
GD=1
|
|
|
|
;;
|
|
|
|
\"FreeType\")
|
|
|
|
echo "LIB_DEPENDS+= ttf.4:\${PORTSDIR}/print/freetype"
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "PHP_CONF_ARGS+= --with-ttf=\${PREFIX}"
|
2000-02-27 21:14:28 +00:00
|
|
|
if [ -z "$GD" ]; then
|
|
|
|
set $* \"GD\"
|
|
|
|
fi
|
1998-09-01 18:38:05 +00:00
|
|
|
;;
|
|
|
|
\"zlib\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "PHP_CONF_ARGS+= --with-zlib"
|
1999-07-30 21:07:03 +00:00
|
|
|
ZLIB=1
|
1998-09-01 18:38:05 +00:00
|
|
|
;;
|
1999-06-28 23:57:39 +00:00
|
|
|
\"mcrypt\")
|
2000-01-27 13:04:23 +00:00
|
|
|
echo "LIB_DEPENDS+= mcrypt-2.2.2:\${PORTSDIR}/security/libmcrypt"
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "PHP_CONF_ARGS+= --with-mcrypt=\${PREFIX}"
|
1999-06-28 23:57:39 +00:00
|
|
|
;;
|
|
|
|
\"mhash\")
|
1999-12-28 10:17:34 +00:00
|
|
|
echo "mhash is DISABLED for now. Ignoring." > /dev/stderr
|
|
|
|
;;
|
|
|
|
\"nothing\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "LIB_DEPENDS+= mhash.1:\${PORTSDIR}/security/mhash"
|
|
|
|
echo "PHP_CONF_ARGS+= --with-mhash=\${PREFIX}"
|
1999-06-28 23:57:39 +00:00
|
|
|
;;
|
1999-01-20 14:56:42 +00:00
|
|
|
\"pdflib\")
|
1999-08-20 20:28:37 +00:00
|
|
|
echo "pdflib is DISABLED for now. Ignoring." > /dev/stderr
|
|
|
|
;;
|
|
|
|
\"nothing\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "LIB_DEPENDS+= pdf.2:\${PORTSDIR}/print/pdflib"
|
|
|
|
echo "PHP_CONF_ARGS+= --with-pdflib=\${PREFIX} \\"
|
|
|
|
echo " --with-jpeg-dir=\${PREFIX} \\"
|
|
|
|
echo " --with-tiff-dir=\${PREFIX}"
|
1999-07-30 21:07:03 +00:00
|
|
|
if [ -z "$ZLIB" ]; then
|
|
|
|
set $* \"zlib\"
|
|
|
|
fi
|
1999-05-04 14:50:33 +00:00
|
|
|
;;
|
|
|
|
\"IMAP\")
|
1999-08-20 20:28:37 +00:00
|
|
|
echo "IMAP is DISABLED for now. Ignoring." > /dev/stderr
|
|
|
|
;;
|
|
|
|
\"nothing\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "BUILD_DEPENDS+= \${PREFIX}/lib/libc-client4.a:\${PORTSDIR}/mail/imap-uw"
|
|
|
|
echo "PHP_CONF_ARGS+= --with-imap=\${PREFIX}"
|
1999-01-20 14:56:42 +00:00
|
|
|
;;
|
1998-09-01 18:38:05 +00:00
|
|
|
\"MySQL\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "LIB_DEPENDS+= mysqlclient.6:\${PORTSDIR}/databases/mysql322-client"
|
2000-01-25 16:52:23 +00:00
|
|
|
echo "PHP_CONF_ARGS+= --with-mysql=shared,\${PREFIX}"
|
1998-09-01 18:38:05 +00:00
|
|
|
;;
|
1998-09-13 17:18:13 +00:00
|
|
|
\"PostgreSQL\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "BUILD_DEPENDS+= \${PREFIX}/pgsql/bin/psql:\${PORTSDIR}/databases/postgresql"
|
|
|
|
echo "PHP_CONF_ARGS+= --with-pgsql=\${PREFIX}/pgsql"
|
1998-09-01 18:38:05 +00:00
|
|
|
;;
|
|
|
|
\"mSQL\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "BUILD_DEPENDS+= msql:\${PORTSDIR}/databases/msql"
|
|
|
|
echo "PHP_CONF_ARGS+= --with-msql=\${PREFIX}"
|
1998-09-01 18:38:05 +00:00
|
|
|
;;
|
|
|
|
\"dBase\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "PHP_CONF_ARGS+= --with-dbase"
|
1998-12-23 00:44:50 +00:00
|
|
|
;;
|
|
|
|
\"OpenLDAP\")
|
1999-08-16 18:41:13 +00:00
|
|
|
echo "BUILD_DEPENDS+= \${PREFIX}/lib/libldap.a:\${PORTSDIR}/net/openldap"
|
|
|
|
echo "BUILD_DEPENDS+= \${PREFIX}/lib/liblber.a:\${PORTSDIR}/net/openldap"
|
|
|
|
echo "PHP_CONF_ARGS+= --with-ldap=\${PREFIX}"
|
1999-10-09 15:00:21 +00:00
|
|
|
if [ -f /usr/lib/libkrb.a -a -f /usr/lib/libdes.a ]; then
|
|
|
|
echo "CONFIGURE_ENV+= LIBS='-lkrb -ldes -L\${PREFIX}/lib'"
|
|
|
|
fi
|
1998-09-01 18:38:05 +00:00
|
|
|
;;
|
1999-08-26 22:09:39 +00:00
|
|
|
\"SNMP\")
|
1999-09-19 14:37:36 +00:00
|
|
|
echo "LIB_DEPENDS+= snmp.4:\${PORTSDIR}/net/ucd-snmp"
|
2000-01-25 16:52:23 +00:00
|
|
|
echo "PHP_CONF_ARGS+= --with-snmp=shared,\${PREFIX} --enable-ucd-snmp-hack"
|
1999-08-26 22:09:39 +00:00
|
|
|
;;
|
1999-08-26 15:03:52 +00:00
|
|
|
\"XML\")
|
|
|
|
echo "BUILD_DEPENDS+= \${PREFIX}/lib/libexpat.a:\${PORTSDIR}/textproc/expat"
|
|
|
|
echo "BUILD_DEPENDS+= \${PREFIX}/include/xml/xmlparse.h:\${PORTSDIR}/textproc/expat"
|
|
|
|
echo "BUILD_DEPENDS+= \${PREFIX}/include/xml/xmltok.h:\${PORTSDIR}/textproc/expat"
|
|
|
|
echo "PHP_CONF_ARGS+= --with-xml=\${PREFIX}"
|
1999-08-29 15:15:59 +00:00
|
|
|
;;
|
1998-09-30 18:16:08 +00:00
|
|
|
\"modssl\")
|
1999-07-03 09:50:42 +00:00
|
|
|
cat << EOF
|
1999-08-16 18:41:13 +00:00
|
|
|
PKGNAME= apache+php+mod_ssl-\${VERSION_APACHE}+\${VERSION_PHP}+\${VERSION_MODSSL}
|
1998-09-30 18:16:08 +00:00
|
|
|
DISTFILES+= mod_ssl-\${VERSION_MODSSL}-\${VERSION_APACHE}\${EXTRACT_SUFX}
|
|
|
|
|
2000-02-25 23:43:27 +00:00
|
|
|
USE_OPENSSL= RSA
|
|
|
|
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
|
|
|
|
BUILD_DEPENDS+= mm-config:\${PORTSDIR}/devel/mm \\
|
1999-06-08 10:28:05 +00:00
|
|
|
\${PREFIX}/lib/libmm.a:\${PORTSDIR}/devel/mm
|
1998-09-30 18:16:08 +00:00
|
|
|
|
2000-02-29 15:25:21 +00:00
|
|
|
VERSION_MODSSL= 2.6.1
|
1998-09-30 18:16:08 +00:00
|
|
|
|
1999-08-20 19:13:00 +00:00
|
|
|
CONFIGURE_ARGS+=--enable-module=ssl \\
|
1999-04-11 15:11:27 +00:00
|
|
|
--enable-module=define
|
1999-06-08 10:28:05 +00:00
|
|
|
CONFIGURE_ENV+= SSL_BASE='SYSTEM' EAPI_MM='SYSTEM' PATH="\${PREFIX}/bin:\${PATH}"
|
1998-09-30 18:16:08 +00:00
|
|
|
|
2000-02-25 23:43:27 +00:00
|
|
|
EXTRA_PATCHES+= \${PATCHDIR}/ssl_patch-aa
|
|
|
|
|
1998-09-30 18:16:08 +00:00
|
|
|
PLIST= \${PKGDIR}/PLIST.modssl
|
|
|
|
SSL= ssl
|
|
|
|
|
1999-04-11 15:11:27 +00:00
|
|
|
TYPE= test
|
|
|
|
CRT=
|
|
|
|
KEY=
|
|
|
|
|
1998-09-30 18:16:08 +00:00
|
|
|
pre-patch:
|
|
|
|
@cd \${WRKDIR}/mod_ssl-\${VERSION_MODSSL}-\${VERSION_APACHE} \\
|
|
|
|
&& \${ECHO_MSG} "===> Applying mod_ssl-\${VERSION_MODSSL} extension" \\
|
1998-12-23 00:44:50 +00:00
|
|
|
&& ./configure --with-apache=../\${DISTNAME} --expert
|
1998-09-30 18:16:08 +00:00
|
|
|
|
|
|
|
post-patch:
|
|
|
|
@cd \${WRKSRC} \\
|
|
|
|
&& find . -type f -name "*.orig" -print | xargs \${RM} -f
|
|
|
|
|
|
|
|
post-build:
|
|
|
|
@cd \${WRKSRC} \\
|
1998-12-23 00:44:50 +00:00
|
|
|
&& \${ECHO_MSG} "===> Creating Dummy Certificate for Server (SnakeOil)" \\
|
|
|
|
&& \${ECHO_MSG} " [use 'make certificate' to create a real one]" \\
|
1998-09-30 18:16:08 +00:00
|
|
|
&& \${MAKE} certificate TYPE=dummy >/dev/null 2>&1
|
|
|
|
|
|
|
|
certificate:
|
|
|
|
@cd \${WRKSRC} \\
|
|
|
|
&& \${ECHO_MSG} "===> Creating Test Certificate for Server" \\
|
|
|
|
&& \${MAKE} certificate TYPE=\$(TYPE) CRT=\$(CRT) KEY=\$(KEY)
|
1998-12-23 00:44:50 +00:00
|
|
|
|
1998-09-30 18:16:08 +00:00
|
|
|
EOF
|
|
|
|
;;
|
1998-09-01 18:38:05 +00:00
|
|
|
esac
|
|
|
|
shift
|
|
|
|
done
|