• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1use_relative_paths = True
2
3vars = {
4  # 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  'checkout_instrumented_libraries': 'checkout_linux and checkout_configuration != "small"',
11
12  'chromium_git': 'https://chromium.googlesource.com',
13  'pdfium_git': 'https://pdfium.googlesource.com',
14
15  'android_ndk_revision': '27c0a8d090c666a50e40fceb4ee5b40b1a2d3f87',
16  'binutils_revision': '01aa7745b0bab64ae22600f09fd6483c60f22ebf',
17  'build_revision': '1bee638a8c4a9481ea06df4982d69488d0a5626d',
18  'buildtools_revision': '1f38b432e5630619f3aba0a22b9b63d606aee35a',
19  'catapult_revision': 'f7d73bb520283d2a06b8fde8a1b02aa33414fcd0',
20  'clang_revision': '42fbdfef1ce265b09dc6bda2ed90d83324c97481',
21  'code_coverage_revision': 'c7a868bacaccf4f52848e04564fb7de0671e0727',
22  'depot_tools_revision': 'e9730d75a00548a22e4392567243969d85c02dd4',
23  'freetype_revision': 'e5038be70414cf66da6c4d5ce4e30375884c30d8',
24  'gtest_revision': '5395345ca4f0c596110188688ed990e0de5a181c',
25  'icu_revision': 'dbd3825b31041d782c5b504c59dcfb5ac7dda08c',
26  'instrumented_lib_revision': '4dca59c6a614b08b394ed6154a8fcded9298b07e',
27  'jinja2_revision': 'b41863e42637544c2941b574c7877d3e1f663e25',
28  'jpeg_turbo_revision': 'ce0e57e8e636f5132fe6f0590a4dba91f92fd935',
29  'markupsafe_revision': '8f45f5cfa0009d2a70589bcda0349b8cb2b72783',
30  'pdfium_tests_revision': '02dd653ec62649b6f1aa4e4526071cc32d903f54',
31  'skia_revision': 'd50cc95872a8a832faea0154f7ea1fd56cebc775',
32  'tools_memory_revision': 'f7b00daf4df7f6c469f5fbc68d7f40f6bd15d6e6',
33  'trace_event_revision': '81c050f857a0e3c960cfd87f37e3d30d2ef78718',
34  'v8_revision': 'cd34145326def51cb6dcf87aed7d0caf9f62bb4f',
35  'yasm_source_revision': '720b70524a4424b15fc57e82263568c8ba0496ad',
36  'zlib_revision': '814da1f383b625955149c3845db62af3f29a4ffe',
37}
38
39deps = {
40  "base/trace_event/common":
41    Var('chromium_git') + "/chromium/src/base/trace_event/common.git@" +
42        Var('trace_event_revision'),
43
44  "build":
45    Var('chromium_git') + "/chromium/src/build.git@" + Var('build_revision'),
46
47  "buildtools":
48    Var('chromium_git') + "/chromium/src/buildtools.git@" +
49        Var('buildtools_revision'),
50
51  "testing/corpus":
52    Var('pdfium_git') + "/pdfium_tests@" + Var('pdfium_tests_revision'),
53
54  "third_party/android_ndk": {
55    'url': Var('chromium_git') + "/android_ndk.git@" + Var('android_ndk_revision'),
56    'condition': 'checkout_android',
57  },
58
59  "third_party/binutils":
60    Var('chromium_git') + "/chromium/src/third_party/binutils.git@" +
61        Var('binutils_revision'),
62
63  "third_party/catapult": {
64    'url': Var('chromium_git') + '/catapult.git' + '@' + Var('catapult_revision'),
65    'condition': 'checkout_android',
66  },
67
68  'third_party/depot_tools':
69    Var('chromium_git') + '/chromium/tools/depot_tools.git' + '@' +
70        Var('depot_tools_revision'),
71
72  "third_party/freetype/src":
73    Var('chromium_git') + '/chromium/src/third_party/freetype2.git@' +
74        Var('freetype_revision'),
75
76  "third_party/googletest/src":
77    Var('chromium_git') + '/external/github.com/google/googletest.git' + '@' +
78        Var('gtest_revision'),
79
80  "third_party/icu":
81    Var('chromium_git') + "/chromium/deps/icu.git@" + Var('icu_revision'),
82
83  "third_party/instrumented_libraries":
84    Var('chromium_git') +
85        "/chromium/src/third_party/instrumented_libraries.git@" +
86        Var('instrumented_lib_revision'),
87
88  "third_party/jinja2":
89    Var('chromium_git') + "/chromium/src/third_party/jinja2.git@" +
90        Var('jinja2_revision'),
91
92  "third_party/markupsafe":
93    Var('chromium_git') + "/chromium/src/third_party/markupsafe.git@" +
94        Var('markupsafe_revision'),
95
96  "third_party/libjpeg_turbo":
97    Var('chromium_git') + "/chromium/deps/libjpeg_turbo.git@" +
98        Var('jpeg_turbo_revision'),
99
100  "third_party/skia":
101    Var('chromium_git') + '/skia.git@' +  Var('skia_revision'),
102
103  "third_party/zlib":
104    Var('chromium_git') + "/chromium/src/third_party/zlib.git@" +
105        Var('zlib_revision'),
106
107  'third_party/yasm/source/patched-yasm':
108    Var('chromium_git') + '/chromium/deps/yasm/patched-yasm.git@' +
109        Var('yasm_source_revision'),
110
111  "tools/clang":
112    Var('chromium_git') + "/chromium/src/tools/clang@" +  Var('clang_revision'),
113
114  "tools/code_coverage":
115    Var('chromium_git') + "/chromium/src/tools/code_coverage.git@" +
116        Var('code_coverage_revision'),
117
118  "tools/memory":
119    Var('chromium_git') + "/chromium/src/tools/memory@" +
120        Var('tools_memory_revision'),
121
122  "v8":
123    Var('chromium_git') + "/v8/v8.git@" + Var('v8_revision'),
124}
125
126recursedeps = [
127  # buildtools provides clang_format, libc++, and libc++abi
128  'buildtools',
129]
130
131include_rules = [
132  # Basic stuff that everyone can use.
133  # Note: public is not here because core cannot depend on public.
134  '+build/build_config.h',
135  '+constants',
136  '+testing',
137  '+third_party/base',
138]
139
140specific_include_rules = {
141  # Allow embedder tests to use public APIs.
142  "(.*embeddertest\.cpp)": [
143      "+public",
144  ]
145}
146
147hooks = [
148  {
149    # Case-insensitivity for the Win SDK. Must run before win_toolchain below.
150    'name': 'ciopfs_linux',
151    'pattern': '.',
152    'condition': 'checkout_win and host_os == "linux"',
153    'action': [ 'python',
154                'pdfium/third_party/depot_tools/download_from_google_storage.py',
155                '--no_resume',
156                '--no_auth',
157                '--bucket', 'chromium-browser-clang/ciopfs',
158                '-s', 'pdfium/build/ciopfs.sha1',
159    ]
160  },
161  {
162    # Update the Windows toolchain if necessary.  Must run before 'clang' below.
163    'name': 'win_toolchain',
164    'pattern': '.',
165    'condition': 'checkout_win',
166    'action': ['python', 'pdfium/build/vs_toolchain.py', 'update', '--force'],
167  },
168  {
169    # Update the Mac toolchain if necessary.
170    'name': 'mac_toolchain',
171    'pattern': '.',
172    'action': ['python', 'pdfium/build/mac_toolchain.py'],
173  },
174  {
175    # Pull clang-format binaries using checked-in hashes.
176    'name': 'clang_format_win',
177    'pattern': '.',
178    'action': [ 'download_from_google_storage',
179                '--no_resume',
180                '--platform=win32',
181                '--no_auth',
182                '--bucket', 'chromium-clang-format',
183                '-s', 'pdfium/buildtools/win/clang-format.exe.sha1',
184    ],
185  },
186  {
187    'name': 'clang_format_mac',
188    'pattern': '.',
189    'action': [ 'download_from_google_storage',
190                '--no_resume',
191                '--platform=darwin',
192                '--no_auth',
193                '--bucket', 'chromium-clang-format',
194                '-s', 'pdfium/buildtools/mac/clang-format.sha1',
195    ],
196  },
197  {
198    'name': 'clang_format_linux',
199    'pattern': '.',
200    'action': [ 'download_from_google_storage',
201                '--no_resume',
202                '--platform=linux*',
203                '--no_auth',
204                '--bucket', 'chromium-clang-format',
205                '-s', 'pdfium/buildtools/linux64/clang-format.sha1',
206    ],
207  },
208  {
209    # Note: On Win, this should run after win_toolchain, as it may use it.
210    'name': 'clang',
211    'pattern': '.',
212    'action': ['python',
213               'pdfium/tools/clang/scripts/update.py'
214    ],
215  },
216  {
217    'name': 'binutils',
218    'pattern': 'src/third_party/binutils',
219    'condition': 'host_os == "linux"',
220    'action': [
221        'python',
222        'pdfium/third_party/binutils/download.py',
223    ],
224  },
225  {
226    'name': 'sysroot_arm',
227    'pattern': '.',
228    'condition': 'checkout_linux and checkout_arm',
229    'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
230               '--arch=arm'],
231  },
232  {
233    'name': 'sysroot_arm64',
234    'pattern': '.',
235    'condition': 'checkout_linux and checkout_arm64',
236    'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
237               '--arch=arm64'],
238  },
239  {
240    'name': 'sysroot_x86',
241    'pattern': '.',
242    'condition': 'checkout_linux and (checkout_x86 or checkout_x64)',
243    'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
244               '--arch=x86'],
245  },
246  {
247    'name': 'sysroot_mips',
248    'pattern': '.',
249    'condition': 'checkout_linux and checkout_mips',
250    'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
251               '--arch=mips'],
252  },
253  {
254    'name': 'sysroot_x64',
255    'pattern': '.',
256    'condition': 'checkout_linux and checkout_x64',
257    'action': ['python', 'pdfium/build/linux/sysroot_scripts/install-sysroot.py',
258               '--arch=x64'],
259  },
260  {
261    'name': 'msan_chained_origins',
262    'pattern': '.',
263    'condition': 'checkout_instrumented_libraries',
264    'action': [ 'python',
265                'pdfium/third_party/depot_tools/download_from_google_storage.py',
266                "--no_resume",
267                "--no_auth",
268                "--bucket", "chromium-instrumented-libraries",
269                "-s", "pdfium/third_party/instrumented_libraries/binaries/msan-chained-origins-trusty.tgz.sha1",
270              ],
271  },
272  {
273    'name': 'msan_no_origins',
274    'pattern': '.',
275    'condition': 'checkout_instrumented_libraries',
276    'action': [ 'python',
277                'pdfium/third_party/depot_tools/download_from_google_storage.py',
278                "--no_resume",
279                "--no_auth",
280                "--bucket", "chromium-instrumented-libraries",
281                "-s", "pdfium/third_party/instrumented_libraries/binaries/msan-no-origins-trusty.tgz.sha1",
282              ],
283  },
284  {
285    # Update LASTCHANGE.
286    'name': 'lastchange',
287    'pattern': '.',
288    'action': ['python', 'pdfium/build/util/lastchange.py',
289               '-o', 'pdfium/build/util/LASTCHANGE'],
290  },
291]
292