build: ensure symbol files are named lowercase on disk so that boto can find them (#24856)
This commit is contained in:
parent
9274117e12
commit
a2c82f2342
1 changed files with 12 additions and 0 deletions
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
import glob
|
import glob
|
||||||
import os
|
import os
|
||||||
|
import shutil
|
||||||
import subprocess
|
import subprocess
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
|
@ -49,7 +50,18 @@ def main():
|
||||||
|
|
||||||
# The symbol server needs lowercase paths, it will fail otherwise
|
# The symbol server needs lowercase paths, it will fail otherwise
|
||||||
# So lowercase all the file paths here
|
# So lowercase all the file paths here
|
||||||
|
for f in files:
|
||||||
|
lower_f = f.lower()
|
||||||
|
if lower_f != f:
|
||||||
|
if os.path.exists(lower_f):
|
||||||
|
shutil.rmtree(lower_f)
|
||||||
|
lower_dir = os.path.dirname(lower_f)
|
||||||
|
if not os.path.exists(lower_dir):
|
||||||
|
os.makedirs(lower_dir)
|
||||||
|
shutil.copy2(f, lower_f)
|
||||||
files = [f.lower() for f in files]
|
files = [f.lower() for f in files]
|
||||||
|
for f in files:
|
||||||
|
assert os.path.exists(f)
|
||||||
|
|
||||||
bucket, access_key, secret_key = s3_config()
|
bucket, access_key, secret_key = s3_config()
|
||||||
upload_symbols(bucket, access_key, secret_key, files)
|
upload_symbols(bucket, access_key, secret_key, files)
|
||||||
|
|
Loading…
Add table
Reference in a new issue