Skip to content

Commit c8ff03c

Browse files
author
George Wright
authored
Publish validation layer deps as part of the fuchsia artifacts (flutter#18214)
1 parent 7035255 commit c8ff03c

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

tools/fuchsia/build_fuchsia_artifacts.py

+16-3
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,7 @@ def IsLinux():
3232
def IsMac():
3333
return platform.system() == 'Darwin'
3434

35-
36-
def GetPMBinPath():
35+
def GetFuchsiaSDKPath():
3736
# host_os references the gn host_os
3837
# https://gn.googlesource.com/gn/+/master/docs/reference.md#var_host_os
3938
host_os = ''
@@ -44,7 +43,11 @@ def GetPMBinPath():
4443
else:
4544
host_os = 'windows'
4645

47-
return os.path.join(_src_root_dir, 'fuchsia', 'sdk', host_os, 'tools', 'pm')
46+
return os.path.join(_src_root_dir, 'fuchsia', 'sdk', host_os)
47+
48+
49+
def GetPMBinPath():
50+
return os.path.join(GetFuchsiaSDKPath(), 'tools', 'pm')
4851

4952

5053
def RunExecutable(command):
@@ -149,10 +152,20 @@ def CopyToBucket(src, dst, product=False):
149152
CopyToBucketWithMode(src, dst, True, product, 'dart')
150153

151154

155+
def CopyVulkanDepsToBucket(src, dst, arch):
156+
sdk_path = GetFuchsiaSDKPath()
157+
deps_bucket_path = os.path.join(_bucket_directory, dst)
158+
if not os.path.exists(deps_bucket_path):
159+
FindFileAndCopyTo('VkLayer_khronos_validation.json', '%s/pkg' % (sdk_path), deps_bucket_path)
160+
FindFileAndCopyTo('VkLayer_khronos_validation.so', '%s/arch/%s' % (sdk_path, arch), deps_bucket_path)
161+
162+
152163
def BuildBucket(runtime_mode, arch, product):
153164
out_dir = 'fuchsia_%s_%s/' % (runtime_mode, arch)
154165
bucket_dir = 'flutter/%s/%s/' % (arch, runtime_mode)
166+
deps_dir = 'flutter/%s/deps/' % (arch)
155167
CopyToBucket(out_dir, bucket_dir, product)
168+
CopyVulkanDepsToBucket(out_dir, deps_dir, arch)
156169

157170

158171
def ProcessCIPDPackage(upload, engine_version):

0 commit comments

Comments
 (0)