Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(62)

Unified Diff: BUILD.gn

Issue 2174993002: Support Big Endian in ICU: part 3 (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/icu.git@master
Patch Set: simplify per reviewer comment Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: BUILD.gn
diff --git a/BUILD.gn b/BUILD.gn
index 2e63fa934603384ccd9cb5a8e6afaa416a3233cd..80764aa8daf0be3c7511019e3cf2906271ddec5a 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -569,32 +569,28 @@ if (is_android && enable_java_templates) {
}
}
+# TODO(GYP): Gyp has considerations here for QNX and for the host toolchain
+# that have not been ported over.
+data_bundle = "common/icudtl.dat"
+if (is_android) {
+ data_bundle = "android/icudtl.dat"
+} else if (current_cpu == "mips" || current_cpu == "mips64") {
+ data_bundle = "common/icudtb.dat"
+} else {
+ data_bundle = "common/icudtl.dat"
+}
+
# TODO(GYP) support use_system_icu.
if (icu_use_data_file) {
if (is_ios) {
bundle_data("icudata") {
- sources = [ "common/icudtl.dat" ]
+ sources = [ "$data_bundle" ]
outputs = [ "{{bundle_resources_dir}}/{{source_file_part}}" ]
}
} else {
copy("icudata") {
- if (is_android) {
- sources = [
- "android/icudtl.dat",
- ]
- } else {
- sources = [
- "common/icudtl.dat",
- ]
- }
-
- outputs = [
- "$root_out_dir/icudtl.dat",
- ]
-
- data = [
- "$root_out_dir/icudtl.dat",
- ]
+ sources = [ "$data_bundle" ]
+ outputs = [ "$root_out_dir/{{source_file_part}}" ]
}
}
} else {
@@ -607,33 +603,30 @@ if (icu_use_data_file) {
outputs = [
"$root_out_dir/icudt.dll",
]
-
- data = [
- "$root_out_dir/icudtl.dll",
- ]
}
} else {
- source_set("icudata") {
- # These are hand-generated, but will do for now.
- #
- # TODO(GYP): Gyp has considerations here for QNX and for the host toolchain
- # that have not been ported over.
- if (is_linux) {
- sources = [
- "linux/icudtl_dat.S",
- ]
- } else if (is_mac) {
- sources = [
- "mac/icudtl_dat.S",
- ]
- } else if (is_android) {
- sources = [
- "android/icudtl_dat.S",
- ]
- } else {
- assert(false, "No icu data for this platform")
+ if (current_cpu == "mips" || current_cpu == "mips64") {
+ data_assembly = "$target_gen_dir/icudtb_dat.S"
+ } else {
+ data_assembly = "$target_gen_dir/icudtl_dat.S"
+ }
+ action("make_data_assembly") {
+ script = "scripts/make_data_assembly.py"
+ inputs = [ "$data_bundle" ]
+ outputs = [ "$data_assembly" ]
+ args = [
+ rebase_path(data_bundle, root_build_dir),
+ rebase_path(data_assembly, root_build_dir),
+ ]
+ if (is_mac) {
+ args += [ "--mac" ]
}
+ }
+
+ source_set("icudata") {
+ sources = [ "$data_assembly" ]
defines = [ "U_HIDE_DATA_SYMBOL" ]
+ deps = [ ":make_data_assembly", ]
}
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698