Refactor installer to expose BrandFullNameInternal and other symbols
Categories
(Firefox :: Installer, enhancement, P3)
Tracking
()
People
(Reporter: cdupuis, Unassigned)
Details
There are a number of branding-related symbols that are currently only available in .nsi files. Refactor these to put the symbols and their definitions into .h files, and include them in the .nsi file, to allow programmatic use of these symbols by non-NSIS code.
Comment 1•8 months ago
|
||
(In reply to Chris DuPuis from comment #0)
There are a number of branding-related symbols that are currently only available in .nsi files. Refactor these to put the symbols and their definitions into .h files, and include them in the .nsi file, to allow programmatic use of these symbols by non-NSIS code.
Generally, everything branding-related is already available to the build -- but perhaps not as defined constants. We don't have good examples of Fluent files flowing into compiled native code; it's something that we've never needed to do. Consult me or :eemeli for guidance, please -- I've NIed him here in case he has a plan for this type of work.
Comment 2•8 months ago
|
||
I don't have a plan as such, though I do have some ideas. For what we're talking about here, answering the following clarifying questions to start with would help quite a bit:
- Is the locale known at build time, or only at runtime?
- Are there any variables that need to be taken into account in the localization, in particular numbers? As in, "3 days ago" or "Install Firefox".
- For the variables, are their values known at build time, or only at runtime?
| Reporter | ||
Comment 3•8 months ago
|
||
These values should not be locale-specific, and are needed at build time.
The symbols that I need are:
BrandFullNameInternal
URLStubDownloadX86
URLStubDownloadAMD64
URLStubDownloadAArch64
URLManualDownload
Most of these have the current locale name substituted into them at runtime.
| Reporter | ||
Updated•8 months ago
|
Comment 4•8 months ago
|
||
If these values are not meant to be localized, then they probably should not be coming from files controlled by localisers.
Just to make sure, BrandFullNameInternal isn't used to set the value of BrandFullNameDA, right? I see the latter showing up as a variable in some of the messages, and there's usage like https://pontoon.mozilla.org/fi/firefox/browser/installer/mui.properties/?string=78939 that might be a bit broken, for the cases where conjugation is expected by the language.
If BrandFullNameInternal is used in a sentence context anywhere, then it would be good to have it come from Fluent, which supports that: https://pontoon.mozilla.org/fi/firefox/browser/branding/official/brand.ftl/?string=192278
| Reporter | ||
Comment 5•8 months ago
|
||
(In reply to Eemeli Aro [:eemeli] from comment #4)
If these values are not meant to be localized, then they probably should not be coming from files controlled by localisers.
I agree. That's what this ticket is reporting, that these values should be moved out of these files, and put somewhere else.
Just to make sure, BrandFullNameInternal isn't used to set the value of BrandFullNameDA, right? I see the latter showing up as a variable in some of the messages, and there's usage like https://pontoon.mozilla.org/fi/firefox/browser/installer/mui.properties/?string=78939 that might be a bit broken, for the cases where conjugation is expected by the language.
If BrandFullNameInternal is used in a sentence context anywhere, then it would be good to have it come from Fluent, which supports that: https://pontoon.mozilla.org/fi/firefox/browser/branding/official/brand.ftl/?string=192278
Here is what the comments in the branding.nsi files say about BrandFullNameInternal:
# BrandFullNameInternal is used for some registry and file system values
# instead of BrandFullName and typically should not be modified.
It is not used to set BrandFullNameDA.
Updated•7 months ago
|
Description
•