blob: b39b02d8adee01be424959f96f27eb31d59b7b14 [file] [log] [blame]
Dan Sinclair6e581892020-03-02 15:47:43 -05001use_relative_paths = True
2
Ryan Harrison7b819aa2020-07-07 19:11:07 +00003gclient_gn_args_file = 'build/config/gclient_args.gni'
Ryan Harrison7b819aa2020-07-07 19:11:07 +00004
Ben Clayton7b0686a2022-01-06 09:23:11 +00005gclient_gn_args = [
6 'generate_location_tags',
7]
8
Dan Sinclair6e581892020-03-02 15:47:43 -05009vars = {
Ryan Harrison3374f432022-03-28 18:01:02 +000010 'chromium_git': 'https://chromium.googlesource.com',
Dan Sinclair6e581892020-03-02 15:47:43 -050011
Ben Clayton7b0686a2022-01-06 09:23:11 +000012 'tint_gn_revision': 'git_revision:281ba2c91861b10fec7407c4b6172ec3d4661243',
13
14 # We don't use location metadata in our test isolates.
15 'generate_location_tags': False,
Dan Sinclair6e581892020-03-02 15:47:43 -050016}
17
18deps = {
Ryan Harrison3374f432022-03-28 18:01:02 +000019 'third_party/gpuweb-cts': {
20 'url': '{chromium_git}/external/github.com/gpuweb/cts@b0291fd966b55a5efc496772555b94842bde1085',
21 },
dan sinclair429aa812020-07-23 15:01:37 +000022
Ryan Harrison3374f432022-03-28 18:01:02 +000023 'third_party/vulkan-deps': {
Ben Clayton2d498982022-11-23 20:44:33 +000024 'url': '{chromium_git}/vulkan-deps@bd2c589d0d34612d9dd071396225d7de772c020c',
Ryan Harrison3374f432022-03-28 18:01:02 +000025 },
Stephen White7cf3b282021-10-14 14:39:36 +000026
Ryan Harrison29628882020-04-08 20:40:25 +000027 # Dependencies required to use GN/Clang in standalone
Ryan Harrison3374f432022-03-28 18:01:02 +000028 'build': {
Ben Clayton2d498982022-11-23 20:44:33 +000029 'url': '{chromium_git}/chromium/src/build@01569374d46a14b225586c564146a8e1749520b6',
Ryan Harrison3374f432022-03-28 18:01:02 +000030 },
Ryan Harrison29628882020-04-08 20:40:25 +000031
Ryan Harrison3374f432022-03-28 18:01:02 +000032 'buildtools': {
Ben Clayton2d498982022-11-23 20:44:33 +000033 'url': '{chromium_git}/chromium/src/buildtools@cccaf48c82bcf4ddafa6f8aa9f06014a1ef434bf',
Ryan Harrison3374f432022-03-28 18:01:02 +000034 },
Ryan Harrison29628882020-04-08 20:40:25 +000035
Ryan Harrison3374f432022-03-28 18:01:02 +000036 'tools/clang': {
Ben Clayton2d498982022-11-23 20:44:33 +000037 'url': '{chromium_git}/chromium/src/tools/clang@a5e0d72349d028a4023927d6d166a8478355fac3',
Ryan Harrison3374f432022-03-28 18:01:02 +000038 },
Ryan Harrison29628882020-04-08 20:40:25 +000039
Ben Clayton7b0686a2022-01-06 09:23:11 +000040 'buildtools/clang_format/script': {
Ben Clayton2d498982022-11-23 20:44:33 +000041 'url': '{chromium_git}/external/github.com/llvm/llvm-project/clang/tools/clang-format.git@8b525d2747f2584fc35d8c7e612e66f377858df7',
Ben Clayton7b0686a2022-01-06 09:23:11 +000042 },
43
44 'buildtools/linux64': {
45 'packages': [{
46 'package': 'gn/gn/linux-amd64',
47 'version': Var('tint_gn_revision'),
48 }],
49 'dep_type': 'cipd',
50 'condition': 'host_os == "linux"',
51 },
52 'buildtools/mac': {
53 'packages': [{
54 'package': 'gn/gn/mac-${{arch}}',
55 'version': Var('tint_gn_revision'),
56 }],
57 'dep_type': 'cipd',
58 'condition': 'host_os == "mac"',
59 },
60 'buildtools/win': {
61 'packages': [{
62 'package': 'gn/gn/windows-amd64',
63 'version': Var('tint_gn_revision'),
64 }],
65 'dep_type': 'cipd',
66 'condition': 'host_os == "win"',
67 },
68
Ryan Harrison3374f432022-03-28 18:01:02 +000069 'buildtools/third_party/libc++/trunk': {
Ben Clayton2d498982022-11-23 20:44:33 +000070 'url': '{chromium_git}/external/github.com/llvm/llvm-project/libcxx.git@26d0ab4151fd10c523fdbb5bbdb59aa5a5774820',
Ryan Harrison3374f432022-03-28 18:01:02 +000071 },
Ben Clayton7b0686a2022-01-06 09:23:11 +000072
Ryan Harrison3374f432022-03-28 18:01:02 +000073 'buildtools/third_party/libc++abi/trunk': {
Ben Clayton2d498982022-11-23 20:44:33 +000074 'url': '{chromium_git}/external/github.com/llvm/llvm-project/libcxxabi.git@5c3e02e92ae8bbc1bf1001bd9ef0d76e044ddb86',
Ryan Harrison3374f432022-03-28 18:01:02 +000075 },
Ben Clayton7b0686a2022-01-06 09:23:11 +000076
Junji Watanabe5600d612022-11-14 09:56:30 +000077 'third_party/ninja': {
78 'packages': [
79 # https://chrome-infra-packages.appspot.com/p/infra/3pp/tools/ninja
80 {
81 'package': 'infra/3pp/tools/ninja/${{platform}}',
82 'version': 'version:2@1.8.2.chromium.3',
83 }
84 ],
85 'dep_type': 'cipd',
86 },
87
Ryan Harrison0a196c12020-04-17 13:18:20 +000088 # Dependencies required for testing
Ryan Harrison3374f432022-03-28 18:01:02 +000089 'testing': {
Ben Clayton2d498982022-11-23 20:44:33 +000090 'url': '{chromium_git}/chromium/src/testing@e3e8c19554e8f47da85d35e4f990cdc30a061196',
Ryan Harrison3374f432022-03-28 18:01:02 +000091 },
Ryan Harrison0a196c12020-04-17 13:18:20 +000092
Ryan Harrison3374f432022-03-28 18:01:02 +000093 'third_party/catapult': {
Ben Clayton2d498982022-11-23 20:44:33 +000094 'url': '{chromium_git}/catapult.git@4a0e6f034e9756605cfc837c8526588d6c13436b',
Ryan Harrison3374f432022-03-28 18:01:02 +000095 },
Ben Clayton7b0686a2022-01-06 09:23:11 +000096
Ryan Harrison3374f432022-03-28 18:01:02 +000097 'third_party/benchmark': {
98 'url': '{chromium_git}/external/github.com/google/benchmark.git@e991355c02b93fe17713efe04cbc2e278e00fdbd',
99 },
Ben Claytonbe2362b2022-01-18 18:58:16 +0000100
Ryan Harrison3374f432022-03-28 18:01:02 +0000101 'third_party/googletest': {
Ben Clayton2d498982022-11-23 20:44:33 +0000102 'url': '{chromium_git}/external/github.com/google/googletest.git@d1a0039b97291dd1dc14f123b906bb7622ffe07c',
Ryan Harrison3374f432022-03-28 18:01:02 +0000103 },
Vasyl Teliman0b3611b2021-06-24 18:10:46 +0000104
Ryan Harrison3374f432022-03-28 18:01:02 +0000105 'third_party/protobuf': {
106 'url': '{chromium_git}/external/github.com/protocolbuffers/protobuf.git@fde7cf7358ec7cd69e8db9be4f1fa6a5c431386a',
107 },
Dan Sinclair6e581892020-03-02 15:47:43 -0500108}
Ryan Harrison29628882020-04-08 20:40:25 +0000109
110hooks = [
111 # Pull clang-format binaries using checked-in hashes.
112 {
113 'name': 'clang_format_win',
114 'pattern': '.',
115 'condition': 'host_os == "win"',
116 'action': [ 'download_from_google_storage',
117 '--no_resume',
Ryan Harrison29628882020-04-08 20:40:25 +0000118 '--no_auth',
119 '--bucket', 'chromium-clang-format',
120 '-s', 'buildtools/win/clang-format.exe.sha1',
121 ],
122 },
123 {
Ben Clayton2d498982022-11-23 20:44:33 +0000124 'name': 'clang_format_mac_x64',
Ryan Harrison29628882020-04-08 20:40:25 +0000125 'pattern': '.',
Ben Clayton2d498982022-11-23 20:44:33 +0000126 'condition': 'host_os == "mac" and host_cpu == "x64"',
Ryan Harrison29628882020-04-08 20:40:25 +0000127 'action': [ 'download_from_google_storage',
128 '--no_resume',
Ryan Harrison29628882020-04-08 20:40:25 +0000129 '--no_auth',
130 '--bucket', 'chromium-clang-format',
Ben Clayton2d498982022-11-23 20:44:33 +0000131 '-s', 'buildtools/mac/clang-format.x64.sha1',
132 '-o', 'buildtools/mac/clang-format',
133 ],
134 },
135 {
136 'name': 'clang_format_mac_arm64',
137 'pattern': '.',
138 'condition': 'host_os == "mac" and host_cpu == "arm64"',
139 'action': [ 'download_from_google_storage',
140 '--no_resume',
141 '--no_auth',
142 '--bucket', 'chromium-clang-format',
143 '-s', 'buildtools/mac/clang-format.arm64.sha1',
144 '-o', 'buildtools/mac/clang-format',
Ryan Harrison29628882020-04-08 20:40:25 +0000145 ],
146 },
147 {
148 'name': 'clang_format_linux',
149 'pattern': '.',
150 'condition': 'host_os == "linux"',
151 'action': [ 'download_from_google_storage',
152 '--no_resume',
Ryan Harrison29628882020-04-08 20:40:25 +0000153 '--no_auth',
154 '--bucket', 'chromium-clang-format',
155 '-s', 'buildtools/linux64/clang-format.sha1',
156 ],
157 },
158
159 # Pull the compilers and system libraries for hermetic builds
160 {
161 'name': 'sysroot_x86',
162 'pattern': '.',
163 'condition': 'checkout_linux and ((checkout_x86 or checkout_x64))',
Ben Clayton7b0686a2022-01-06 09:23:11 +0000164 'action': ['python3', 'build/linux/sysroot_scripts/install-sysroot.py',
Ryan Harrison29628882020-04-08 20:40:25 +0000165 '--arch=x86'],
166 },
167 {
168 'name': 'sysroot_x64',
169 'pattern': '.',
170 'condition': 'checkout_linux and (checkout_x64)',
Ben Clayton7b0686a2022-01-06 09:23:11 +0000171 'action': ['python3', 'build/linux/sysroot_scripts/install-sysroot.py',
Ryan Harrison29628882020-04-08 20:40:25 +0000172 '--arch=x64'],
173 },
174 {
Ryan Harrison2733c262020-11-16 21:11:19 +0000175 # Update the Mac toolchain if necessary.
176 'name': 'mac_toolchain',
177 'pattern': '.',
178 'condition': 'checkout_mac',
Ben Clayton7b0686a2022-01-06 09:23:11 +0000179 'action': ['python3', 'build/mac_toolchain.py'],
Ryan Harrison2733c262020-11-16 21:11:19 +0000180 },
181 {
Ryan Harrison29628882020-04-08 20:40:25 +0000182 # Update the Windows toolchain if necessary. Must run before 'clang' below.
183 'name': 'win_toolchain',
184 'pattern': '.',
185 'condition': 'checkout_win',
Ben Clayton7b0686a2022-01-06 09:23:11 +0000186 'action': ['python3', 'build/vs_toolchain.py', 'update', '--force'],
Ryan Harrison29628882020-04-08 20:40:25 +0000187 },
188 {
189 # Note: On Win, this should run after win_toolchain, as it may use it.
190 'name': 'clang',
191 'pattern': '.',
Ben Clayton7b0686a2022-01-06 09:23:11 +0000192 'action': ['python3', 'tools/clang/scripts/update.py'],
Ryan Harrison29628882020-04-08 20:40:25 +0000193 },
194 {
195 # Pull rc binaries using checked-in hashes.
196 'name': 'rc_win',
197 'pattern': '.',
198 'condition': 'checkout_win and (host_os == "win")',
199 'action': [ 'download_from_google_storage',
200 '--no_resume',
201 '--no_auth',
202 '--bucket', 'chromium-browser-clang/rc',
203 '-s', 'build/toolchain/win/rc/win/rc.exe.sha1',
204 ],
205 },
Ryan Harrison29628882020-04-08 20:40:25 +0000206 # Update build/util/LASTCHANGE.
207 {
208 'name': 'lastchange',
209 'pattern': '.',
Ben Clayton7b0686a2022-01-06 09:23:11 +0000210 'action': ['python3', 'build/util/lastchange.py',
Ryan Harrison29628882020-04-08 20:40:25 +0000211 '-o', 'build/util/LASTCHANGE'],
212 },
213]
214
215recursedeps = [
216 # buildtools provides clang_format, libc++, and libc++abi
217 'buildtools',
Ryan Harrison3374f432022-03-28 18:01:02 +0000218 # vulkan-deps provides spirv-headers, spirv-tools & gslang
219 # It also provides other Vulkan tools that Tint doesn't use
220 'third_party/vulkan-deps',
Ryan Harrison29628882020-04-08 20:40:25 +0000221]