pkgsrc/www/php3/Makefile
jlam d7f69e47ce Instead of including bsd.pkg.install.mk directly in a package Makefile,
have it be automatically included by bsd.pkg.mk if USE_PKGINSTALL is set
to "YES".  This enforces the requirement that bsd.pkg.install.mk be
included at the end of a package Makefile.  Idea suggested by Julio M.
Merino Vidal <jmmv at menta.net>.
2003-01-28 22:03:00 +00:00

43 lines
1.1 KiB
Makefile

# $NetBSD: Makefile,v 1.39 2003/01/28 22:04:30 jlam Exp $
PKGNAME= php-${BASE_VERS}
PKGREVISION?= 2
CATEGORIES+= lang
COMMENT= HTML-embedded programming language
.include "Makefile.common"
USE_PERL5= build
CPPFLAGS+= -DPHP_INTERNAL_FUNCS
FILES_SUBST+= PHP_EXTENSION_DIR=${PHP_EXTENSION_DIR}
.if ${OPSYS} == Linux
LIBS+= -lnsl
.endif
CGIDIR= ${PREFIX}/libexec/cgi-bin
EGDIR= ${PREFIX}/share/examples/php3
DATADIR= ${PREFIX}/share/php3
USE_PKGINSTALL= yes
OWN_DIRS= ${PREFIX}/${PHP_EXTENSION_DIR}
CONF_FILES= ${EGDIR}/php3.ini.example ${PKG_SYSCONFDIR}/php3.ini
BUILD_DIRS= ${WRKSRC} ${WRKSRC}/convertor
pre-install:
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/php3.ini.example \
> ${WRKDIR}/php3.ini.example
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/php ${CGIDIR}/php
${INSTALL_PROGRAM} ${WRKSRC}/convertor/convertor \
${PREFIX}/bin/php2convert
${LN} -sf ${CGIDIR}/php ${PREFIX}/bin/php
${INSTALL_DATA_DIR} ${DATADIR} ${EGDIR}
cd ${WRKSRC}/extra/icons; ${INSTALL_DATA} * ${DATADIR}
cd ${WRKSRC}/examples; ${INSTALL_DATA} README* *.php3 ${EGDIR}
${INSTALL_DATA} ${WRKDIR}/php3.ini.example ${EGDIR}
.include "../../mk/bsd.pkg.mk"