Difference between revisions of "TB/TB-2008-02-L18N"
Karyn.hunt (Talk | contribs) |
Karyn.hunt (Talk | contribs) |
||
Line 1: | Line 1: | ||
== Overview == | == Overview == | ||
− | Using UTF8 character encoding, Scalix provides full multi-byte language support, coupled with an open-source localization kit for channel partners and customers | + | Using UTF8 character encoding, Scalix provides full multi-byte language support, coupled with an open-source localization kit for channel partners and customers to facilitate international deployments. |
== Localizing Outlook == | == Localizing Outlook == | ||
Line 7: | Line 7: | ||
You can localize the MAPI Connector for any language that Outlook supports. | You can localize the MAPI Connector for any language that Outlook supports. | ||
− | Tools | + | '''Tools''' |
For this procedure, you need the following tools: | For this procedure, you need the following tools: | ||
− | Microsoft resource compiler Visual Studio 6.0, including the compiler RC.EXE and the linker LINK.EXE | + | Microsoft resource compiler Visual Studio 6.0, including the compiler RC.EXE and the linker LINK.EXE. |
− | Procedures | + | For more on the compiler, see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/tools/tools/resource_compiler.asp. |
+ | |||
+ | '''Procedures''' | ||
To localize the MAPI Connector: | To localize the MAPI Connector: | ||
Line 20: | Line 22: | ||
SCLXRES\RESEN.RC | SCLXRES\RESEN.RC | ||
and in all sub-files of the SCLXRES\EN subdirectory. | and in all sub-files of the SCLXRES\EN subdirectory. | ||
+ | |||
2. Make sure you can save the file with the proper font files. | 2. Make sure you can save the file with the proper font files. | ||
+ | |||
3. From the directory SCLXRES, run the resource compiler. The command is: | 3. From the directory SCLXRES, run the resource compiler. The command is: | ||
rc /l<LCID Culture ID> /fo "<file name>\sclxres.res" /i "..\shared\include" /i "..\common" /d "THIS_LANG_<NAME OF LANGUAGE>" sclxres.rc | rc /l<LCID Culture ID> /fo "<file name>\sclxres.res" /i "..\shared\include" /i "..\common" /d "THIS_LANG_<NAME OF LANGUAGE>" sclxres.rc | ||
Line 32: | Line 36: | ||
Note that in this step, you are compiling the file SCLXRES.RC, which includes all subfiles and subfolders, and creates a new file named SCLXRES.RES to the same directory. | Note that in this step, you are compiling the file SCLXRES.RC, which includes all subfiles and subfolders, and creates a new file named SCLXRES.RES to the same directory. | ||
+ | |||
4. When the compiler completes, you see a new file named sclxres.res in the directory SCLXRES. | 4. When the compiler completes, you see a new file named sclxres.res in the directory SCLXRES. | ||
+ | |||
5 Using the resource compiler's LINK.EXE tool, link the .res file to produce a dll in the same directory that will be called SCLXRES.DLL. The command is: | 5 Using the resource compiler's LINK.EXE tool, link the .res file to produce a dll in the same directory that will be called SCLXRES.DLL. The command is: | ||
link /nologo /dll /pdb:none /machine:I386 /nodefaultlib /implib:"sclxres.lib" /NOENTRY sclxres.res | link /nologo /dll /pdb:none /machine:I386 /nodefaultlib /implib:"sclxres.lib" /NOENTRY sclxres.res | ||
+ | |||
6. Copy the new file, SCLXRES.DLL to the MAPI Connector's installation directory. | 6. Copy the new file, SCLXRES.DLL to the MAPI Connector's installation directory. | ||
(The default installation directory is C:\Program Files\Scalix\Connect). | (The default installation directory is C:\Program Files\Scalix\Connect). | ||
Line 43: | Line 50: | ||
== Localizing SWA == | == Localizing SWA == | ||
− | Localization of SWA involves translating two xml files, putting them in the appropriate location, and then restarting Tomcat. | + | Localization of SWA involves translating two xml files, putting them in the appropriate location, and then restarting Tomcat. |
− | Note Unless your localization file is part of a Scalix distribution, you MUST do a backup before the next upgrade. If you do not, your file will be lost. | + | |
+ | Note: Unless your localization file is part of a Scalix distribution, you MUST do a backup before the next upgrade. If you do not, your file will be lost. | ||
To add a new locale to SWA version 11.0: | To add a new locale to SWA version 11.0: | ||
Line 58: | Line 66: | ||
4. Put the files strings_xx.xml and strings_xx_XX.xml in the WEB-INF/data directory. | 4. Put the files strings_xx.xml and strings_xx_XX.xml in the WEB-INF/data directory. | ||
+ | |||
5. Delete the Tomcat cache if needed by deleting the contents of the following directory. | 5. Delete the Tomcat cache if needed by deleting the contents of the following directory. | ||
/opt/scalix-tomcat/work/Catalina/ directory | /opt/scalix-tomcat/work/Catalina/ directory | ||
+ | |||
6. Restart Tomcat by running the shutodwn script found at: | 6. Restart Tomcat by running the shutodwn script found at: | ||
/etc/init.d/scalix-tomcat start | /etc/init.d/scalix-tomcat start | ||
Line 71: | Line 81: | ||
1. Stop Tomcat. | 1. Stop Tomcat. | ||
/opt/scalix-tomcat/shutdown.sh | /opt/scalix-tomcat/shutdown.sh | ||
+ | |||
2. On the server where SIS is installed, open the following file: | 2. On the server where SIS is installed, open the following file: | ||
/etc/opt/scalix/sis/sis.properties | /etc/opt/scalix/sis/sis.properties | ||
+ | |||
3 Edit the property, sis.language, to one of the following: | 3 Edit the property, sis.language, to one of the following: | ||
Danish | Danish | ||
Line 89: | Line 101: | ||
4. In the following file: | 4. In the following file: | ||
/var/opt/scalix-sis, | /var/opt/scalix-sis, | ||
− | remove existing indexes and rebuild them using the command sxmkindex | + | remove existing indexes and rebuild them using the command |
+ | sxmkindex | ||
5. All subsequent index and search operations will use the stemming rules for the given language. | 5. All subsequent index and search operations will use the stemming rules for the given language. | ||
Note: This procedure uses the Snowball Analyzer written by Martin Porter. For more information, see the Lucene API at: http://lucene.apache.org/java/docs/api/net/sf/snowball/ext/package-summary.html. | Note: This procedure uses the Snowball Analyzer written by Martin Porter. For more information, see the Lucene API at: http://lucene.apache.org/java/docs/api/net/sf/snowball/ext/package-summary.html. | ||
− | Using Custom Analyzers | + | '''Using Custom Analyzers''' |
For additional languages, you can use other analyzers, all of which have built-in stemmers. To use these additional stemmers: | For additional languages, you can use other analyzers, all of which have built-in stemmers. To use these additional stemmers: |
Revision as of 21:24, 17 August 2006
Overview
Using UTF8 character encoding, Scalix provides full multi-byte language support, coupled with an open-source localization kit for channel partners and customers to facilitate international deployments.
Localizing Outlook
You can localize the MAPI Connector for any language that Outlook supports.
Tools
For this procedure, you need the following tools:
Microsoft resource compiler Visual Studio 6.0, including the compiler RC.EXE and the linker LINK.EXE.
For more on the compiler, see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/tools/tools/resource_compiler.asp.
Procedures
To localize the MAPI Connector:
1. Use your preferred editing and translation tools to localize the English strings in the following file.
SCLXRES\RESEN.RC
and in all sub-files of the SCLXRES\EN subdirectory.
2. Make sure you can save the file with the proper font files.
3. From the directory SCLXRES, run the resource compiler. The command is:
rc /l<LCID Culture ID> /fo "<file name>\sclxres.res" /i "..\shared\include" /i "..\common" /d "THIS_LANG_<NAME OF LANGUAGE>" sclxres.rc
Where:
rc = The compiler command <LCID Culture ID> = Can be found at http://www.microsoft.co.ke/globaldev/nlsweb/default.mspx. This code number must be preceded by an “l” (a lower-case l, not an i) and must match the “THIS-LANG...” option l = Specifies default language for compilation. For example, -l409 is equivalent to including the following statement at the top of the resource script file: LANGUAGE LANG_ENGLISH,SUBLANG_ENGLISH_US fo = Renames the source file so that it comes out as a .res file i = The "include" command so takes a directory as its variable d = This variable changes according to the culture ID specified earlier
Note that in this step, you are compiling the file SCLXRES.RC, which includes all subfiles and subfolders, and creates a new file named SCLXRES.RES to the same directory.
4. When the compiler completes, you see a new file named sclxres.res in the directory SCLXRES.
5 Using the resource compiler's LINK.EXE tool, link the .res file to produce a dll in the same directory that will be called SCLXRES.DLL. The command is:
link /nologo /dll /pdb:none /machine:I386 /nodefaultlib /implib:"sclxres.lib" /NOENTRY sclxres.res
6. Copy the new file, SCLXRES.DLL to the MAPI Connector's installation directory.
(The default installation directory is C:\Program Files\Scalix\Connect).
Note: For more on the link command, see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore98/html/_core_linker_reference.asp.
Localizing SWA
Localization of SWA involves translating two xml files, putting them in the appropriate location, and then restarting Tomcat.
Note: Unless your localization file is part of a Scalix distribution, you MUST do a backup before the next upgrade. If you do not, your file will be lost.
To add a new locale to SWA version 11.0:
1. Translate the files strings_en.xml and strings_en_US.xml to create the files strings_xx.xml and strings_xx_XX.xml. Those strings are located at:
/opt/scalix-tomcat/webapps/webmail/WEB-INF/data
For example: For Nederlands Dutch, create files named string_nl.xml and strings_nl_NL.xml.
2. Stop Tomcat by running the shutdown script found at:
/etc/init.d/scalix-tomcat stop
3. If Tomcat has not already unpacked it, uncompress the war file.
4. Put the files strings_xx.xml and strings_xx_XX.xml in the WEB-INF/data directory.
5. Delete the Tomcat cache if needed by deleting the contents of the following directory.
/opt/scalix-tomcat/work/Catalina/ directory
6. Restart Tomcat by running the shutodwn script found at:
/etc/init.d/scalix-tomcat start
Localizing the Search and Index Service
The Scalix Search Index Service can be configured to process text for any language. To work with different languages, it uses stemming rules for that specific language, which break down words by removing suffixes and endings just as they do with the English language. For example, a search for the English word "singing" will match the word "sing".
To change the language assumed by SIS when it indexes text or builds search queries:
1. Stop Tomcat.
/opt/scalix-tomcat/shutdown.sh
2. On the server where SIS is installed, open the following file:
/etc/opt/scalix/sis/sis.properties
3 Edit the property, sis.language, to one of the following:
Danish Dutch English Finnish French German Italian Norwegian Portuguese Russian Spanish Swedish (English is default)
4. In the following file:
/var/opt/scalix-sis,
remove existing indexes and rebuild them using the command
sxmkindex
5. All subsequent index and search operations will use the stemming rules for the given language.
Note: This procedure uses the Snowball Analyzer written by Martin Porter. For more information, see the Lucene API at: http://lucene.apache.org/java/docs/api/net/sf/snowball/ext/package-summary.html.
Using Custom Analyzers
For additional languages, you can use other analyzers, all of which have built-in stemmers. To use these additional stemmers:
1. In the file sis.properties, specify a custom class of your own.
index.content.analyzer.class==com.scalix.index.message.MyRussianAnalyzer
The list of potential analyzers includes:
BrazilianAnalyzer ChineseAnalyzer CJKAnalyzer CzechAnalyzer DutchAnalyzer FrenchAnalyzer GermanAnalyzer GreekAnalyzer
2. The class must be implemented like this:
import org.apache.lucene.analysis.Analyzer; import org.apache.lucene.analysis.ru.RussianAnalyzer; import com.scalix.index.message.MessageAnalyzer; public class MyRussianAnalyser extends MessageAnalyzer { public Analyzer getAnalyzer() { return new RussianAnalyzer(); } }
3. Compile the class and put it in the following directory so that it can be picked up by the Web Apps classloader.
/opt/scalix-tomcat/webapps/sis/WEB-INF/classes