深入 Alchemy CATALYST 系列:安装文件(*.msi)的本地化

  Alchemy CATALYST 是一款屡获殊荣的软件本地化专业工具,它提供了众多文件类型的本地化支持。今天,我要向你介绍的将是对于 *.msi(安装文件)文件类型的本地化。

  使用 Alchemy CATALYST 本地化 *.msi 文件,需要一个名为 MsiConvert 的小工具。所幸的是,在 Alchemy CATALYST 的安装包中已经自带了此程序,我们就不必满世界的找啦。只要你按照默认方式安装 Alchemy CATALYST,就可以在其安装目录中的 Tools 文件夹中打到它了。

  现在,你需要准备原始的 *.msi 文件。我找到的示范文件为 Test.msi。

  Alchemy CATALYST 本地化 *.msi 文件的流程为:提取资源→翻译资源→更新资源。

一、提取资源

  因为 MsiConvert 为命令行工具,所以我们得先进入命令行环境。在 Windows XP 系统中,进入命令行环境的方法为:单击“开始→运行”,在弹出的对话框中输入“Cmd”,点击“确定”按钮。接着,想办法进入到 Alchemy CATALYST 安装目录中的 Tools 文件夹中(注意,你需要一些 DOS 知识)。在命令提示符后输入下面的命令:

MsiConvert /TOTRS:"C:/Test.msi"

注意,你需要将上述命令引号中的内容替换为你所保存的 *.msi 路径。此命令的作用是将 *.msi 文件中可供本地化的字符串资源提取出来。一旦命令成功完成,在保存 *.msi 文件的目录中将会产生一个与 *.msi 同名而扩展名为 trs 的文件,例如,本例为 Test.trs 文件。

二、翻译资源

  启动 Alchemy CATALYST,建立方案,并向其中插入刚才生成的 Test.trs 文件。按照常规的方法对 Test.trs 文件进行翻译。注意,不要翻译变量。然后,提取翻译好的文件 Test-loc.trs 备用。

三、更新资源

  在命令提示符后输入下面的命令:

MsiConvert /TOMSI:"C:/Test.msi" "C:/Test-loc.trs" "Chinese (PRC Simplified)"

此命令中,第一个引号为需要更新资源的 *.msi 文件;第二个引号为已经翻译好的 *.trs 资源文件;第三个引号为需要更新的语言(也就是你所翻译后的语言)。当命令执行成功后,*.msi 文件中的资源将被自动更新。

  现在,Test.msi 已经被本地化为你所需要的语言版本。

 

附:MsiConverter 使用方法;

Command Line arguments can take two forms as outlined below:

1)
To update an MSI file with a translated TRS file use as follows:

MsiConverter /TOMSI:"path to MSI" "path to TRS" "Language"

The command line arguments must be entered exactly as they appear above i.e.
Paths must be in quotes and seperated by a space.
Please seperate the path to the MSI file from the EXE name with a Colon !
The Language parameter states which Language has been used to translate the TRS file and this must be specified using a capital letter and surrounded by quotes.This allows the database summary to be updated correctly. Please see the 'Language Options' section below for more details.

2)
To create  a TRS file from an MSI file use as follows:

MsiConverter /TOTRS:"path to .MSI file"

The syntax rules as were outlined above apply to the arguments.
There is no need to specify the name of the TRS file to be created as it will have the same name as the MSI file but for a different extension. It will also be created in the same location as the MSI file.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Language Options:

The Language parameter states which Language has been used to translate the TRS file and this must be specified using a capital letter and surrounded by quotes.
Any of the languages below can be chosen and they should be entered exactly as they appear below.
This allows the codepage to be set within the database and is primarily required for the database to display correctly in Windows 2000.

"Language Neutral"  "Process Default Language"
"Arabic (Saudi Arabia)" "Arabic (Iraq)"
"Arabic (Egypt)"  "Arabic (Libya)"
"Arabic (Algeria)"  "Arabic (Morocco)"
"Arabic (Tunisia)"  "Arabic (Oman)"
"Arabic (Yemen)"  "Arabic (Syria)"
"Arabic (Jordan)"  "Arabic (Lebanon)"
"Arabic (Kuwait)"  "Arabic (U.A.E.)"
"Arabic (Bahrain)"  "Arabic (Qatar)"
"Bulgarian"  "Catalan"
"Chinese (Taiwan Traditional)" "Chinese (PRC Simplified)"
"Chinese (Hong Kong)" "Chinese (Singapore)"
"Czech"   "Danish"
"German"   "German (Swiss)"
"German (Austrian)"  "German (Luxembourg)"
"German (Liechtenstein)" "Greek"
"English (United States)" "English (United Kingdom)"
"English (Australian)" "English (Canadian)"
"English (New Zealand)" "English (Ireland)" 
"English (South Africa)" "English (Jamaica)"
"English (Caribbean)" "English (Belize)" 
"English (Trinidad)"  "Spanish (Tradional Sort)"
"Spanish (Mexican)"  "Spanish (Modern Sort)"
"Spanish (Guatemala)" "Spanish (Costa Rica)"
"Spanish (Panama)"  "Spanish (Dominican Republic)"
"Spanish (Venezuela)" "Spanish (Colombia)"
"Spanish (Peru)"  "Spanish (Argentina)"
"Spanish (Ecuador)"  "Spanish (Chile)"
"Spanish (Uruguay)"  "Spanish (Paraguay)"
"Spanish (Bolivia)"  "Spanish (El Salvador)"
"Spanish (Hondurus)" "Spanish (Nicaragua)"
"Spanish (Puerto Rico)" "Spanish (Castilian)"  //same as Traditional Spanish
"Finnish"
"French"   "French (Belgian)"
"French (Canadian)"  "French (Swiss)"
"French (Luxembourg)" "Hebrew" 
"Hungarian"  "Icelandic"
"Italian"   "Italian (Swiss)"   
"Japanese"  "Korean"
"Korean (Johab)"  "Dutch"
"Dutch (Belgian)"  "Norwegian (Bokmal)"
"Norwegian (Nynorsk)" "Polish"
"Portuguese (Brazilian)" "Portuguese"
"Romanian"  "Russian"
"Croatian"       "Serbian (Latin)"
"Serbian (Cyrillic)"  "Slovak"
"Albanian"  "Swedish"
"Swedish (Finland)"  "Thai"  
"Turkish"   "Indonesian"
"Ukrainian"  "Belarusian"
"Slovenian"  "Estonian"
"Latvian"   "Lithuanian"
"Farsi",   "Vietnamese"
"Basque"   "Afrikaans"
"Faeroese"  "Rhaeto-Romanic"
"Urdu"

你可能感兴趣的:(汉化相关)