From b303174e32c0fff0e80a219c3c0c25d78bf51596 Mon Sep 17 00:00:00 2001 From: "blundell@chromium.org" Date: Mon, 2 Dec 2013 16:02:48 +0000 Subject: Re-enable ios_exception_minidump_generator being built on non-ARM. This file gets built on x86 as part of building Chromium for the iOS simulator, which I had forgotten in the course of https://breakpad.appspot.com/664002/. R=mark@chromium.org Review URL: https://breakpad.appspot.com/774002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1238 4c0a9323-5329-0410-9bdc-e9ce6186880e --- src/client/ios/handler/ios_exception_minidump_generator.mm | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src/client/ios') diff --git a/src/client/ios/handler/ios_exception_minidump_generator.mm b/src/client/ios/handler/ios_exception_minidump_generator.mm index 491c4916..d7db876b 100644 --- a/src/client/ios/handler/ios_exception_minidump_generator.mm +++ b/src/client/ios/handler/ios_exception_minidump_generator.mm @@ -37,10 +37,6 @@ #include "client/minidump_file_writer-inl.h" #include "common/scoped_ptr.h" -#if !defined(HAS_ARM_SUPPORT) && !defined(HAS_ARM64_SUPPORT) -#error "This file should only be compiled for ARM processors" -#endif - #if defined(HAS_ARM_SUPPORT) && defined(HAS_ARM64_SUPPORT) #error "This file should be compiled for only one architecture at a time" #endif @@ -83,7 +79,7 @@ bool IosExceptionMinidumpGenerator::WriteCrashingContext( #elif defined(HAS_ARM64_SUPPORT) return WriteCrashingContextARM64(register_location); #else -#error "This file should only be compiled on ARM processors" + assert(false); return false; #endif } @@ -134,6 +130,7 @@ uintptr_t IosExceptionMinidumpGenerator::GetLRFromException() { bool IosExceptionMinidumpGenerator::WriteExceptionStream( MDRawDirectory *exception_stream) { +#if defined(HAS_ARM_SUPPORT) || defined(HAS_ARM64_SUPPORT) TypedMDRVA exception(&writer_); if (!exception.Allocate()) @@ -154,10 +151,14 @@ bool IosExceptionMinidumpGenerator::WriteExceptionStream( exception_ptr->exception_record.exception_address = GetPCFromException(); return true; +#else + return MinidumpGenerator::WriteExceptionStream(exception_stream); +#endif } bool IosExceptionMinidumpGenerator::WriteThreadStream(mach_port_t thread_id, MDRawThread *thread) { +#if defined(HAS_ARM_SUPPORT) || defined(HAS_ARM64_SUPPORT) if (pthread_mach_thread_np(pthread_self()) != thread_id) return MinidumpGenerator::WriteThreadStream(thread_id, thread); @@ -196,6 +197,9 @@ bool IosExceptionMinidumpGenerator::WriteThreadStream(mach_port_t thread_id, thread->thread_id = thread_id; return true; +#else + return MinidumpGenerator::WriteThreadStream(thread_id, thread); +#endif } } // namespace google_breakpad -- cgit v1.2.1