mirror of
https://github.com/chromium/crashpad.git
synced 2024-12-26 06:31:50 +08:00
Update Crashpad scripts to python3
Also update mini_chromium to f87a38442a9e for python3 changes. Change-Id: I4ca7aa4cc9dcc97698fc0bc13cfb339421668074 Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3542572 Reviewed-by: Mark Mentovai <mark@chromium.org> Commit-Queue: Justin Cohen <justincohen@chromium.org>
This commit is contained in:
parent
25e67e285c
commit
f88a116c0e
1
.gn
1
.gn
@ -13,3 +13,4 @@
|
||||
# limitations under the License.
|
||||
|
||||
buildconfig = "//build/BUILDCONFIG.gn"
|
||||
script_executable = "python3"
|
||||
|
4
DEPS
4
DEPS
@ -39,7 +39,7 @@ deps = {
|
||||
'e1e7b0ad8ee99a875b272c8e33e308472e897660',
|
||||
'crashpad/third_party/mini_chromium/mini_chromium':
|
||||
Var('chromium_git') + '/chromium/mini_chromium@' +
|
||||
'6e2f204b4ae135c40a6c4b3c3a01f48a86c5e886',
|
||||
'f87a38442a9e7ba88d1c4f479e9167927eae84ed',
|
||||
'crashpad/third_party/libfuzzer/src':
|
||||
Var('chromium_git') + '/chromium/llvm-project/compiler-rt/lib/fuzzer.git@' +
|
||||
'fda403cf93ecb8792cb1d061564d89a6553ca020',
|
||||
@ -169,7 +169,7 @@ hooks = [
|
||||
'pattern': '.',
|
||||
'condition': 'run_setup_ios_gn and checkout_ios',
|
||||
'action': [
|
||||
'python',
|
||||
'python3',
|
||||
'crashpad/build/ios/setup_ios_gn.py'
|
||||
],
|
||||
},
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# Copyright 2020 The Crashpad Authors. All rights reserved.
|
||||
#
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# Copyright 2020 The Crashpad Authors. All rights reserved.
|
||||
#
|
||||
@ -23,29 +23,20 @@ import shutil
|
||||
import subprocess
|
||||
import sys
|
||||
import tempfile
|
||||
|
||||
try:
|
||||
import configparser
|
||||
except ImportError:
|
||||
import ConfigParser as configparser
|
||||
|
||||
try:
|
||||
import StringIO as io
|
||||
except ImportError:
|
||||
import io
|
||||
import configparser
|
||||
import io
|
||||
|
||||
SUPPORTED_TARGETS = ('iphoneos', 'iphonesimulator')
|
||||
SUPPORTED_CONFIGS = ('Debug', 'Release', 'Profile', 'Official', 'Coverage')
|
||||
|
||||
|
||||
class ConfigParserWithStringInterpolation(configparser.SafeConfigParser):
|
||||
class ConfigParserWithStringInterpolation(configparser.ConfigParser):
|
||||
'''A .ini file parser that supports strings and environment variables.'''
|
||||
|
||||
ENV_VAR_PATTERN = re.compile(r'\$([A-Za-z0-9_]+)')
|
||||
|
||||
def values(self, section):
|
||||
return map(lambda kv: self._UnquoteString(self._ExpandEnvVar(kv[1])),
|
||||
configparser.ConfigParser.items(self, section))
|
||||
return [self._UnquoteString(self._ExpandEnvVar(kv[1])) for kv in configparser.ConfigParser.items(self, section)]
|
||||
|
||||
def getstring(self, section, option):
|
||||
return self._UnquoteString(self._ExpandEnvVar(self.get(section,
|
||||
@ -110,7 +101,7 @@ class GnGenerator(object):
|
||||
args.append(('target_cpu', target_cpu))
|
||||
args.append(
|
||||
('additional_target_cpus',
|
||||
[cpu for cpu in cpu_values.itervalues() if cpu != target_cpu]))
|
||||
[cpu for cpu in cpu_values.values() if cpu != target_cpu]))
|
||||
else:
|
||||
args.append(('target_cpu', cpu_values[build_arch]))
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# Copyright 2017 The Crashpad Authors. All rights reserved.
|
||||
#
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# Copyright 2015 The Crashpad Authors. All rights reserved.
|
||||
#
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# Copyright 2019 The Crashpad Authors. All rights reserved.
|
||||
#
|
||||
|
@ -1,5 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
# coding: utf-8
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# Copyright 2019 The Crashpad Authors. All rights reserved.
|
||||
#
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
|
||||
# Copyright 2019 The Crashpad Authors. All rights reserved.
|
||||
#
|
||||
|
Loading…
x
Reference in New Issue
Block a user