弟兄们共同帮忙汉化 slax
小弟前不久发现很好的基于slackware的livecd,做的很不错。感兴趣的高手可以拿虚拟机试一下可惜没有中文字体,没有中文支持。给作者建议,可是人家表示对此不感兴趣,还得自己动手。详细信息可以看看官方网站 http://slax.linux-live.org/
我自己搞了一下,可是仅仅是能显示中文了,这个添加了字体就成,安装了magic的kde3.2.1的中文包,可是在控制中心的语言选项中还是不见有中文的内容,如何编译源码,我就不会了,上面自然没有gcc
中文化最好是能做成模块,这样在以后的版本中均可使用。网站给了做模块的步骤,可是偶没有看懂 :cry: ,偶的所有努力都是将它放到硬盘里的,主要参考的是knoppix的汉化,可是偶汉化到所说的程度后,重启以后就startx不了了 :cry:
添加fcitx的结果是,桌面控制台可以显示中文了,可是无法调出输入条。举个例子,就是运行fcitx后再运行一次,桌面控制台会显示“已有同名程序运行”
希望有感兴趣的弟兄姐妹们共同作出这个中文模块来,偶正在翻译网页
制作module
How to create own modulesAt first, you have to download Linux Live scripts. Unpack them in /tmp directory, chdir to /tmp/linux-live-y.x.z/ and run ./install. Your system is now prepared.
The easiest way how to create a module is to convert Slackware's package to IMG. For example, to convert quake.tgz slackware's package use:
tgz2img quake.tgz quake.img
To create a module for SLAX, create an empty directory somewhere, for example in /tmp/newmod. Then create the essential module content in this directory. Each module should contain these files:
preinsert # /tmp/newmod/preinsert
postinsert # /tmp/newmod/postinsert
manual # /tmp/newmod/manual
and it should contain these directories:
data/ # /tmp/newmod/data/
The directory ./data should contain the whole filesystem (all changed or new files and directories). Let's assume that ./data is the new root here, so if you wish to include /bin/bash in your module, place it in ./data/bin/bash (or in /tmp/newmod/data/bin/bash in this example).
Note: The content of ./data directory could be created from slackware's TGZ package by using "installpkg -root ./data packagename.tgz" (or by "installpkg -root /tmp/newmod/data/ packagename.tgz" in this example)
Finaly, create the module by using
dir2img /tmp/newmod/ /tmp/modulename.img
The first argument is the module directory, the second one is the new name for your module. http://www.slackware.org.tw/?q=node/view/79 谢谢关注
可是很就没有更新了,用不上
汉化最好作成模块,以后有新的版本就一劳永逸了 好不容易安装了中文支持包,一并把美化包也转装了,添加了新字体,ms的好字体我都添加了,^_^,可以显示中文了!!!
可是,中文网页可以显示,文档却全是乱码,这是怎么回事?
还有想问的是,挂载fat分区的乱码问题, 是不是加上-t iocharset=gb2312就行了,不用别的??今天忘试了,假如是,又如何让它在启动时自动加上这个参数?
有没有让它自动挂载所有分区的脚本??,就是让系统自动识别有多少分区,然后加上中文参数,并挂载分区??
请指教 找到了制作语言包的方法,内容如下
How to create a multilanguage module for SLAX
---------------------------------------------
This document describes which packages and which files are needed
to create a SLAX module with your language. At first, read the file
DOC_MODULES to learn how to create modules for SLAX. You will need to
know that.
Now let's assume that your language is "cs" (for Czech) and you wish to
create the module structure in /tmp/lang directory. Also let's assume
that you don't wish to include any sounds, manuals and documentation
files in the module, because of it's size.
-----------------------
1. Installing KDE files
-----------------------
The most important part of multilanguage module for SLAX is covered in
two KDE i18n packages. In Slackware, these files are located in
/slackware/kdei/ directory on the FTP or on the Install CD. So download
them if neccessary and install them by using
installpkg -root /tmp/lang ./kde-i18n-cs*.tgz
installpkg -root /tmp/lang ./koffice-i18n-cs*.tgz
You may now remove everythig you don't need from the lang directory.
For example, you won't need /tmp/lang/opt/kde/share/doc.
KDE multilanguage support is now installed, but the default language
in KDE is still english.
-------------------------------
2. Set KDE to use your language
-------------------------------
You will need to modify two KDE config files. You may copy them from your
home directory (/root/ under SLAX) to /tmp/lang; and then:
at first, /tmp/lang/root/.kde/share/config/kdeglobals: in section,
for example, modify these lines:
Country=cz
Language=cs
at second, /tmp/lang/root/.kde/share/config/kxkbrc: in section,
for example, modify these lines:
Additional=cz,us
Layout=cz
Variants=cz(basic),us(intl)
If you are not sure what to type here, make your changes by using
KDE Control Center and then see these files to find all differences.
--------------------
3. Textmode settings
--------------------
To be able to use your keyboard and language in text-mode, start "setfont"
and "loadkeys" with apropriate arguments. You can create
/tmp/lang/etc/rc.d/rc.keymap
with the following content:
echo "Loading keyboard mapping for cz" # This is Czech keyboard mapping
loadkeys cz 2>/dev/null >/dev/null
and then edit
/tmp/lang/etc/rc.d/rc.font
adding the following:
echo "Loading font from file lat2a-16.psfu.gz" # This is Czech font
setfont -v lat2a-16.psfu.gz 2>/dev/null >/dev/null
These two scripts will be executed by SLAX during the boot.
You also have to create /tmp/lang/manual with the following content:
#!/bin/bash
/etc/rc.d/rc.font
/etc/rc.d/rc.keymap
to start both rc-scripts mentioned above when user loads the module manually
(by downloading the module and using moduse command)
-------------------
4. Own translations
-------------------
Edit or replace /tmp/lang/etc/issue with your translation
of SLAX splash screen.
You may also wish to translate this document to your language
and copy it to /tmp/lang/
----------------
5. System locale
----------------
Locale is used to translate textmode applications.
You may want to create profile script to set your locale
environment variables. For example
/tmp/lang/etc/profile.d/lang.sh
#!/bin/sh
export LANG=cs_CZ
export LC_COLLATE=C
Apropriate translations are usually located in /usr/share/locale/??/*.mo
These translations could break scripts so it's a good idea
to include only few of them, for ncurses apps only, for example
mc.mo (for Midnight Commander)
lynx.mo (for Lynx browser)
mutt.mo (for Mutt mail client)
--------------------
6. Create the module
--------------------
Then convert your lang directory to SLAX module by using
dir2img /tmp/lang cs.img /data
页:
[1]