summaryrefslogtreecommitdiffstats
path: root/www/tclhttpd
diff options
context:
space:
mode:
authormi <mi@FreeBSD.org>2001-03-29 21:32:14 +0000
committermi <mi@FreeBSD.org>2001-03-29 21:32:14 +0000
commit2fb720ab6c9075e218b53a8642bb60d5a0b254b4 (patch)
tree5cba24e3586644af8cce9f3025b41d89ee21aee7 /www/tclhttpd
parent21df35e65c7d6f43ff79c08e10e04b1a08ae4721 (diff)
downloadFreeBSD-ports-2fb720ab6c9075e218b53a8642bb60d5a0b254b4.zip
FreeBSD-ports-2fb720ab6c9075e218b53a8642bb60d5a0b254b4.tar.gz
The previous commit by sobomax fixed the build, but quite terribly broke
the install. My version used the special Makefile only to build the binary lib. The installation was done by the software's Makefile. sobomax declared the custom Makefile.lib to be _the_ Makefile, which caused the library to be installed into /usr/lib :-) and completely missed the .tcl scripts, etc. I'm restoring the old behaviour with the build problem fixed (I hope). This version will also help tclhttpd find its docRoot on startup. It will also install tclhttpd.rc.default instead of tclhttpd.rc. If the latter does not exist, the former gets copied to create it. Submitted by: bento (and fenner's script)
Diffstat (limited to 'www/tclhttpd')
-rw-r--r--www/tclhttpd/Makefile24
-rw-r--r--www/tclhttpd/files/patch-ab5
-rw-r--r--www/tclhttpd/files/patch-ae13
-rw-r--r--www/tclhttpd/pkg-plist1
4 files changed, 27 insertions, 16 deletions
diff --git a/www/tclhttpd/Makefile b/www/tclhttpd/Makefile
index da549e1..2db6e7d 100644
--- a/www/tclhttpd/Makefile
+++ b/www/tclhttpd/Makefile
@@ -1,4 +1,4 @@
-# New ports collection makefile for: thttpd
+# New ports collection makefile for: tclhttpd
# Date created: 27 Apr 2000
# Whom: Mikhail Teterin <mi@aldan.algebra.com>
#
@@ -19,21 +19,20 @@ LIB_DEPENDS= tcl${TCL_VER}:${PORTSDIR}/lang/tcl${TCL_VER}
TCL_DVER?= 8.3
TCL_VER= ${TCL_DVER:S/.//}
-
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --with-tcl="${LOCALBASE}/lib/tcl${TCL_DVER}" \
--with-tclinclude="${LOCALBASE}/include/tcl${TCL_DVER}"
-MAKEFILE= ${FILESDIR}/Makefile.lib
-MAKE_ENV= TCL_DVER="${TCL_DVER}" FILESDIR="${FILESDIR}"
-MAKE_ARGS= -j2
+RCD= ${LOCALBASE}/etc/rc.d/tclhttpd.sh
+
+.include <bsd.port.pre.mk>
+SHLIB_NAME!= ${MAKE} -f "${FILESDIR}/Makefile.lib" ech
PLIST_SUB+= TCL_VER=${TCL_VER} PORTVERSION=${PORTVERSION} \
SHLIB_NAME=${SHLIB_NAME}
-RCD= ${LOCALBASE}/etc/rc.d/tclhttpd.sh
-
-.include <bsd.port.pre.mk>
-SHLIB_NAME!= ${MAKE} -f ${MAKEFILE} ech
+do-build:
+ cd ${WRKSRC} && ${MAKE_ENV} ${MAKE} -j 2 TCL_DVER="${TCL_DVER}" \
+ FILESDIR="${FILESDIR}" -f "${FILESDIR}/Makefile.lib"
pre-install:
${MKDIR} ${LOCALBASE}/tclhttpd/custom
@@ -43,14 +42,15 @@ post-install:
"s%COMMAND_LINE%${LOCALBASE}/bin/tclsh${TCL_DVER} ${PREFIX}/bin/httpd.tcl%" \
< ${FILESDIR}/tclhttpd.sh > ${RCD}
${CHOWN} -R nobody ${LOCALBASE}/share/${PORTNAME}${PORTVERSION}
- #${LN} -sf ${LOCALBASE}/share/${PORTNAME} \
- # ${LOCALBASE}/${PORTNAME}${PORTVERSION}/htdocs
${CHMOD} +x ${RCD}
${INSTALL_DATA} ${WRKSRC}/${SHLIB_NAME} \
${LOCALBASE}/lib/${PORTNAME}${PORTVERSION}/${SHLIB_NAME}
${INSTALL_SCRIPT} ${WRKSRC}/bin/httpd.tcl \
${WRKSRC}/bin/httpdthread.tcl ${LOCALBASE}/bin/
- ${INSTALL_DATA} ${WRKSRC}/bin/tclhttpd.rc ${LOCALBASE}/etc/
+ ${SED} 's%@VER@%${PORTVERSION}%g' < ${WRKSRC}/bin/tclhttpd.rc \
+ > ${LOCALBASE}/etc/tclhttpd.rc.default
+ cd ${LOCALBASE}/etc; test -e tclhttpd.rc || \
+ ${CP} -p tclhttpd.rc.default tclhttpd.rc
${SED} 's%@LIB@%${SHLIB_NAME}%g' < \
${FILESDIR}/pkgIndex.tcl >> \
${LOCALBASE}/lib/${PORTNAME}${PORTVERSION}/pkgIndex.tcl
diff --git a/www/tclhttpd/files/patch-ab b/www/tclhttpd/files/patch-ab
index 66988a6..86ec389 100644
--- a/www/tclhttpd/files/patch-ab
+++ b/www/tclhttpd/files/patch-ab
@@ -15,3 +15,8 @@
-install: all install-binaries install-libraries install-doc
+install: all install-libraries install-doc
+@@ -335,3 +335,3 @@
+ installdirs:
+- $(mkinstalldirs) $(pkglibdir) $(cryptlibdir) $(prefix)/bin $(htdocsdir) $(customdir)
++ $(mkinstalldirs) $(pkglibdir) $(prefix)/bin $(htdocsdir) $(customdir)
+
diff --git a/www/tclhttpd/files/patch-ae b/www/tclhttpd/files/patch-ae
index 0ecd38d..b560625 100644
--- a/www/tclhttpd/files/patch-ae
+++ b/www/tclhttpd/files/patch-ae
@@ -1,11 +1,16 @@
---- bin/tclhttpd.rc Mon Apr 24 21:39:19 2000
-+++ bin/tclhttpd.rc Fri Apr 28 19:23:21 2000
-@@ -36,3 +36,3 @@
+--- bin/tclhttpd.rc Mon Sep 25 18:47:35 2000
++++ bin/tclhttpd.rc Thu Mar 29 15:19:59 2001
+@@ -24,2 +24,4 @@
+ foreach d [list \
++ [file join [Config home] \
++ ../share/tclhttpd@VER@]] \
+ [file join [Config home] ../htdocs] \
+@@ -51,3 +53,3 @@
-Config uid 50
+Config uid 65534 ;# BSD's nobody
-@@ -45,3 +45,3 @@
+@@ -60,3 +62,3 @@
-Config gid 50
+Config gid 65534 ;# BSD's nobody group
diff --git a/www/tclhttpd/pkg-plist b/www/tclhttpd/pkg-plist
index a01d260..c2b4b8d 100644
--- a/www/tclhttpd/pkg-plist
+++ b/www/tclhttpd/pkg-plist
@@ -1,6 +1,7 @@
bin/httpd.tcl
bin/httpdthread.tcl
etc/tclhttpd.rc
+etc/tclhttpd.rc.default
etc/rc.d/tclhttpd.sh
lib/tclhttpd%%PORTVERSION%%/%%SHLIB_NAME%%
lib/tclhttpd%%PORTVERSION%%/admin.tcl
OpenPOWER on IntegriCloud