diff options
author | Mikhail Teterin <mi@FreeBSD.org> | 2007-02-13 06:46:59 +0000 |
---|---|---|
committer | Mikhail Teterin <mi@FreeBSD.org> | 2007-02-13 06:46:59 +0000 |
commit | f3015877b88f3272dfdba48573017e1e70423e83 (patch) | |
tree | f8628a1948d1de6861db8e13f547d52db59f6367 /www/websh/Makefile | |
parent | 4a338d1237adf2a55bd6a60300caf0e8756828da (diff) | |
download | ports-f3015877b88f3272dfdba48573017e1e70423e83.tar.gz ports-f3015877b88f3272dfdba48573017e1e70423e83.zip |
Notes
Diffstat (limited to 'www/websh/Makefile')
-rw-r--r-- | www/websh/Makefile | 98 |
1 files changed, 98 insertions, 0 deletions
diff --git a/www/websh/Makefile b/www/websh/Makefile new file mode 100644 index 000000000000..7bc9b79d1270 --- /dev/null +++ b/www/websh/Makefile @@ -0,0 +1,98 @@ +# New ports collection makefile for: mod_dtcl +# Date created: January 31, 2007 +# Whom: Mikhail Teterin <mi@aldan.algebra.com> +# +# $FreeBSD$ +# + +PORTNAME= websh +PORTVERSION= 3.6.0b4 +CATEGORIES= www tcl84 +MASTER_SITES= ${MASTER_SITE_APACHE} +MASTER_SITE_SUBDIR=tcl/${PORTNAME}/source +EXTRACT_SUFX= -src.tar.gz + +MAINTAINER= mi@aldan.algebra.com +COMMENT= Embeds a TCL8 interpreter in the Apache server + +LIB_DEPENDS= tcl${TCL_DVER}:${PORTSDIR}/lang/tcl${TCL_DVER} + +OPTIONS= WSMDEBUG "memory(n) and checkmem(n) commands in web-scripts" on +OPTIONS+= WSSTATIC "Link the objects into the module statically" off + +TCL_DVER= ${TCL_VER:S/.//} + +USE_TCL= yes +USE_AUTOTOOLS= autoconf:259 +WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}/src/unix +CONFIGURE_ARGS+=--with-tclinclude=${TCL_INCLUDEDIR} \ + --with-tcl=${TCL_LIBDIR} +USE_GMAKE= yes +INSTALLS_SHLIB= yes +SUB_FILES= httpd.conf pkgIndex.tcl pkg-message +SUB_LIST+= TCL_DVER=${TCL_DVER} WS_VER=${PORTVERSION:R} +SUB_LIST+= APACHEETCDIR=${APACHEETCDIR} APACHEMODDIR=${APACHEMODDIR} + +USE_APACHE= 1.3+ +CONFIGURE_ARGS+=--with-httpdinclude=`apxs -q includedir` + +CPPFLAGS+= -I ${LOCALBASE}/include/apr-1 +.if !defined(NO_WERROR) && ${CC} == "cc" || ${CC:T:Mgcc*} != "" +CPPFLAGS+= -Wall -Werror +.endif + +post-patch: + ${REINPLACE_CMD} -e 's,/usr/local/websh,${PREFIX},' \ + ${WRKSRC:H:H}/doc/mod_websh/conf/websh.conf + for p in ${WRKSRC:H:H}/doc/mod_websh/htdocs/*.html ; do \ + ${SED} -e 's,\.html,.whtml,g' < $$p > \ + `${DIRNAME} $$p`/`${BASENAME} $$p .html`.whtml; \ + done + ${REINPLACE_CMD} -e 's,\.html,.whtml,g' ${WRKSRC:H:H}/doc/mod_websh/htdocs/*.ws3 + +post-configure: + # "STUBS" are for wimps: + ${REINPLACE_CMD} -e 's,tclstub,tcl,' ${WRKSRC}/Makefile + +post-build test: + ${SETENV} LANG=C ${GMAKE} -C ${WRKSRC} test | ${AWK} '\ + /Failed/ && $$NF {failed=1} \ + END {exit failed} \ + {print}' + +do-install: + ${MKDIR} ${PREFIX}/lib/${PORTNAME} + ${INSTALL_DATA} ${WRKSRC:H:H}/doc/mod_websh/conf/*.ws3 \ + ${WRKDIR}/pkgIndex.tcl ${PREFIX}/lib/${PORTNAME}/ + ${INSTALL_DATA} ${WRKSRC:H:H}/doc/mod_websh/conf/websh.conf \ + ${PREFIX}/etc/websh.conf.dist + ${INSTALL_DATA} ${WRKSRC}/mod_websh${PORTVERSION}.so \ + ${PREFIX}/${APACHEMODDIR}/mod_websh.so + ${INSTALL_DATA} ${WRKSRC}/libwebsh${TCL_DVER}.so.1 ${PREFIX}/lib + ${LN} -sf ${PREFIX}/lib/libwebsh${TCL_DVER}.so.1 \ + ${PREFIX}/lib/libwebsh${TCL_DVER}.so +.if !defined(NOPORTDOCS) + ${MKDIR} ${EXAMPLESDIR} + ${INSTALL_DATA} ${WRKSRC:H:H}/doc/mod_websh/htdocs/*.ws3 \ + ${WRKSRC:H:H}/doc/mod_websh/htdocs/*.whtml \ + ${WRKDIR}/httpd.conf ${EXAMPLESDIR}/ + ${MKDIR} ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC:H:H}/doc/html/* ${DOCSDIR} +.endif + +post-install: + @${CAT} ${PKGMESSAGE} + +.include <bsd.port.pre.mk> + +.if defined(WITH_WSMDEBUG) +CFLAGS+= -DTCL_MEM_DEBUG +.endif + +.if defined(WITHOUT_WSSTATIC) +EXTRA_PATCHES= ${FILESDIR}/shared-patch +.endif + +CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" + +.include <bsd.port.post.mk> |