I need to create .zip file to be uploaded on Blackberry (App) World, but the instructions on the Blackberry page seem to be very confusing.
I have 3 bundles, support for OS version 4.6, support for OS version 4.7 and up, support for 6.0 and up. I need to support two languages (English and Spanish).
To do that do I need to create 2 bundles for each OS version? One for English and one for Spanish? Do I also need to add a suffix on each .cod file per bundle to support the languages that I need to support?
...do I need to create 2 bundles for each os version?
It depends how you want to do it.
If the English and Spanish versions have large differences, then you might find yourself using different images, possibly even different UI layouts, in addition to simply changing the language of your text. In that situation, you might want to provide a different bundle for each language (so you would have 3 English bundles and 3 Spanish bundles). That file structure might look like this:
- MyApp_2.0
- release.xml
- MyAppNoTouchEnglish_4.6.0.0
- devices.txt
- <.cod files go here>
+ MyAppNoTouchSpanish_4.6.0.0
+ MyAppTouchEnglish_4.7.0.0
+ MyAppTouchSpanish_4.7.0.0
+ MyAppTouchEnglish_6.0.0.0
+ MyAppTouchSpanish_6.0.0.0
Then, in the top-level release.xml file, you would need to identify the language codes of your bundles:
<?xml version="1.0" encoding="utf-8"?>
<Release version="x.x.x.x">
<ReleaseNotes>Release note text</ReleaseNotes>
<filebundle name="MyAppNoTouchEnglish_4.6.0.0">
<language>en</language>
</filebundle>
<filebundle name="MyAppNoTouchSpanish_4.6.0.0">
<language>es</language>
</filebundle>
<filebundle name="MyAppTouchEnglish_4.7.0.0">
<language>en</language>
</filebundle>
<filebundle name="MyAppTouchSpanish_4.7.0.0">
<language>es</language>
</filebundle>
<filebundle name="MyAppTouchEnglish_6.0.0.0">
<language>en</language>
</filebundle>
<filebundle name="MyAppTouchSpanish_6.0.0.0">
<language>es</language>
</filebundle>
</Release>
However, if there are not major differences between your app versions (English/Spanish), and you just want to let your code display text in the user's supported language, I would recommend using the BlackBerry localization APIs. These would allow one bundle to support both English and Spanish. That way, you'd only need 3 bundles (MyAppNoTouch_4.6.0.0, MyAppTouch_4.7.0.0, and MyAppTouch_6.0.0.0). Here is a tutorial on this technique.
If you do it this way, if I remember correctly, you simply don't include the <language></language>
elements in release.xml, since each bundle supports both languages.
Do I also need to add a suffix on each .cod file per bundle to support the languages that I need to support?
No, you don't have to, but that would actually be yet another way to handle this. You can let one "Bundle" support English and Spanish. Then, within that bundle, you can have different .cod files, which individually support English or Spanish:
- MyApp_2.0
- MyAppNoTouch_4.6.0.0
- MyApp_en.cod
- MyApp_es.cod
- MyApp-1_en.cod
- MyApp-1_es.cod
- MyApp-2_en.cod
- MyApp-2_es.cod
I haven't used this technique, personally. It's just another way to achieve localization, but you don't have to do it this way.
Also, see here for some advice on localizing BB apps.