0

Make consistent brand strings naming

This CL is a follow of previous work in which the use of a gn variable
`branding_path_product` was introduced, in order to have a consistent
approach to naming string file resources.

These changes are minimal, and they are aimed at reducing the branching
in the build code, and make it more consistent with the general use of
the variable itself for determining the branding naming itself.

Bug: 1470725
Change-Id: Ife059e437af68e817b2ce99119ade49a71209a35
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4882660
Reviewed-by: Sylvain Defresne <sdefresne@chromium.org>
Commit-Queue: Claudio DeSouza <cdesouza@chromium.org>
Reviewed-by: Andrey Kosyakov <caseq@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1202200}
This commit is contained in:
Claudio DeSouza
2023-09-28 01:42:06 +00:00
committed by Chromium LUCI CQ
parent e2da672d9e
commit 262ed90657
4 changed files with 7 additions and 26 deletions

@ -600,11 +600,7 @@ if (is_win) {
outputs = []
foreach(locale, platform_pak_locales) {
if (is_chrome_branded) {
_strings_file = "google_chrome_strings"
} else {
_strings_file = "chromium_strings"
}
_strings_file = "${branding_path_product}_strings"
inputs += [ "$root_gen_dir/chrome/${_strings_file}_${locale}.pak" ]
}

@ -99,17 +99,10 @@ template("chrome_repack_locales") {
deps += [ "//extensions/strings" ]
}
if (is_chrome_branded) {
source_patterns += [
"${root_gen_dir}/chrome/google_chrome_strings_",
"${root_gen_dir}/components/strings/components_google_chrome_strings_",
]
} else {
source_patterns += [
"${root_gen_dir}/chrome/chromium_strings_",
"${root_gen_dir}/components/strings/components_chromium_strings_",
]
}
source_patterns += [
"${root_gen_dir}/chrome/${branding_path_product}_strings_",
"${root_gen_dir}/components/strings/components_${branding_path_product}_strings_",
]
if (defined(invoker.additional_source_patterns)) {
source_patterns += invoker.additional_source_patterns

@ -834,11 +834,7 @@ repack("components_tests_pak") {
"//components/strings",
]
if (is_chrome_branded) {
sources += [ "${root_gen_dir}/components/strings/components_google_chrome_strings_en-US.pak" ]
} else {
sources += [ "${root_gen_dir}/components/strings/components_chromium_strings_en-US.pak" ]
}
sources += [ "${root_gen_dir}/components/strings/components_${branding_path_product}_strings_en-US.pak" ]
}
if (is_android) {

@ -93,11 +93,7 @@ repack("resource_pack_strings") {
"$root_gen_dir/ui/strings/ui_strings_en-US.pak",
]
if (is_chrome_branded) {
sources += [ "${root_gen_dir}/components/strings/components_google_chrome_strings_en-US.pak" ]
} else {
sources += [ "${root_gen_dir}/components/strings/components_chromium_strings_en-US.pak" ]
}
sources += [ "${root_gen_dir}/components/strings/components_${branding_path_product}_strings_en-US.pak" ]
deps = [
"//components/strings",