aboutsummaryrefslogtreecommitdiff
path: root/japanese
diff options
context:
space:
mode:
authorAkinori MUSHA <knu@FreeBSD.org>2001-01-06 18:54:10 +0000
committerAkinori MUSHA <knu@FreeBSD.org>2001-01-06 18:54:10 +0000
commit91cfe10d515dec397f134f5689180df3d8bfa87b (patch)
treefb5f46111480e2b91b766482a050ee34aa747554 /japanese
parent3cc329279eafafcaa410b0a4d097281aa02e8838 (diff)
downloadports-91cfe10d515dec397f134f5689180df3d8bfa87b.tar.gz
ports-91cfe10d515dec397f134f5689180df3d8bfa87b.zip
Notes
Diffstat (limited to 'japanese')
-rw-r--r--japanese/Makefile1
-rw-r--r--japanese/slirc/Makefile29
-rw-r--r--japanese/slirc/distinfo2
-rw-r--r--japanese/slirc/files/README.ja65
-rw-r--r--japanese/slirc/files/patch-editor.sl109
-rw-r--r--japanese/slirc/files/patch-init.sl11
-rw-r--r--japanese/slirc/files/patch-slirc.c40
-rw-r--r--japanese/slirc/files/patch-vfile-module.c50
-rw-r--r--japanese/slirc/files/patch-windoze.c44
9 files changed, 351 insertions, 0 deletions
diff --git a/japanese/Makefile b/japanese/Makefile
index fa75336eeb16..3643efa3307e 100644
--- a/japanese/Makefile
+++ b/japanese/Makefile
@@ -287,6 +287,7 @@
SUBDIR += skkfep
SUBDIR += skkinput
SUBDIR += skkserv
+ SUBDIR += slirc
SUBDIR += slrn
SUBDIR += srd-fpw
SUBDIR += srd-fpw-package
diff --git a/japanese/slirc/Makefile b/japanese/slirc/Makefile
new file mode 100644
index 000000000000..7a2c384fd986
--- /dev/null
+++ b/japanese/slirc/Makefile
@@ -0,0 +1,29 @@
+# New ports collection makefile for: SLirc-ja
+# Date created: 6 Jan 2001
+# Whom: Akinori MUSHA aka knu <knu@idaemons.org>
+#
+# $FreeBSD$
+#
+
+CATEGORIES= japanese
+
+MAINTAINER= knu@FreeBSD.org
+
+MASTERDIR= ${.CURDIR}/../../irc/slirc
+
+MD5_FILE= ${.CURDIR}/distinfo
+EXTRA_FILESDIR= ${.CURDIR}/files
+EXTRA_PATCHES= ${EXTRA_FILESDIR}/patch-*
+
+SLANG_INCDIR= ${PREFIX}/include/slang
+LIB_DEPENDS_LIBSLANG?= slang.2:${PORTSDIR}/japanese/libslang
+
+MAKE_ARGS_JA= KANJI="-DKANJI"
+PLIST_JA= ""
+
+DOCS= README.ja
+
+post-patch:
+ ${CP} ${EXTRA_FILESDIR}/README.ja ${WRKSRC}/
+
+.include "${MASTERDIR}/Makefile"
diff --git a/japanese/slirc/distinfo b/japanese/slirc/distinfo
new file mode 100644
index 000000000000..63142b282fc8
--- /dev/null
+++ b/japanese/slirc/distinfo
@@ -0,0 +1,2 @@
+MD5 (slirc-0.12.tgz) = d5210681b5719d095ffa7f683e98860c
+MD5 (slirc-0.11.10ja6.patch.gz) = eaa93a712efdd43a831c2541ef796248
diff --git a/japanese/slirc/files/README.ja b/japanese/slirc/files/README.ja
new file mode 100644
index 000000000000..0ff92f6deda6
--- /dev/null
+++ b/japanese/slirc/files/README.ja
@@ -0,0 +1,65 @@
+
+SLirc 0.11.10ja6
+$BI~It(B $BE590(B <tnh@aurora.dti.ne.jp>
+
+SLirc$B$K$D$$$F(B
+$B%*%j%8%J%k$+$i$NJQ99(B
+$B%3%s%Q%$%k!&4D6-@_Dj(B
+$BIT6q9g!?%P%0(B
+$B$=$NB>(B
+
+SLirc$B$K$D$$$F(B
+
+Dave Cridland $B;a$H(B Stan Brooks $B;a$K$h$k(B IRC Client $B$G$9!#(B
+$BFCD'$H$7$F(B
+
+o $BB.$/$F2wE,(B
+o $B%+%i%U%k$G$+$C$3$$$$(B
+o S-lang $B8@8l$G3HD%$G$-$k(B
+
+$B$H$$$&$b$N$,$"$j$^$9!#(B
+$BF|K\8lBP1~(B SLirc $B$O(B SLirc $B$rF|K\8lBP1~$K$7$?$b$N$G$9!#(B
+
+
+$B%*%j%8%J%k$+$i$NJQ99(B
+
+IRC $B%5!<%P$HF|K\8l$NAw<u?.$,$G$-$^$9!#(B
+$BF~NO%P%C%U%!$GF|K\8l$,@5>o$KJT=8$G$-$^$9!#(B
+
+
+$B%3%s%Q%$%k!&4D6-@_Dj(B
+
+$B!&%3%s%Q%$%k(B
+
+$B%3%s%Q%$%k;~$K%*%W%7%g%s$H$7$F(B -DKANJI $B$r;XDj$7$F$/$@$5$$!#(B
+
+$B!&4D6-@_Dj(B
+
+config.sl, colours.sl $B$r(B ~/.slirc/scripts $B$K%3%T!<$7$^$9!#(B
+
+mkdir -p ~/.slirc/scripts
+cp /usr/lib/slirc/scripts/config.sl ~/.slirc/scripts
+cp /usr/lib/slirc/scripts/colours.sl ~/.slirc/scripts
+
+$B<!$K(B ~/.slirc/scripts/config.sl $B$r@_Dj$7$^$9!#(B
+
+() = s_putlast(servers,"$B%5!<%PL>(B:$B%]!<%HHV9f(B::$B%K%C%/%M!<%`(B");
+variable chan_on_connect = "$B@\B3$9$k%A%c%M%k(B";
+
+$B%K%C%/%M!<%`$O(B9$BJ8;z0JFb$G!"H>3Q1Q?t$7$+$D$+$($J$$$N$GCm0U$7$F$/$@$5$$!#(B
+$B<!$K4D6-JQ?t(B IRCNAME $B$r(B .profile $BEy$K@_Dj$7$^$9!#(B
+
+export IRCNAME="$BK\L>(B"
+
+$B0J>e$G@_Dj$O40N;$G$9!#(B
+
+
+$BIT6q9g!?%P%0(B
+
+$BF~NO%P%C%U%!$KD9$$F|K\8l$rF~NO$9$k$HI=<($,$_$@$l$k>l9g$,$"$j$^$9!#(B
+
+
+$B$=$NB>(B
+
+$B%P%0$r8+$D$1$?$j=$@5$5$l$?J}$,$$$i$C$7$c$?$i!"I~ItE590(B
+<tnh@aurora.dti.ne.jp>$B$^$GO"Mm$7$F2<$5$$!#(B
diff --git a/japanese/slirc/files/patch-editor.sl b/japanese/slirc/files/patch-editor.sl
new file mode 100644
index 000000000000..1566a6193eb4
--- /dev/null
+++ b/japanese/slirc/files/patch-editor.sl
@@ -0,0 +1,109 @@
+--- scripts/editor.sl.orig Mon Jun 7 16:07:23 1999
++++ scripts/editor.sl Sat Jan 6 21:23:30 2001
+@@ -35,6 +35,13 @@
+ {
+ irc_edit_insert_pos--;
+ buf = chop_last(irc_buffer);
++#ifdef KANJI
++ if(iskanji(irc_buffer[irc_edit_insert_pos]))
++ {
++ irc_edit_insert_pos--;
++ buf = substr(irc_buffer, 1, irc_edit_insert_pos);
++ }
++#endif
+ irc_set_buffer(buf);
+ }
+ else
+@@ -42,6 +49,14 @@
+ irc_edit_insert_pos--;
+ buf = substr(irc_buffer, 1, irc_edit_insert_pos)
+ + substr(irc_buffer, irc_edit_insert_pos + 2, -1);
++#ifdef KANJI
++ if(iskanji(irc_buffer[irc_edit_insert_pos]))
++ {
++ irc_edit_insert_pos--;
++ buf = substr(irc_buffer, 1, irc_edit_insert_pos)
++ + substr(irc_buffer, irc_edit_insert_pos + 3, -1);
++ }
++#endif
+ irc_set_buffer(buf);
+ }
+ !if(irc_edit_insert_pos)
+@@ -67,10 +82,25 @@
+ if(ch < 0x0a0) return; % ISO-LATIN-1 are 0xa0-0xff
+ }
+ variable buf;
++#ifdef KANJI
++ variable keysym;
++#endif
+ if(irc_edit_insert_pos >= strlen(irc_buffer))
+ {
++#ifdef KANJI
++ buf = irc_buffer + char(ch);
++ irc_edit_insert_pos = strlen(buf);
++ if (iskanji(ch))
++ {
++ keysym = irc_get_input();
++ buf = irc_buffer + char(ch) + char(keysym);
++ irc_edit_insert_pos = strlen(buf);
++ }
++ irc_set_buffer(buf);
++#else
+ irc_set_buffer(irc_buffer + char(ch));
+ irc_edit_insert_pos = strlen(irc_buffer);
++#endif
+ }
+ else
+ {
+@@ -78,12 +108,30 @@
+ {
+ buf = char(ch) + irc_buffer;
+ irc_edit_insert_pos = 1;
++#ifdef KANJI
++ if (iskanji(ch))
++ {
++ keysym = irc_get_input();
++ buf = char(ch) + char(keysym) + irc_buffer;
++ irc_edit_insert_pos = 2;
++ }
++#endif
+ }
+ else
+ {
+ buf = substr(irc_buffer, 1, irc_edit_insert_pos)
+ + char(ch)
+ + substr(irc_buffer, irc_edit_insert_pos + 1, -1);
++#ifdef KANJI
++ if (iskanji(ch))
++ {
++ keysym = irc_get_input();
++ buf = substr(irc_buffer, 1, irc_edit_insert_pos)
++ + char(ch) + char(keysym)
++ + substr(irc_buffer, irc_edit_insert_pos + 1, -1);
++ irc_edit_insert_pos++;
++ }
++#endif
+ irc_edit_insert_pos++;
+ }
+ irc_set_buffer(buf);
+@@ -96,10 +144,20 @@
+ {
+ if(irc_edit_insert_pos > 0)
+ irc_edit_insert_pos --;
++#ifdef KANJI
++ if(irc_edit_insert_pos > 0)
++ if(iskanji(irc_buffer[irc_edit_insert_pos]))
++ irc_edit_insert_pos--;
++#endif
+ }
+
+ define do_scroll_right()
+ {
++#ifdef KANJI
++ if(irc_edit_insert_pos < strlen(irc_buffer))
++ if(iskanji(irc_buffer[irc_edit_insert_pos]))
++ irc_edit_insert_pos++;
++#endif
+ if(irc_edit_insert_pos < strlen(irc_buffer))
+ irc_edit_insert_pos++;
+ }
diff --git a/japanese/slirc/files/patch-init.sl b/japanese/slirc/files/patch-init.sl
new file mode 100644
index 000000000000..d2cc27c11e39
--- /dev/null
+++ b/japanese/slirc/files/patch-init.sl
@@ -0,0 +1,11 @@
+--- scripts/init.sl.orig Sun Aug 22 03:22:41 1999
++++ scripts/init.sl Sat Jan 6 21:23:30 2001
+@@ -56,7 +56,7 @@
+ return;
+ }
+ variable w = vf_write(irc_server, st);
+- if (w == strlen(st)) return;
++ if (w >= strlen(st)) return;
+ irc_Inff("incomplete server write: %d/%d",w,strlen(st));
+ % () = fflush(irc_server);
+ }
diff --git a/japanese/slirc/files/patch-slirc.c b/japanese/slirc/files/patch-slirc.c
new file mode 100644
index 000000000000..d44f24e12692
--- /dev/null
+++ b/japanese/slirc/files/patch-slirc.c
@@ -0,0 +1,40 @@
+--- slirc.c.orig Tue Aug 24 00:15:11 1999
++++ slirc.c Sat Jan 6 21:23:30 2001
+@@ -8,6 +8,9 @@
+ #include <signal.h>
+
+ #include <slang.h>
++#ifdef KANJI
++#include <slkanji.h>
++#endif
+
+ #include "slirc.h"
+
+@@ -135,7 +138,16 @@
+ char *cp,*pm;
+ char stop, ch;
+
++#ifdef KANJI
++ char *KBuf;
++ int KSiz;
++ KSiz = strlen(cp0);
++ KBuf = kSLCodeConv(cp0, &KSiz, JIS, kSLcode, 1);
++ cp = strmcpy(RBuf, KBuf, sizeof(RBuf));
++ SLfree(KBuf);
++#else
+ cp = strmcpy(RBuf, cp0, sizeof(RBuf));
++#endif
+ /* now cp points to the terminating null in RBuf */
+ while(1) {
+ if (cp > RBuf && *(cp-1) == '\n') { /* back up past '\n' if is one. */
+@@ -1031,6 +1043,10 @@
+ }
+ SLsmg_init_smg(); /* this does get_screen_size inside. */
+ SLang_set_abort_signal(NULL);
++#ifdef KANJI
++ kSLcode = EUC;
++ init_SLKanji();
++#endif
+ InitMainScreen();
+ SLang_VMessage_Hook = Local_vmessage;
+ SLang_Load_File_Hook = Local_SLang_load_file;
diff --git a/japanese/slirc/files/patch-vfile-module.c b/japanese/slirc/files/patch-vfile-module.c
new file mode 100644
index 000000000000..0db71b0c51b8
--- /dev/null
+++ b/japanese/slirc/files/patch-vfile-module.c
@@ -0,0 +1,50 @@
+--- vfile-module.c.orig Tue Aug 24 00:08:56 1999
++++ vfile-module.c Sat Jan 6 21:53:38 2001
+@@ -54,6 +54,9 @@
+ #include <sys/wait.h>
+
+ #include <slang.h>
++#ifdef KANJI
++#include <slkanji.h>
++#endif
+
+ /* we need stripped-down version of SLang_Object_Type for cookies: */
+ typedef struct {
+@@ -1331,6 +1334,9 @@
+ unsigned long ip;
+ void *data;
+ char *s = NULL;
++#ifdef KANJI
++ char *s2 = NULL;
++#endif
+ SLang_BString_Type *bs = NULL;
+ SLang_Array_Type *at = NULL;
+ SLang_MMT_Type *mmt = NULL;
+@@ -1351,8 +1357,15 @@
+ case SLANG_STRING_TYPE:
+ if (SLang_pop_slstring(&s)) return -1;
+ type = strlen(s);
++#ifdef KANJI
++ s2 = kSLCodeConv(s,&type,kSLcode,JIS,0);
++ type = strlen(s2);
++ if (len < 0 || len > type) len = type;
++ data = s2;
++#else
+ if (len < 0 || len > type) len = type;
+ data = s;
++#endif
+ break;
+ case SLANG_BSTRING_TYPE:
+ if (SLang_pop_bstring(&bs)) return -1;
+@@ -1397,6 +1410,11 @@
+ if (at) SLang_free_array (at);
+ if (bs) SLbstring_free(bs);
+ SLang_free_slstring(s); /* NULL is ok */
++#ifdef KANJI
++ if(s2 != NULL)
++ SLfree(s2);
++#endif
++
+ if (mmt) SLang_free_mmt(mmt);
+ return ct;
+ }
diff --git a/japanese/slirc/files/patch-windoze.c b/japanese/slirc/files/patch-windoze.c
new file mode 100644
index 000000000000..60243300e543
--- /dev/null
+++ b/japanese/slirc/files/patch-windoze.c
@@ -0,0 +1,44 @@
+--- windoze.c.orig Sun Aug 22 20:15:00 1999
++++ windoze.c Sat Jan 6 21:23:35 2001
+@@ -15,6 +15,9 @@
+ #include <errno.h>
+ #include <stdio.h>
+ #include <slang.h>
++#ifdef KANJI
++#include <slkanji.h>
++#endif
+ #include <time.h>
+ #include <string.h>
+ #include "slirc.h"
+@@ -124,7 +127,19 @@
+ while (*p && isspace(*p)) p++ ;
+ q = p;
+ if (*p) {
++#ifdef KANJI
++ for (q = p; q < (p+tw); q++) {
++ if(iskanji(*q)) {
++ q++;
++ }
++ }
++ if (q > (p+tw)) {
++ q -= 2;
++ }
++ if (q > txth) q = txth;
++#else
+ q += tw; if (q > txth) q = txth;
++#endif
+ /* go back up to 1/3 of text-width looking for a word-break */
+ if (*q && !isspace(*q)) {
+ char *r,*rlow;
+@@ -256,6 +271,11 @@
+ } else if (*cp == CTRL_O) {
+ bold = 0;
+ SLsmg_set_color(ColNorm);
++#ifdef KANJI
++ } else if (iskanji(*cp)){
++ SLsmg_write_nstring(cp,2);
++ cp++;
++#endif
+ } else if (*cp != '')
+ SLsmg_write_char(*cp);
+ }