邪恶八进制信息安全团队技术讨论组's Archiver

pub!1c 2006-6-5 10:04

[转载]FreeBSD 6.1下图形界面KDE和输入法SCIM安装

<p>信息来源: 邪恶八进制信息安全团队</p><p># sysinstall<br /><br />选择[Configure]->[Distributions]->[X.Org],如下图:<br /><a href="http://www.caisong.com//attachment/1148282590.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148282590.jpg" width="500" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" resized="true" /></a><br />接下来会出现一个菜单让你选择所需要安装的X.Org的包,如下图所示,请进入每一个选项里选取ALL.<br /><a href="http://www.caisong.com//attachment/1148283077.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148283077.jpg" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" /></a><br /><br /><a href="http://www.caisong.com//attachment/1148283132.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148283132.jpg" width="500" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" resized="true" /></a><br />接着选择Exit回到选择安装来源.您可以选择CD/DVD为安装本源,放入第一张CD即可开始安装.<br /><br />安装KDE:<br />leo# sysinstall<br />选择[Configure]->[Packages]->[kde],选择kde-3.5.1如下图:<br /><a href="http://www.caisong.com//attachment/1148284886.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148284886.jpg" width="500" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" resized="true" /></a><br />选择OK,然后Install会有提示要求您放第二张光盘.这里需要等比较长的时间.安装完就退出.<br /><br />运行<br />xorgcfg –textmode<br /><a href="http://www.caisong.com//attachment/1148283572.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148283572.jpg" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" /></a><br />配置xorg<br />本机上所生成的/etc/X11/xorg.conf文件内容如下<br />leo# cat /etc/X11/xorg.conf<br />Section "ServerLayout"<br />   Identifier   "Layout0"<br />   Screen   0 "Screen0" 0 0<br />   InputDevice  "Keyboard0" "CoreKeyboard"<br />   InputDevice  "Mouse0" "CorePointer"<br />EndSection<br /><br />Section "Files"<br />EndSection<br /><br />Section "Module"<br />   Load "freetype"<br />   # Load "xtt"<br />   Load "extmod"<br />   Load "glx"<br />   Load "dri"<br />   Load "dbe"<br />   Load "record"<br />   Load "xtrap"<br />   Load "type1"<br />   Load "speedo"<br />EndSection<br /><br />Section "InputDevice"<br />   Identifier "Mouse0"<br />   Driver   "mouse"<br />   Option   "Protocol" "Auto"<br />   Option   "Emulate3Buttons"<br />   Option   "Device" "/dev/sysmouse"<br />EndSection<br /><br />Section "InputDevice"<br />   Identifier "Keyboard0"<br />   Driver   "kbd"<br />   Option   "XkbModel" "pc101"<br />   Option   "XkbLayout" "us"<br />EndSection<br /><br />Section "Monitor"<br /><br />### Comment all HorizSync and VertSync values to use DDC:<br />   Identifier  "Monitor0"<br />### Comment all HorizSync and VertSync values to use DDC:<br />   HorizSync  31.5 - 57.0<br />   VertRefresh 50.0 - 90.0<br />EndSection<br /><br />Section "Device"<br />   Identifier "Card0"<br />   Driver   "vmware"<br />EndSection<br /><br />Section "Screen"<br />   Identifier "Screen0"<br />   Device   "Card0"<br />   Monitor  "Monitor0"<br />   DefaultDepth   24<br />   SubSection "Display"<br />       Viewport  0 0<br />       Depth   24<br />       Modes  "1024x768" "800x600"<br />   EndSubSection<br />EndSection<br /><br />在 /root 目录下 编辑 .xinitrc 文件:<br />加入下面行<br />exec /usr/local/bin/startkde<br />然后执行<br />startx<br />即可进入KDE<br /><a href="http://www.caisong.com//attachment/1148284386.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148284386.jpg" width="500" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" resized="true" /></a><br /><br />接着我们要将KDE 汉化,如果要在X-Window 中看到中文的菜单,必须先装中文字体kcfont(国乔字体)及arphicttf(文鼎字体),以及中文信息档(i18n)<br /># cd /usr/ports/chinese/kcfonts<br /># make install clean<br /># cd /usr/ports/chinese/arphicttf<br /># make install clean<br /># cd /usr/ports/chinese/kde3-i18n-zh_CN<br /># make install clean<br /># cd /usr/ports/chinese/koffice-i18n-zh_CN<br /># make install clean<br />接着编辑/etc/X11/xorg.conf<br />leo# vi /etc/X11/xorg.conf<br />在Section "Files"之间加入下面三行,以使X-Window能找到正确的字体路径,如下:<br />Section "Files"<br />   FontPath   "/usr/X11R6/lib/X11/fonts/TrueType"<br />   FontPath   "/usr/X11R6/lib/X11/fonts/local"<br />   FontPath   "/usr/X11R6/lib/X11/fonts/misc"<br />EndSection<br />更改保存后进入KDE。<br />找到Setting->Desktop Setting Wizard进行设置:<br /><a href="http://www.caisong.com//attachment/1148284623.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148284623.jpg" width="500" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" resized="true" /></a><br /><br />按Next一直到最后即可。<br />如果您想要有Windows的字体,可以到将Win上面的字体COPY到下面的目录<br />#cd /usr/X11R6/lib/X11/fonts/TrueType<br />然后打开“控制中心”->外观和主题->字体,里面设置你所需要的字体和字体大小。我是把windows下面的simsun.ttc和tohoma.ttf拷贝到了FreeBSD上面,然后应用windows的字体,这样感觉比较舒服,毕竟是平时看惯了windows的字体了。看其它字体感觉怪怪的。<br />-rw-r--r-- 1 root wheel 10507340 May 14 19:07 simsun.ttc<br />-rw-r--r-- 1 root wheel  379856 May 14 19:07 tahoma.ttf<br /><a href="http://www.caisong.com//attachment/1148284703.jpg" target="_blank"><img title="点击在新窗口中浏览此图片" alt="点击在新窗口中浏览此图片" src="http://www.caisong.com//attachment/1148284703.jpg" width="500" onload="function anonymous()
{
if(this.width>500) {this.resized=true; this.width=500;}
}" border="0" resized="true" /></a><br />中文输入法安装:<br />cd /usr/ports/chinese/scim-tables/<br />make install<br /><br />cat >> /etc/csh.cshrc << OK<br />setenv LANG zh_CN.eucCN<br />setenv LC_CTYPE zh_CN.eucCN<br />setenv XMODIFIERS @im=SCIM<br />setenv GTK_IM_MODULE scim<br />OK <br />另外在进入X之前需要执行(在~/.xinitrc中加入)<br />exec scim -d & <br />此行一定要放在exec /usr/local/bin/startkde之前<br />leo# cat /root/.xinitrc<br />exec scim -d &<br />exec /usr/local/bin/startkde<br /><br />重新启动KDE就可以输入中文了。 </p>

页: [1]
© 1999-2008 EvilOctal Security Team