PLCrashReporter is a reliable open source library that provides an in-process live crash reporting framework for use on iOS, macOS and tvOS. The library detects crashes and generates reports to help your investigation and troubleshooting with the information of application, system, process, thread, etc. as well as stack traces.
- Uses only supported and public APIs/ABIs for crash reporting.
- The most accurate stack unwinding available, using DWARF and Apple Compact Unwind frame data.
- First released in 2008, and used in hundreds of thousands of apps. PLCrashReporter has seen a tremendous amount of user testing.
- Does not interfere with debugging in lldb/gdb
- Easy to integrate with existing or custom crash reporting services.
- Backtraces for all active threads are provided.
- Provides full register state for the crashed thread.
- Xcode 11 or above.
- Minimum supported platforms: iOS 9, macOS 10.9, tvOS 9, Mac Catalyst 13.0.
Decoding Crash Reports
Crash reports are output as protobuf-encoded messages, and may be decoded using the CrashReporter library or any Google Protocol Buffers decoder.
In addition to the in-library decoding support, you may use the included
plcrashutil binary to convert crash reports to apple's standard iPhone text format. This may be passed to the symbolicate tool.
plcrashutil convert --format=iphone example_report.plcrash | symbolicatecrash
Future library releases may include built-in re-usable formatters, for outputting alternative formats directly from the phone.
- A Mac running macOS compliant with Xcode requirements.
- Xcode 11 or above.
Also, next optional tools are used to build additional resources:
- Doxygen to generate the documentation. See the official Doxygen repository for more information or use Homebrew to install it.
- GraphViz to generate the documentation. See the official GraphViz website for more information or use Homebrew to install it.
protobuf-cto convert Protocol Buffer
.protofiles to C descriptor code. See the official protobuf-c repository for more information or use Homebrew to install it.
Open a new window for your Terminal.
Go to PLCrashReporter's root folder and run
xcodebuild -configuration Release -target 'CrashReporter'
to create binaries for all platforms.
We are looking forward to your contributions via pull requests.
To contribute to PLCrashReporter, you need the tools mentioned above to build PLCrashReporter for all architectures and
protobuf-c to convert Protocol Buffer
.proto files to C descriptor code.
Code of Conduct
You may find interesting
1.8.1 - 2020-11-09T07:59:31
1.8.0 - 2020-11-03T14:07:10
- Drop support of old versions of iOS and macOS. The minimal version is iOS 9 and macOS 10.9 now.
- Add Apple Silicon support. Note that
arm64for iOS and tvOS simulators is available only in xcframework or SwiftPM.
- Support saving custom data in crash report, see
- Fix exported symbols list for applying
- Fix Xcode 12 compatibility if the framework is used from sources.
- Fix getting the subtype of device architecture on iOS 14.
- Fix crash on collecting register values on
arm64edevices with iOS 14.
1.7.2 - 2020-08-19T11:07:26
- Fix building on Xcode 12 beta.
- Use memory mapping to reduce live reports memory pressure.
- Remove "CrashReporter Key: TODO" from text report output.
[PLCrashReporter]prefix for all log messages.
1.7.1 - 2020-06-30T15:26:44
- Fix crash on old operating systems: macOS 10.11, iOS 9 and tvOS 9 (and older).
- Fix duplicate symbols in applications with
- Fix exporting PLCrashReporter along with an application into
- Fix collecting stacktraces on
arm64edevices in some cases.
1.7.0 - 2020-06-17T15:44:06
- Drop support old versions of Xcode. The minimal version is Xcode 11 now.
- Support Mac Catalyst.
.xcframeworkarchive alongside with the other options.
- Improve reliability of saving crash reports in case of memory corruption.
- Fix symbolication issues with new Objective-C runtime version.
- Add workaround for SwiftPM on Xcode 11.1 bug (
SWIFT_PACKAGEis not defined) that prevents library usage on macOS.
1.6.0 - 2020-05-20T12:11:26
- Support integration via Carthage.
- Support integration via Swift Package Manager. Please note that this way has some limitations:
- macOS 64-bit mach_* APIs is not available here.
protobuf-csymbols are not prefixed, so it can cause conflicts with other libraries.
- Additional architectures like
arm64eare not built explicitly.
- Migrate to Automatic Reference Counting (ARC).
- Embed required
protoc-csources instead of using submodule. No more additional steps on cloning the repo.
- Store sources generated from
*.protofiles to drop
protobuf-ccompiler requirement for building the library. It's required only for contributors now.
- Enable generating debug symbols for static libraries. Previously it was included only to macOS framework.
- Fix framework targets type issue that prevents use the library as a project dependency (instead of binary distribution) in Xcode 11.
- Fix implicit casting warnings.
1.5.1 - 2020-03-18T14:09:20
- Fix support for Xcode 10.
1.5.0 - 2020-03-17T11:40:18
- Drop support old versions of Xcode and iOS. The minimal versions are Xcode 10 and iOS 8 now.
UIKitdependency on iOS.
- Fix arm64e crash report text formatting.
- Fix possible crash
NSExceptioninstances have a
- Apply bit mask for non-pointer isa values on macOS x64 (used in runtime symbolication).
- Strip pointer authentication codes on arm64e.
1.4.0 - 2019-12-05T18:01:05
- Support macOS 10.15 and XCode 11 and drop support for macOS 10.6.
- Add support for tvOS apps.
protobuf-cto version 1.3.2.
protoc-ccode generator binary has been removed from the repo, so it should be installed separately now (
brew install protobuf-c).
protoc-cC library is included as a git submodule, please make sure that it's initialized after update (
git submodule update --init).
- Remove outdated "Google Toolbox for Mac" dependency.
- The sources aren't distributed in the release archive anymore. Please use GitHub snapshot instead.
- Distribute static libraries in a second archive aside the frameworks archive.
- Fix minor bugs in runtime symbolication: use correct bit-mask for the data pointer and correctly reset error code if no categories for currently symbolicating class.
- Add preview support for the arm64e CPU architecture.
- Support for arm64e devices that run an arm64 slice (which is the default for apps that were compiled with Xcode 10 or earlier).
- Remove support for armv6 CPU architecture as it is no longer supported.
- Improve namespacing to avoid symbol collisions when integrating PLCrashReporter.
- Fix a crash that occurred on macOS where PLCrashReporter would be caught in an endless loop handling signals.
- Make it possible to not add an uncaught exception handler via
PLCrashReporterConfig. This scenario is important when using PLCrashReporter inside managed runtimes, i.e. for a Xamarin app. This is not a breaking change and behavior will not change if you use PLCrashReporter.