diff options
author | Edwin Groothuis <edwin@FreeBSD.org> | 2006-04-06 00:34:34 +0000 |
---|---|---|
committer | Edwin Groothuis <edwin@FreeBSD.org> | 2006-04-06 00:34:34 +0000 |
commit | 000de2cf3bcc49c65ec8102876b4f74de4bc0ea7 (patch) | |
tree | ace770fa6e9d0245e1ec92cdb6ff88cbabc8676c /shells/wapsh | |
parent | audio/cd-console - Fix MASTER_SITE and WWW (make fetchable) (diff) |
shells/wapsh - update, make fetchable, take maintainership
- Upgrade to latest version (make fetchable again)
- Add WWW line and more supported phones to pkg-descr
- Single PLIST file addition
- Replace rc.d script with new rc.subr-style
- Install in more appropriate place
- Take maintainership
PR: ports/94243
Submitted by: Shaun Amott <shaun@inerd.com>
Notes
Notes:
svn path=/head/; revision=158921
Diffstat (limited to 'shells/wapsh')
-rw-r--r-- | shells/wapsh/Makefile | 97 | ||||
-rw-r--r-- | shells/wapsh/distinfo | 6 | ||||
-rw-r--r-- | shells/wapsh/files/htshd.sh | 20 | ||||
-rw-r--r-- | shells/wapsh/files/htshd.sh.in | 18 | ||||
-rw-r--r-- | shells/wapsh/files/patch-htshd::htshd.c | 72 | ||||
-rw-r--r-- | shells/wapsh/files/pkg-message.in | 11 | ||||
-rw-r--r-- | shells/wapsh/pkg-descr | 7 | ||||
-rw-r--r-- | shells/wapsh/pkg-plist | 35 |
8 files changed, 111 insertions, 155 deletions
diff --git a/shells/wapsh/Makefile b/shells/wapsh/Makefile index 44bbaa3bf91e..ad94b71518b0 100644 --- a/shells/wapsh/Makefile +++ b/shells/wapsh/Makefile @@ -5,41 +5,46 @@ # $FreeBSD$ # -PORTNAME= wapsh -PORTVERSION= 1.0 -PORTREVISION= 1 -CATEGORIES= shells -MASTER_SITES= http://www.exolution.de/wapsh/ -DISTNAME= ${PORTNAME}_${PORTVERSION} - -MAINTAINER= ports@FreeBSD.org -COMMENT= A system to allow remote shell logins via a WAP phone or web browser - -WRKSRC= ${WRKDIR}/${DISTNAME:S/_/-/} -SUB_FILES= pkg-message -PKGMESSAGE= ${WRKDIR}/pkg-message - -USERGUIDEDOCS= Image10.jpg Image11.jpg Image12.jpg Image13.jpg \ - Image14.jpg Image15.jpg Image16.jpg Image17.jpg \ - Image18.jpg Image19.jpg Image20.jpg Image21.jpg \ - Image22.jpg Image23.jpg Image24.jpg Image25.gif \ - Image26.jpg Image27.jpg Image28.jpg Image29.jpg \ - Image30.jpg Image31.jpg Image32.jpg Image33.jpg \ - Image34.jpg Image35.jpg Image36.jpg Image37.jpg \ - Image38.jpg Image39.jpg Image4.gif Image40.jpg \ - Image41.jpg Image42.jpg Image43.jpg Image44.jpg \ - Image45.jpg Image46.jpg Image47.jpg Image48.jpg \ - Image49.jpg Image5.gif Image50.gif Image51.jpg \ - Image52.jpg Image53.gif Image54.jpg Image55.jpg \ - Image56.jpg Image6.jpg Image7.jpg Image8.jpg \ - Image9.jpg index.html - -HTDOCS= command.php command_html.inc command_wml.inc \ - common.inc common_html.inc common_wml.inc \ - controls_wml.php displayfuncs.inc getloginhosts.inc \ - history_edit_wml.php history_html.php history_wml.php \ - login_html.php login_wml.php scroll_wml.php \ - shortcuts_wml.php +PORTNAME= wapsh +PORTVERSION= 1.0.1 +CATEGORIES= shells +MASTER_SITES= http://www.exolution.de/geschaeft/produkte/wapsh/ +DISTNAME= ${PORTNAME}_${PORTVERSION} + +MAINTAINER= shaun@inerd.com +COMMENT= A system to allow remote shell logins via a WAP phone or web browser + +USE_RC_SUBR= htshd.sh + +WRKSRC= ${WRKDIR}/${DISTNAME:S/_/-/} + +WWWOWN?= www +WWWGRP?= www +WWWDIR?= www/data/${PORTNAME} +DATADIR= ${PREFIX}/${WWWDIR} +SUB_FILES= pkg-message + +USERGUIDEDOCS= Image10.jpg Image11.jpg Image12.jpg Image13.jpg \ + Image14.jpg Image15.jpg Image16.jpg Image17.jpg \ + Image18.jpg Image19.jpg Image20.jpg Image21.jpg \ + Image22.jpg Image23.jpg Image24.jpg Image25.gif \ + Image26.jpg Image27.jpg Image28.jpg Image29.jpg \ + Image30.jpg Image31.jpg Image32.jpg Image33.jpg \ + Image34.jpg Image35.jpg Image36.jpg Image37.jpg \ + Image38.jpg Image39.jpg Image4.gif Image40.jpg \ + Image41.jpg Image42.jpg Image43.jpg Image44.jpg \ + Image45.jpg Image46.jpg Image47.jpg Image48.jpg \ + Image49.jpg Image5.gif Image50.gif Image51.jpg \ + Image52.jpg Image53.gif Image54.jpg Image55.jpg \ + Image56.jpg Image6.jpg Image7.jpg Image8.jpg \ + Image9.jpg index.html + +HTDOCS= command.php command_html.inc command_wml.inc \ + common.inc common_html.inc common_wml.inc \ + controls_wml.php displayfuncs.inc getloginhosts.inc \ + history_edit_wml.php history_html.php history_wml.php \ + login_html.php login_wml.php scroll_wml.php \ + shortcuts_wml.php index.html post-patch: @${SED} -e 's,%%PREFIX%%,${PREFIX},g' ${WRKSRC}/htshd/htshd.c > ${WRKDIR}/foo && \ @@ -49,6 +54,19 @@ do-build: (cd ${WRKSRC}/htshd && ${CC} ${CFLAGS} -o htshd htshd.c -lcrypt \ -lutil -DUSE_DEV_RANDOM=1 -DHAVE_SETENV) +pre-install: + @${ECHO_MSG} "----------------------------------------------------------------" + @${ECHO_MSG} "Set WWWDIR to the location of your web server's document root," + @${ECHO_MSG} "relative to ${PREFIX}" + @${ECHO_MSG} "" + @${ECHO_MSG} "${PORTNAME} will be installed under ${PREFIX}/\$$WWWDIR/" + @${ECHO_MSG} "" + @${ECHO_MSG} "The current value of WWWDIR is: ${WWWDIR}" + @${ECHO_MSG} "" + @${ECHO_MSG} "Press CTRL+C now to change it." + @${ECHO_MSG} "----------------------------------------------------------------" + @sleep 2 + do-install: ${INSTALL_PROGRAM} ${WRKSRC}/htshd/htshd ${PREFIX}/sbin @@ -61,10 +79,11 @@ do-install: fi .endfor - ${MKDIR} ${PREFIX}/share/wapsh/htdocs + ${MKDIR} ${DATADIR} .for H in ${HTDOCS} - ${INSTALL_DATA} ${WRKSRC}/htdocs/$H ${PREFIX}/share/wapsh/htdocs + ${INSTALL_DATA} ${WRKSRC}/htdocs/$H ${DATADIR} .endfor + ${CHOWN} -R ${WWWOWN}:${WWWGRP} ${DATADIR} .if !defined(NOPORTDOCS) ${MKDIR} ${DOCSDIR}/admin_guide @@ -89,10 +108,6 @@ post-install: @${ECHO} "updating /etc/services" @${CP} /etc/services /etc/services.bak @(${GREP} -v ^htsh /etc/services.bak; ${ECHO_CMD} "htsh 3001/tcp # htsh/wapsh server") > /etc/services - @if [ ! -f ${PREFIX}/etc/rc.d/htshd.sh ]; then \ - ${ECHO} "===> Installing ${PREFIX}/etc/rc.d/htshd.sh startup file."; \ - ${INSTALL_SCRIPT} ${FILESDIR}/htshd.sh ${PREFIX}/etc/rc.d/htshd.sh; \ - fi @${CAT} ${PKGMESSAGE} .include <bsd.port.mk> diff --git a/shells/wapsh/distinfo b/shells/wapsh/distinfo index 49212eb1a5a4..be6889caf3e6 100644 --- a/shells/wapsh/distinfo +++ b/shells/wapsh/distinfo @@ -1,3 +1,3 @@ -MD5 (wapsh_1.0.tar.gz) = 4e836a2edd189d3301ca6fa7ba52cafb -SHA256 (wapsh_1.0.tar.gz) = aab2b3ef5b3b497785cd281682c5d9ef20e8780a9b1ba97f279c4d59e742d3f1 -SIZE (wapsh_1.0.tar.gz) = 3552353 +MD5 (wapsh_1.0.1.tar.gz) = dc5efdfffd7fc8b4a610b160585113ff +SHA256 (wapsh_1.0.1.tar.gz) = 49ee84ed6e92e747931a090a2804d933bac31f4c92eda66ee091ad9698d5aef7 +SIZE (wapsh_1.0.1.tar.gz) = 3547292 diff --git a/shells/wapsh/files/htshd.sh b/shells/wapsh/files/htshd.sh deleted file mode 100644 index 8013945fd7a9..000000000000 --- a/shells/wapsh/files/htshd.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh - -if ! PREFIX=$(expr $0 : "\(/.*\)/etc/rc\.d/$(basename $0)\$"); then - echo "$0: Cannot determine the PREFIX" >&2 - exit 1 -fi - -case "$1" in -start) - [ -x "${PREFIX}/sbin/htshd" -a -f "${PREFIX}/etc/wapsh/htshd.conf" ] && ${PREFIX}/sbin/htshd -f ${PREFIX}/etc/wapsh/htshd.conf > /dev/null && echo -n ' htshd' - ;; -stop) - killall htshd && echo -n ' htshd' - ;; -*) - echo "Usage: `basename $0` {start|stop}" >&2 - ;; -esac - -exit 0 diff --git a/shells/wapsh/files/htshd.sh.in b/shells/wapsh/files/htshd.sh.in new file mode 100644 index 000000000000..54aaee5022f2 --- /dev/null +++ b/shells/wapsh/files/htshd.sh.in @@ -0,0 +1,18 @@ +#!/bin/sh + +# PROVIDE: htshd +# REQUIRE: DAEMON +# BEFORE: LOGIN + +. %%RC_SUBR%% + +name="htshd" +rcvar=`set_rcvar` +load_rc_config $name + +htshd_enable=${htshd_enable:-"NO"} + +command="%%PREFIX%%/sbin/htshd" +required_files="%%PREFIX%%/etc/wapsh/htshd.conf" + +run_rc_command "$1" diff --git a/shells/wapsh/files/patch-htshd::htshd.c b/shells/wapsh/files/patch-htshd::htshd.c index 48b1a6a49edf..8af522dd3581 100644 --- a/shells/wapsh/files/patch-htshd::htshd.c +++ b/shells/wapsh/files/patch-htshd::htshd.c @@ -13,75 +13,3 @@ /* Default name of global user initialisation file */ #define RCFILE ".htshrc" /* Name of user-specific initialisation file -@@ -3572,39 +3572,38 @@ - usage(void) - { - if (!weAreDaemon) { -- fprintf(stderr, --"htsh options are: ---b numbytes Specify upper limit for per-user shell output buffers -- (Default: %d bytes) ---c numbytes Maximum number of bytes to be transferred at a time -- between Client Shell and HTTP Server. -- (Default: %d bytes, minimum setting %d bytes) ---d Run in debug mode ---D [y|n] If argument is 'y' run as daemon, otherwise ('n') -- do not daemonise. -- (If run from inetd, htsh is always a daemon. If run from a -- shell, htsh is a daemon by default) ---f config-file Use named file for startup configuration, instead of %s ---F Do not use standard configuration file (%s) ---h Display this help message ---g global-init-file Use named file as login initialisation file for all user -- logins. (Default: %s) ---H http-server Specify HTTP server from which connections will -- be accepted. (Can be specified multiple times) ---L log-file-dir Record script(1) style log of each login session -- in named directory ---o numsecs Timeout for shell output (Default: %3.1f seconds, -- minimum: %3.1f, maximum: %4.1f seconds) ---p port-num Specify TCP port on which htsh should listen for -- connections. (Default is %s in /etc/services) ---P 'proto-name... ' Specify list of allowed login protocols -- (can be '%s' and or '%s' ---t numsecs Timeout for shell input (Default: %d seconds) ---u username Specify user who is allowed to login to htsh -- (Can be repeated multiple times) -- --The -c, -D, -o, -p, and -t options override corresponding options in the --configuration file. The -h and -u options are additive with corresponding -+ fprintf(stderr, "htsh options are: \n\ -+-b numbytes Specify upper limit for per-user shell output buffers \n\ -+ (Default: %d bytes)\n\ -+-c numbytes Maximum number of bytes to be transferred at a time \n\ -+ between Client Shell and HTTP Server. \n\ -+ (Default: %d bytes, minimum setting %d bytes)\n\ -+-d Run in debug mode\n\ -+-D [y|n] If argument is 'y' run as daemon, otherwise ('n')\n\ -+ do not daemonise. \n\ -+ (If run from inetd, htsh is always a daemon. If run from a \n\ -+ shell, htsh is a daemon by default)\n\ -+-f config-file Use named file for startup configuration, instead of %s\n\ -+-F Do not use standard configuration file (%s)\n\ -+-h Display this help message\n\ -+-g global-init-file Use named file as login initialisation file for all user\n\ -+ logins. (Default: %s)\n\ -+-H http-server Specify HTTP server from which connections will \n\ -+ be accepted. (Can be specified multiple times)\n\ -+-L log-file-dir Record script(1) style log of each login session\n\ -+ in named directory\n\ -+-o numsecs Timeout for shell output (Default: %3.1f seconds, \n\ -+ minimum: %3.1f, maximum: %4.1f seconds)\n\ -+-p port-num Specify TCP port on which htsh should listen for \n\ -+ connections. (Default is %s in /etc/services)\n\ -+-P 'proto-name... ' Specify list of allowed login protocols \n\ -+ (can be '%s' and or '%s'\n\ -+-t numsecs Timeout for shell input (Default: %d seconds)\n\ -+-u username Specify user who is allowed to login to htsh\n\ -+ (Can be repeated multiple times)\n\ -+\n\ -+The -c, -D, -o, -p, and -t options override corresponding options in the\n\ -+configuration file. The -h and -u options are additive with corresponding\n\ - options in the configuration file\n", - DEF_OUTPUT_BUFFER_LIMIT, - DEF_CS_MAX_TRANSFER_SIZE, CS_MAX_TRANSFER_SIZE_LOW_BOUND, diff --git a/shells/wapsh/files/pkg-message.in b/shells/wapsh/files/pkg-message.in index 6228883b3740..13148eb610ae 100644 --- a/shells/wapsh/files/pkg-message.in +++ b/shells/wapsh/files/pkg-message.in @@ -1,3 +1,14 @@ +------------------------------------------------------------------------ +wapsh/htsh is now installed. + +Sample configuration files can be found in %%PREFIX%%/etc/wapsh + +PHP scripts for both HTTP and WAP access have been installed in +%%DATADIR%% + +Please read the installed documentation for information on how to create +the configuration files. +------------------------------------------------------------------------ wapsh/htsh is now installed. diff --git a/shells/wapsh/pkg-descr b/shells/wapsh/pkg-descr index 1ce365b09854..417249fedaff 100644 --- a/shells/wapsh/pkg-descr +++ b/shells/wapsh/pkg-descr @@ -6,9 +6,14 @@ The following phones and emulators have been successfully tested with htsh: * Nokia 6210 * Nokia 7110 - * Siemens C35 and S35 + * Motorola Timeport P7389 + * Siemens C35 and S35, S45, S55 + * Samsung SCH-20 + * Sony CMD-J5 * Nokia WAP Toolkit 2.0 "Blueprint" phone emulator * UP.Simulator 4.0 from Phone.com We welcome feedback (at wapsh@exolution.de) from users about their experiences using other phone types. + +WWW: http://www.exolution.de/geschaeft/produkte/wapsh.en.htm diff --git a/shells/wapsh/pkg-plist b/shells/wapsh/pkg-plist index 8599b1bb713f..1342fb9b9284 100644 --- a/shells/wapsh/pkg-plist +++ b/shells/wapsh/pkg-plist @@ -1,5 +1,4 @@ sbin/htshd -etc/rc.d/htshd.sh @unexec if cmp -s %D/etc/wapsh/htsh_profile %D/etc/wapsh/htsh_profile.dist; then rm -f %D/etc/wapsh/htsh_profile; fi etc/wapsh/htsh_profile.dist @exec [ -f %B/htsh_profile ] || cp %B/%f %B/htsh_profile @@ -9,22 +8,23 @@ etc/wapsh/htshd.conf.dist @unexec if cmp -s %D/etc/wapsh/loginhosts %D/etc/wapsh/loginhosts.dist; then rm -f %D/etc/wapsh/loginhosts; fi etc/wapsh/loginhosts.dist @exec [ -f %B/loginhosts ] || cp %B/%f %B/loginhosts -%%DATADIR%%/htdocs/command.php -%%DATADIR%%/htdocs/command_html.inc -%%DATADIR%%/htdocs/command_wml.inc -%%DATADIR%%/htdocs/common.inc -%%DATADIR%%/htdocs/common_html.inc -%%DATADIR%%/htdocs/common_wml.inc -%%DATADIR%%/htdocs/controls_wml.php -%%DATADIR%%/htdocs/displayfuncs.inc -%%DATADIR%%/htdocs/getloginhosts.inc -%%DATADIR%%/htdocs/history_edit_wml.php -%%DATADIR%%/htdocs/history_html.php -%%DATADIR%%/htdocs/history_wml.php -%%DATADIR%%/htdocs/login_html.php -%%DATADIR%%/htdocs/login_wml.php -%%DATADIR%%/htdocs/scroll_wml.php -%%DATADIR%%/htdocs/shortcuts_wml.php +%%DATADIR%%/command.php +%%DATADIR%%/command_html.inc +%%DATADIR%%/command_wml.inc +%%DATADIR%%/common.inc +%%DATADIR%%/common_html.inc +%%DATADIR%%/common_wml.inc +%%DATADIR%%/controls_wml.php +%%DATADIR%%/displayfuncs.inc +%%DATADIR%%/getloginhosts.inc +%%DATADIR%%/history_edit_wml.php +%%DATADIR%%/history_html.php +%%DATADIR%%/history_wml.php +%%DATADIR%%/index.html +%%DATADIR%%/login_html.php +%%DATADIR%%/login_wml.php +%%DATADIR%%/scroll_wml.php +%%DATADIR%%/shortcuts_wml.php %%PORTDOCS%%%%DOCSDIR%%/Image1.jpg %%PORTDOCS%%%%DOCSDIR%%/Image2.jpg %%PORTDOCS%%%%DOCSDIR%%/Image3.jpg @@ -94,5 +94,4 @@ etc/wapsh/loginhosts.dist %%PORTDOCS%%@dirrm %%DOCSDIR%%/implementation_notes %%PORTDOCS%%@dirrm %%DOCSDIR%%/user_guide %%PORTDOCS%%@dirrm %%DOCSDIR%% -@dirrm %%DATADIR%%/htdocs @dirrm %%DATADIR%% |