mac: Disable crash reporter for MAS build
This commit is contained in:
parent
644af0800c
commit
a9f5667899
4 changed files with 50 additions and 10 deletions
31
atom.gyp
31
atom.gyp
|
@ -285,12 +285,21 @@
|
||||||
'vendor/breakpad/breakpad.gyp:breakpad_sender',
|
'vendor/breakpad/breakpad.gyp:breakpad_sender',
|
||||||
],
|
],
|
||||||
}], # OS=="win"
|
}], # OS=="win"
|
||||||
['OS=="mac"', {
|
['OS=="mac" and mas_build==0', {
|
||||||
'dependencies': [
|
'dependencies': [
|
||||||
'vendor/crashpad/client/client.gyp:crashpad_client',
|
'vendor/crashpad/client/client.gyp:crashpad_client',
|
||||||
'vendor/crashpad/handler/handler.gyp:crashpad_handler',
|
'vendor/crashpad/handler/handler.gyp:crashpad_handler',
|
||||||
],
|
],
|
||||||
}], # OS=="mac"
|
}], # OS=="mac" and mas_build==0
|
||||||
|
['OS=="mac" and mas_build==1', {
|
||||||
|
'defines': [
|
||||||
|
'MAS_BUILD',
|
||||||
|
],
|
||||||
|
'sources!': [
|
||||||
|
'atom/common/crash_reporter/crash_reporter_mac.h',
|
||||||
|
'atom/common/crash_reporter/crash_reporter_mac.mm',
|
||||||
|
],
|
||||||
|
}], # OS=="mac" and mas_build==1
|
||||||
['OS=="linux"', {
|
['OS=="linux"', {
|
||||||
'link_settings': {
|
'link_settings': {
|
||||||
'ldflags': [
|
'ldflags': [
|
||||||
|
@ -439,12 +448,6 @@
|
||||||
'<@(copied_libraries)',
|
'<@(copied_libraries)',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
|
||||||
'destination': '<(PRODUCT_DIR)/<(product_name) Framework.framework/Versions/A/Resources',
|
|
||||||
'files': [
|
|
||||||
'<(PRODUCT_DIR)/crashpad_handler',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
],
|
],
|
||||||
'postbuilds': [
|
'postbuilds': [
|
||||||
{
|
{
|
||||||
|
@ -476,6 +479,18 @@
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
'conditions': [
|
||||||
|
['mas_build==0', {
|
||||||
|
'copies': [
|
||||||
|
{
|
||||||
|
'destination': '<(PRODUCT_DIR)/<(product_name) Framework.framework/Versions/A/Resources',
|
||||||
|
'files': [
|
||||||
|
'<(PRODUCT_DIR)/crashpad_handler',
|
||||||
|
],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
}],
|
||||||
|
],
|
||||||
}, # target framework
|
}, # target framework
|
||||||
{
|
{
|
||||||
'target_name': '<(project_name)_helper',
|
'target_name': '<(project_name)_helper',
|
||||||
|
|
|
@ -64,4 +64,23 @@ CrashReporter::GetUploadedReports(const std::string& path) {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(OS_MACOSX) && defined(MAS_BUILD)
|
||||||
|
void CrashReporter::InitBreakpad(const std::string& product_name,
|
||||||
|
const std::string& version,
|
||||||
|
const std::string& company_name,
|
||||||
|
const std::string& submit_url,
|
||||||
|
bool auto_submit,
|
||||||
|
bool skip_system_crash_handler) {
|
||||||
|
}
|
||||||
|
|
||||||
|
void CrashReporter::SetUploadParameters() {
|
||||||
|
}
|
||||||
|
|
||||||
|
// static
|
||||||
|
CrashReporter* CrashReporter::GetInstance() {
|
||||||
|
static CrashReporter crash_reporter;
|
||||||
|
return &crash_reporter;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
} // namespace crash_reporter
|
} // namespace crash_reporter
|
||||||
|
|
|
@ -40,8 +40,8 @@ class CrashReporter {
|
||||||
const std::string& company_name,
|
const std::string& company_name,
|
||||||
const std::string& submit_url,
|
const std::string& submit_url,
|
||||||
bool auto_submit,
|
bool auto_submit,
|
||||||
bool skip_system_crash_handler) = 0;
|
bool skip_system_crash_handler);
|
||||||
virtual void SetUploadParameters() = 0;
|
virtual void SetUploadParameters();
|
||||||
|
|
||||||
StringMap upload_parameters_;
|
StringMap upload_parameters_;
|
||||||
bool is_browser_;
|
bool is_browser_;
|
||||||
|
|
|
@ -55,11 +55,17 @@ def run_gyp(target_arch, component):
|
||||||
# Avoid using the old gyp lib in system.
|
# Avoid using the old gyp lib in system.
|
||||||
env['PYTHONPATH'] = os.path.pathsep.join([gyp_pylib,
|
env['PYTHONPATH'] = os.path.pathsep.join([gyp_pylib,
|
||||||
env.get('PYTHONPATH', '')])
|
env.get('PYTHONPATH', '')])
|
||||||
|
# Whether to build for Mac App Store.
|
||||||
|
if os.environ.has_key('MAS_BUILD'):
|
||||||
|
mas_build = 1
|
||||||
|
else:
|
||||||
|
mas_build = 0
|
||||||
defines = [
|
defines = [
|
||||||
'-Dlibchromiumcontent_component={0}'.format(component),
|
'-Dlibchromiumcontent_component={0}'.format(component),
|
||||||
'-Dtarget_arch={0}'.format(target_arch),
|
'-Dtarget_arch={0}'.format(target_arch),
|
||||||
'-Dhost_arch={0}'.format(get_host_arch()),
|
'-Dhost_arch={0}'.format(get_host_arch()),
|
||||||
'-Dlibrary=static_library',
|
'-Dlibrary=static_library',
|
||||||
|
'-Dmas_build={0}'.format(mas_build),
|
||||||
]
|
]
|
||||||
return subprocess.call([python, gyp, '-f', 'ninja', '--depth', '.',
|
return subprocess.call([python, gyp, '-f', 'ninja', '--depth', '.',
|
||||||
'atom.gyp', '-Icommon.gypi'] + defines, env=env)
|
'atom.gyp', '-Icommon.gypi'] + defines, env=env)
|
||||||
|
|
Loading…
Reference in a new issue