summaryrefslogtreecommitdiff
path: root/inputmethod/ja-freewnn-lib/files
diff options
context:
space:
mode:
Diffstat (limited to 'inputmethod/ja-freewnn-lib/files')
-rw-r--r--inputmethod/ja-freewnn-lib/files/INSTALL24
-rw-r--r--inputmethod/ja-freewnn-lib/files/ja_freewnn34
2 files changed, 58 insertions, 0 deletions
diff --git a/inputmethod/ja-freewnn-lib/files/INSTALL b/inputmethod/ja-freewnn-lib/files/INSTALL
new file mode 100644
index 00000000000..5b0b37e7686
--- /dev/null
+++ b/inputmethod/ja-freewnn-lib/files/INSTALL
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+case $2 in
+PRE-INSTALL)
+ uid=`id -u ${WNNOWNER} 2> /dev/null`
+ if [ X"$uid" != X ]; then
+ exit 0
+ fi
+
+ wnn_uid=69
+ uid=`id -u $wnn_uid 2> /dev/null`
+ if [ X"$uid" != X ]; then
+ wnn_uid=32768
+ while id -u $wnn_uid > /dev/null 2>&1; do
+ wnn_uid=`echo $wnn_uid+1|bc`
+ if [ $wnn_uid = 65536 ]; then
+ exit 1
+ fi
+ done
+ fi
+ chpass -l -a "${WNNOWNER}:*:$wnn_uid:1::0:0:User Wnn:/nonexistent:/sbin/nologin"
+ exit $?
+ ;;
+esac
diff --git a/inputmethod/ja-freewnn-lib/files/ja_freewnn b/inputmethod/ja-freewnn-lib/files/ja_freewnn
new file mode 100644
index 00000000000..83859ef6907
--- /dev/null
+++ b/inputmethod/ja-freewnn-lib/files/ja_freewnn
@@ -0,0 +1,34 @@
+#!/bin/sh
+#
+# $NetBSD: ja_freewnn,v 1.1.1.1 2002/05/31 13:00:48 seb Exp $
+#
+# PROVIDE: freewnn
+# REQUIRE: DAEMON
+
+. /etc/rc.subr
+
+name="freewnn"
+command_start="@PREFIX@/sbin/jserver"
+command_stop="@PREFIX@/sbin/wnnkill"
+pidfile=""
+
+cmd=${1:-start}
+
+case ${cmd} in
+start)
+ if [ -x ${command_start} ]; then
+ echo "Starting ${name}."
+ ${command_start} >/dev/null 2>&1
+ fi
+ ;;
+stop)
+ if [ -x ${command_stop} ]; then
+ echo "Stopping ${name}."
+ ${command_stop} >/dev/null 2>&1
+ fi
+ ;;
+*)
+ :
+ ;;
+esac
+exit 0