diff options
author | Ying-Chieh Liao <ijliao@FreeBSD.org> | 2004-03-11 03:34:44 +0000 |
---|---|---|
committer | Ying-Chieh Liao <ijliao@FreeBSD.org> | 2004-03-11 03:34:44 +0000 |
commit | 536edd82cfbf397bc9a554b234036b3581e5359c (patch) | |
tree | 89225bf945ff0330f680da5e254d66198516a25f /chinese | |
parent | 7d36cbb3e9128cea9220362969dad60cfdede350 (diff) | |
download | ports-536edd82cfbf397bc9a554b234036b3581e5359c.tar.gz ports-536edd82cfbf397bc9a554b234036b3581e5359c.zip |
Notes
Diffstat (limited to 'chinese')
-rw-r--r-- | chinese/Makefile | 1 | ||||
-rw-r--r-- | chinese/mldonkey-core/Makefile | 22 | ||||
-rw-r--r-- | chinese/mldonkey-core/files/patch-driverControlers.ml | 48 |
3 files changed, 71 insertions, 0 deletions
diff --git a/chinese/Makefile b/chinese/Makefile index 187b70e03651..262ef470aae4 100644 --- a/chinese/Makefile +++ b/chinese/Makefile @@ -69,6 +69,7 @@ SUBDIR += mingunittf SUBDIR += miniChinput SUBDIR += mkisofs + SUBDIR += mldonkey-core SUBDIR += moefonts-cid SUBDIR += moettf SUBDIR += mplayer-fonts diff --git a/chinese/mldonkey-core/Makefile b/chinese/mldonkey-core/Makefile new file mode 100644 index 000000000000..e60bd3fa4bf5 --- /dev/null +++ b/chinese/mldonkey-core/Makefile @@ -0,0 +1,22 @@ +# New ports collection makefile for: zh-tw-mldonkey +# Date created: Wed Mar 10 19:36:06 CST 2004 +# Whom: Hung-Te Lin +# <piaip@csie.ntu.edu.tw> +# +# $FreeBSD$ +# +# Only core (HTML/telnet) is affected. GUI has no problem with Chinese. + +PORTNAME= mldonkey-core +CATEGORIES= chinese + +MAINTAINER= piaip@csie.ntu.edu.tw +COMMENT= Client 'core' for MLDonkey with Traditional Chinese (Big5) support + +WITHOUT_GUI= yes +MASTERDIR= ${.CURDIR}/../../net/mldonkey +EXTRA_PATCHES= ${.CURDIR}/files/patch-driverControlers.ml + +.include "${MASTERDIR}/Makefile" + +PKGNAMEPREFIX:= ${PKGNAMEPREFIX}tw- diff --git a/chinese/mldonkey-core/files/patch-driverControlers.ml b/chinese/mldonkey-core/files/patch-driverControlers.ml new file mode 100644 index 000000000000..0c481f65070b --- /dev/null +++ b/chinese/mldonkey-core/files/patch-driverControlers.ml @@ -0,0 +1,48 @@ +--- src/daemon/driver/driverControlers.ml.orig Mon Oct 13 02:41:30 2003 ++++ src/daemon/driver/driverControlers.ml Wed Mar 10 19:11:04 2004 +@@ -291,6 +291,7 @@ + } + + ++let iac_will_8bit = "\255\253\000" + let iac_will_naws = "\255\253\031" + + let user_reader o telnet sock nread = +@@ -320,7 +321,7 @@ + + let i = int_of_char c in + telnet.telnet_iac <- false; +- let is_normal_char = i > 31 && i < 127 in ++ let is_normal_char = i > 31 (*&& i < 127*) in + + if telnet.telnet_wait = 1 then begin + Buffer.add_char telnet.telnet_buffer c; +@@ -439,6 +440,7 @@ + TcpBufferedSocket.set_closer sock user_closed; + user_socks := sock :: !user_socks; + ++ TcpBufferedSocket.write_string sock iac_will_8bit; + TcpBufferedSocket.write_string sock iac_will_naws; + + before_telnet_output o sock; +@@ -573,17 +575,17 @@ + let http_add_html_header buf = + http_add_gen_header buf; + Buffer.add_string buf "Pragma: no-cache\r\n"; +- Buffer.add_string buf "Content-Type: text/html; charset=iso-8859-1\r\n"; ++ Buffer.add_string buf "Content-Type: text/html; charset=big5\r\n"; + Buffer.add_string buf "\r\n" + + let http_add_css_header buf = + http_add_gen_header buf; +- Buffer.add_string buf "Content-Type: text/css; charset=iso-8859-1\r\n"; ++ Buffer.add_string buf "Content-Type: text/css; charset=big5\r\n"; + Buffer.add_string buf "\r\n" + + let http_add_js_header buf = + http_add_gen_header buf; +- Buffer.add_string buf "Content-Type: text/javascript; charset=iso-8859-1\r\n"; ++ Buffer.add_string buf "Content-Type: text/javascript; charset=big5\r\n"; + Buffer.add_string buf "\r\n" + + let any_ip = Ip.of_inet_addr Unix.inet_addr_any |