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

Side by Side Diff: src/icu_util.cc

Issue 2393603002: Revert of Turn libbase into a component (Closed)
Patch Set: Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « src/heap/spaces.h ('k') | src/startup-data-util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/icu_util.h" 5 #include "src/icu_util.h"
6 6
7 #if defined(_WIN32) 7 #if defined(_WIN32)
8 #include <windows.h> 8 #include <windows.h>
9 #endif 9 #endif
10 10
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 const char* icu_data_file) { 45 const char* icu_data_file) {
46 #if !defined(V8_I18N_SUPPORT) 46 #if !defined(V8_I18N_SUPPORT)
47 return true; 47 return true;
48 #else 48 #else
49 #if ICU_UTIL_DATA_IMPL == ICU_UTIL_DATA_FILE 49 #if ICU_UTIL_DATA_IMPL == ICU_UTIL_DATA_FILE
50 if (icu_data_file) { 50 if (icu_data_file) {
51 return InitializeICU(icu_data_file); 51 return InitializeICU(icu_data_file);
52 } 52 }
53 char* icu_data_file_default; 53 char* icu_data_file_default;
54 #if defined(V8_TARGET_LITTLE_ENDIAN) 54 #if defined(V8_TARGET_LITTLE_ENDIAN)
55 base::RelativePath(&icu_data_file_default, exec_path, "icudtl.dat"); 55 RelativePath(&icu_data_file_default, exec_path, "icudtl.dat");
56 #elif defined(V8_TARGET_BIG_ENDIAN) 56 #elif defined(V8_TARGET_BIG_ENDIAN)
57 base::RelativePath(&icu_data_file_default, exec_path, "icudtb.dat"); 57 RelativePath(&icu_data_file_default, exec_path, "icudtb.dat");
58 #else 58 #else
59 #error Unknown byte ordering 59 #error Unknown byte ordering
60 #endif 60 #endif
61 bool result = InitializeICU(icu_data_file_default); 61 bool result = InitializeICU(icu_data_file_default);
62 free(icu_data_file_default); 62 free(icu_data_file_default);
63 return result; 63 return result;
64 #else 64 #else
65 return InitializeICU(NULL); 65 return InitializeICU(NULL);
66 #endif 66 #endif
67 #endif 67 #endif
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 110
111 UErrorCode err = U_ZERO_ERROR; 111 UErrorCode err = U_ZERO_ERROR;
112 udata_setCommonData(reinterpret_cast<void*>(g_icu_data_ptr), &err); 112 udata_setCommonData(reinterpret_cast<void*>(g_icu_data_ptr), &err);
113 return err == U_ZERO_ERROR; 113 return err == U_ZERO_ERROR;
114 #endif 114 #endif
115 #endif 115 #endif
116 } 116 }
117 117
118 } // namespace internal 118 } // namespace internal
119 } // namespace v8 119 } // namespace v8
OLDNEW
« no previous file with comments | « src/heap/spaces.h ('k') | src/startup-data-util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698