blob: d20e9098bedb6d19b3a47ceb20917fe7a9c4e781 [file] [log] [blame]
Lei Zhange4bf8342015-10-21 17:11:04 -07001use_relative_paths = True
2
Dan Sinclaira03c3432016-03-16 15:35:20 -04003vars = {
Lei Zhangab384ed2017-12-21 08:00:44 +00004 # By default, we should check out everything needed to run on the main
5 # chromium waterfalls. This var can be also be set to "small", in order
6 # to skip things are not strictly needed to build chromium for development
7 # purposes.
8 'checkout_configuration': 'default',
9
10 # TODO(dpranke): change to != "small" once != is supported.
11 'checkout_instrumented_libraries': 'checkout_linux and checkout_configuration == "default"',
12
Dan Sinclaira03c3432016-03-16 15:35:20 -040013 'chromium_git': 'https://chromium.googlesource.com',
14 'pdfium_git': 'https://pdfium.googlesource.com',
15
Tom Anderson16ccc8b2018-05-30 01:53:00 +000016 'android_ndk_revision': '5cd86312e794bdf542a3685c6f10cbb96072990b',
Lei Zhangdfc08432017-12-21 07:37:15 +000017 'binutils_revision': 'e146228c20af6af922887d0be2d3641cbffb33c5',
Lei Zhang65f38c82018-07-02 23:29:33 +000018 'build_revision': '7ac293430bfc16826dc27680c6c3c60911f10759',
Tom Anderson16ccc8b2018-05-30 01:53:00 +000019 'buildtools_revision': '893eb86b02b2571894e328f05551112b96df1cce',
20 'catapult_revision': '8fbdf9f10b76595b6299e577709f2608ae29e19a',
Lei Zhangb36ae1d2018-07-02 23:28:54 +000021 'clang_revision': 'dec27d726d78471325a143a49863846e91d39df8',
Ryan Harrisona7b65b82018-05-30 19:56:11 +000022 'code_coverage_revision': '14b8501b7d9f41826d632254a1df8bc664edeec7',
Dan Sinclaira03c3432016-03-16 15:35:20 -040023 'cygwin_revision': 'c89e446b273697fadf3a10ff1007a97c0b7de6df',
Lei Zhangf9f0e512018-03-22 17:14:36 +000024 'depot_tools_revision': '869a2857a4f3acc08fdec6182ecec5b73593be3b',
Nicolas Pena18065652018-06-01 16:30:14 +000025 'freetype_revision': '125b84800a3230305b7fbc8eedeee106fa78adae',
Lei Zhang00721f02018-04-25 18:13:21 +000026 'gtest_revision': '4bd8c4638ada823a8da2569735cc0a9402fb8052',
Lei Zhang575f2382018-04-27 01:44:15 +000027 'icu_revision': 'e4194dc7bbb3305d84cbb1b294274ca70d230721',
Lei Zhang7212f322018-03-19 22:08:37 +000028 'instrumented_lib_revision': '323cf32193caecbf074d1a0cb5b02b905f163e0f',
Lei Zhang37dde5b2018-07-03 17:55:44 +000029 'jinja2_revision': '45571de473282bd1d8b63a8dfcb1fd268d0635d2',
Lei Zhang0e5d8922017-04-06 21:43:50 -070030 'jpeg_turbo_revision': '7260e4d8b8e1e40b17f03fafdf1cd83296900f76',
Dale Curtisc758d9d2017-04-06 14:10:09 -070031 'markupsafe_revision': '8f45f5cfa0009d2a70589bcda0349b8cb2b72783',
Henrique Nakashima8549ab42018-04-19 21:33:53 +000032 'pdfium_tests_revision': '9b7ff5b879ce578f4f186ad546f45fc9fb592943',
Lei Zhangc49f39d2018-03-19 22:39:27 +000033 'skia_revision': 'af7700265b74123d8ad3de6dde0c21545453140b',
Lei Zhang3658d6d2018-07-03 18:02:19 +000034 'tools_memory_revision': 'f7b00daf4df7f6c469f5fbc68d7f40f6bd15d6e6',
Lei Zhang27c8aef2018-07-03 17:55:04 +000035 'trace_event_revision': '211b3ed9d0481b4caddbee1322321b86a483ca1f',
Lei Zhang89653e32018-03-19 22:05:07 +000036 'v8_revision': '9cf8abb7ce7e3a3152fb71d0e87678e64f7ab0c8',
Lei Zhange20e80a2017-08-17 12:23:40 -070037 'yasm_source_revision': 'b98114e18d8b9b84586b10d24353ab8616d4c5fc',
Lei Zhang9d06a6c2018-07-03 17:54:24 +000038 'zlib_revision': '39b4a6260702da4c089eca57136abf40a39667e9',
Dan Sinclaira03c3432016-03-16 15:35:20 -040039}
40
Aneesh Mulye2ee9c3a2014-08-06 18:11:02 -070041deps = {
thestig5fec5972016-08-30 06:39:40 -070042 "base/trace_event/common":
43 Var('chromium_git') + "/chromium/src/base/trace_event/common.git@" +
44 Var('trace_event_revision'),
45
dsinclair685bb882016-04-20 07:32:39 -070046 "build":
47 Var('chromium_git') + "/chromium/src/build.git@" + Var('build_revision'),
Aneesh Mulye2ee9c3a2014-08-06 18:11:02 -070048
Tom Sepez4c0e2752015-06-05 13:46:08 -070049 "buildtools":
Lei Zhangeb39cdb2017-03-31 12:26:15 -070050 Var('chromium_git') + "/chromium/buildtools.git@" +
51 Var('buildtools_revision'),
Tom Sepez4c0e2752015-06-05 13:46:08 -070052
Tom Sepez9519ab22015-03-16 15:27:19 -070053 "testing/corpus":
Dan Sinclaira03c3432016-03-16 15:35:20 -040054 Var('pdfium_git') + "/pdfium_tests@" + Var('pdfium_tests_revision'),
Tom Sepez9519ab22015-03-16 15:27:19 -070055
Lei Zhangdfc08432017-12-21 07:37:15 +000056 "third_party/binutils":
57 Var('chromium_git') + "/chromium/src/third_party/binutils.git@" +
58 Var('binutils_revision'),
59
Lei Zhangab384ed2017-12-21 08:00:44 +000060 'third_party/depot_tools':
61 Var('chromium_git') + '/chromium/tools/depot_tools.git' + '@' +
62 Var('depot_tools_revision'),
63
Lei Zhangeb39cdb2017-03-31 12:26:15 -070064 "third_party/freetype/src":
65 Var('chromium_git') + '/chromium/src/third_party/freetype2.git@' +
66 Var('freetype_revision'),
67
Lei Zhangc5514272018-03-22 05:19:14 +000068 "third_party/googletest/src":
69 Var('chromium_git') + '/external/github.com/google/googletest.git' + '@' +
70 Var('gtest_revision'),
71
dsinclair685bb882016-04-20 07:32:39 -070072 "third_party/icu":
73 Var('chromium_git') + "/chromium/deps/icu.git@" + Var('icu_revision'),
74
weili62f36732016-10-14 16:59:40 -070075 "third_party/instrumented_libraries":
Lei Zhangeb39cdb2017-03-31 12:26:15 -070076 Var('chromium_git') +
77 "/chromium/src/third_party/instrumented_libraries.git@" +
78 Var('instrumented_lib_revision'),
weili62f36732016-10-14 16:59:40 -070079
Dale Curtisc758d9d2017-04-06 14:10:09 -070080 "third_party/jinja2":
81 Var('chromium_git') + "/chromium/src/third_party/jinja2.git@" +
82 Var('jinja2_revision'),
83
84 "third_party/markupsafe":
85 Var('chromium_git') + "/chromium/src/third_party/markupsafe.git@" +
86 Var('markupsafe_revision'),
87
Lei Zhang0e5d8922017-04-06 21:43:50 -070088 "third_party/libjpeg_turbo":
89 Var('chromium_git') + "/chromium/deps/libjpeg_turbo.git@" +
90 Var('jpeg_turbo_revision'),
91
Dan Sinclaira03c3432016-03-16 15:35:20 -040092 "third_party/skia":
Lei Zhangeb39cdb2017-03-31 12:26:15 -070093 Var('chromium_git') + '/skia.git@' + Var('skia_revision'),
Tom Sepez22ee2482015-01-07 10:04:16 -080094
Lei Zhanga2af7de2017-03-31 13:33:12 -070095 "third_party/zlib":
96 Var('chromium_git') + "/chromium/src/third_party/zlib.git@" +
97 Var('zlib_revision'),
98
Lei Zhang0e5d8922017-04-06 21:43:50 -070099 'third_party/yasm/source/patched-yasm':
100 Var('chromium_git') + '/chromium/deps/yasm/patched-yasm.git@' +
101 Var('yasm_source_revision'),
102
Oliver Changafaa98e2015-10-21 15:29:47 -0700103 "tools/clang":
weilib34d72b2016-04-18 12:24:36 -0700104 Var('chromium_git') + "/chromium/src/tools/clang@" + Var('clang_revision'),
Oliver Changafaa98e2015-10-21 15:29:47 -0700105
Ryan Harrisona7b65b82018-05-30 19:56:11 +0000106 "tools/code_coverage":
107 Var('chromium_git') + "/chromium/src/tools/code_coverage.git@" +
108 Var('code_coverage_revision'),
109
Tom Anderson19817af2017-07-18 18:00:18 -0700110 # TODO(GYP): Remove this when no tools rely on GYP anymore.
111 "tools/gyp":
112 Var('chromium_git') + '/external/gyp.git@' +
113 'eb296f67da078ec01f5e3a9ea9cdc6d26d680161',
114
dsinclairfb969002016-05-31 12:55:32 -0700115 "tools/memory":
116 Var('chromium_git') + "/chromium/src/tools/memory@" +
117 Var('tools_memory_revision'),
118
John Abd-El-Malekfe453722014-10-16 15:32:26 -0700119 "v8":
Dan Sinclaira03c3432016-03-16 15:35:20 -0400120 Var('chromium_git') + "/v8/v8.git@" + Var('v8_revision'),
Aneesh Mulye2ee9c3a2014-08-06 18:11:02 -0700121}
122
123deps_os = {
jbudorick7f3a15f2016-06-10 06:28:40 -0700124 "android": {
125 "third_party/android_ndk":
126 Var('chromium_git') + "/android_ndk.git@" + Var('android_ndk_revision'),
127 "third_party/catapult":
Lei Zhangeb39cdb2017-03-31 12:26:15 -0700128 Var('chromium_git') +
129 "/external/github.com/catapult-project/catapult.git@" +
130 Var('catapult_revision'),
jbudorick7f3a15f2016-06-10 06:28:40 -0700131 },
Aneesh Mulye2ee9c3a2014-08-06 18:11:02 -0700132 "win": {
John Abd-El-Malekfe453722014-10-16 15:32:26 -0700133 "v8/third_party/cygwin":
Dan Sinclaira03c3432016-03-16 15:35:20 -0400134 Var('chromium_git') + "/chromium/deps/cygwin@" + Var('cygwin_revision'),
Aneesh Mulye2ee9c3a2014-08-06 18:11:02 -0700135 },
136}
Tom Sepez4c0e2752015-06-05 13:46:08 -0700137
thestig3873f302016-09-28 17:39:26 -0700138recursedeps = [
139 # buildtools provides clang_format, libc++, and libc++abi
140 'buildtools',
141]
142
Tom Sepez4c0e2752015-06-05 13:46:08 -0700143include_rules = [
Lei Zhang8fec3e42015-11-04 15:32:02 -0800144 # Basic stuff that everyone can use.
145 # Note: public is not here because core cannot depend on public.
Lei Zhang26170562018-04-17 17:01:52 +0000146 '+constants',
Tom Sepez0c1bd7c2015-06-17 15:56:43 -0700147 '+testing',
148 '+third_party/base',
Tom Sepez4c0e2752015-06-05 13:46:08 -0700149]
Tom Sepez0c1bd7c2015-06-17 15:56:43 -0700150
weili90c964f2016-04-22 15:25:14 -0700151specific_include_rules = {
152 # Allow embedder tests to use public APIs.
153 "(.*embeddertest\.cpp)": [
154 "+public",
155 ]
156}
157
Tom Sepez0c1bd7c2015-06-17 15:56:43 -0700158hooks = [
dsinclair685bb882016-04-20 07:32:39 -0700159 {
dsinclairb4e87082016-04-20 12:18:16 -0700160 'name': 'gn_win',
dsinclair685bb882016-04-20 07:32:39 -0700161 'action': [ 'download_from_google_storage',
162 '--no_resume',
163 '--platform=win32',
164 '--no_auth',
165 '--bucket', 'chromium-gn',
166 '-s', 'pdfium/buildtools/win/gn.exe.sha1',
167 ],
168 },
169 {
170 'name': 'gn_mac',
171 'pattern': '.',
172 'action': [ 'download_from_google_storage',
173 '--no_resume',
174 '--platform=darwin',
175 '--no_auth',
176 '--bucket', 'chromium-gn',
177 '-s', 'pdfium/buildtools/mac/gn.sha1',
178 ],
179 },
180 {
181 'name': 'gn_linux64',
182 'pattern': '.',
183 'action': [ 'download_from_google_storage',
184 '--no_resume',
185 '--platform=linux*',
186 '--no_auth',
187 '--bucket', 'chromium-gn',
188 '-s', 'pdfium/buildtools/linux64/gn.sha1',
189 ],
190 },
Tom Sepeze9446f82015-08-13 15:51:43 -0700191 # Pull clang-format binaries using checked-in hashes.
192 {
193 'name': 'clang_format_win',
194 'pattern': '.',
195 'action': [ 'download_from_google_storage',
196 '--no_resume',
197 '--platform=win32',
198 '--no_auth',
199 '--bucket', 'chromium-clang-format',
Oliver Chang5a21e142015-10-21 15:19:20 -0700200 '-s', 'pdfium/buildtools/win/clang-format.exe.sha1',
Tom Sepeze9446f82015-08-13 15:51:43 -0700201 ],
202 },
203 {
204 'name': 'clang_format_mac',
205 'pattern': '.',
206 'action': [ 'download_from_google_storage',
207 '--no_resume',
208 '--platform=darwin',
209 '--no_auth',
210 '--bucket', 'chromium-clang-format',
Oliver Chang5a21e142015-10-21 15:19:20 -0700211 '-s', 'pdfium/buildtools/mac/clang-format.sha1',
Tom Sepeze9446f82015-08-13 15:51:43 -0700212 ],
213 },
214 {
215 'name': 'clang_format_linux',
216 'pattern': '.',
217 'action': [ 'download_from_google_storage',
218 '--no_resume',
219 '--platform=linux*',
220 '--no_auth',
221 '--bucket', 'chromium-clang-format',
Oliver Chang5a21e142015-10-21 15:19:20 -0700222 '-s', 'pdfium/buildtools/linux64/clang-format.sha1',
Tom Sepeze9446f82015-08-13 15:51:43 -0700223 ],
224 },
Oliver Changafaa98e2015-10-21 15:29:47 -0700225 {
dsinclairb12fbdde2016-09-19 10:45:14 -0700226 # Pull clang
Oliver Changafaa98e2015-10-21 15:29:47 -0700227 'name': 'clang',
228 'pattern': '.',
dsinclair685bb882016-04-20 07:32:39 -0700229 'action': ['python',
dsinclairb12fbdde2016-09-19 10:45:14 -0700230 'pdfium/tools/clang/scripts/update.py'
dsinclair685bb882016-04-20 07:32:39 -0700231 ],
Oliver Changafaa98e2015-10-21 15:29:47 -0700232 },
weili9a1b6652016-04-28 15:26:45 -0700233 {
Lei Zhangdfc08432017-12-21 07:37:15 +0000234 'name': 'binutils',
235 'pattern': 'src/third_party/binutils',
236 'condition': 'host_os == "linux"',
237 'action': [
238 'python',
239 'pdfium/third_party/binutils/download.py',
240 ],
241 },
242 {
Lei Zhang728127c2018-02-16 19:26:20 +0000243 'name': 'sysroot_arm',
Tom Anderson19817af2017-07-18 18:00:18 -0700244 'pattern': '.',
Lei Zhang728127c2018-02-16 19:26:20 +0000245 'condition': 'checkout_linux and checkout_arm',
Tom Anderson19817af2017-07-18 18:00:18 -0700246 'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
Lei Zhang728127c2018-02-16 19:26:20 +0000247 '--arch=arm'],
248 },
249 {
250 'name': 'sysroot_arm64',
251 'pattern': '.',
252 'condition': 'checkout_linux and checkout_arm64',
253 'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
254 '--arch=arm64'],
255 },
256 {
257 'name': 'sysroot_x86',
258 'pattern': '.',
259 'condition': 'checkout_linux and (checkout_x86 or checkout_x64)',
260 'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
261 '--arch=x86'],
262 },
263 {
264 'name': 'sysroot_mips',
265 'pattern': '.',
266 'condition': 'checkout_linux and checkout_mips',
267 'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
268 '--arch=mips'],
269 },
270 {
271 'name': 'sysroot_x64',
272 'pattern': '.',
273 'condition': 'checkout_linux and checkout_x64',
274 'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
275 '--arch=x64'],
Tom Anderson19817af2017-07-18 18:00:18 -0700276 },
277 {
Lei Zhang451c9b42018-02-21 10:35:20 +0000278 # Case-insensitivity for the Win SDK. Must run before win_toolchain below.
279 'name': 'ciopfs_linux',
280 'pattern': '.',
281 'condition': 'checkout_win and host_os == "linux"',
282 'action': [ 'python',
283 'pdfium/third_party/depot_tools/download_from_google_storage.py',
284 '--no_resume',
285 '--no_auth',
286 '--bucket', 'chromium-browser-clang/ciopfs',
287 '-s', 'pdfium/build/ciopfs.sha1',
288 ]
289 },
290 {
weili9a1b6652016-04-28 15:26:45 -0700291 # Update the Windows toolchain if necessary.
292 'name': 'win_toolchain',
293 'pattern': '.',
Lei Zhang63579f92017-12-21 19:18:00 -0800294 'condition': 'checkout_win',
Lei Zhang451c9b42018-02-21 10:35:20 +0000295 'action': ['python', 'pdfium/build/vs_toolchain.py', 'update', '--force'],
weili9a1b6652016-04-28 15:26:45 -0700296 },
weili62f36732016-10-14 16:59:40 -0700297 {
weili9053f192016-11-18 14:03:49 -0800298 # Update the Mac toolchain if necessary.
299 'name': 'mac_toolchain',
300 'pattern': '.',
301 'action': ['python', 'pdfium/build/mac_toolchain.py'],
302 },
Tom Anderson4e8edf52017-03-30 18:27:21 -0700303 {
Lei Zhangab384ed2017-12-21 08:00:44 +0000304 'name': 'msan_chained_origins',
305 'pattern': '.',
306 'condition': 'checkout_instrumented_libraries',
307 'action': [ 'python',
308 'pdfium/third_party/depot_tools/download_from_google_storage.py',
309 "--no_resume",
310 "--no_auth",
311 "--bucket", "chromium-instrumented-libraries",
312 "-s", "pdfium/third_party/instrumented_libraries/binaries/msan-chained-origins-trusty.tgz.sha1",
313 ],
314 },
315 {
316 'name': 'msan_no_origins',
317 'pattern': '.',
318 'condition': 'checkout_instrumented_libraries',
319 'action': [ 'python',
320 'pdfium/third_party/depot_tools/download_from_google_storage.py',
321 "--no_resume",
322 "--no_auth",
323 "--bucket", "chromium-instrumented-libraries",
324 "-s", "pdfium/third_party/instrumented_libraries/binaries/msan-no-origins-trusty.tgz.sha1",
325 ],
Tom Anderson4e8edf52017-03-30 18:27:21 -0700326 },
Tom Sepeze9446f82015-08-13 15:51:43 -0700327]