Marxon13/M13Checkbox

Segmentation fault: 11 on Xcode 9.3

suhitp opened this issue · 2 comments

I am getting segmentation fault when using my app with the latest Xcode 9.3 but the same code runs when using in Xcode 9.2. Below is the the error logs

0 swift 0x0000000111a66ffa PrintStackTraceSignalHandler(void*) + 42 1 swift 0x0000000111a663b6 SignalHandler(int) + 966 2 libsystem_platform.dylib 0x00007fff70597f5a _sigtramp + 26 3 libsystem_platform.dylib 0x00007fc35db90b08 _sigtramp + 3982461896 4 swift 0x0000000110037fc2 llvm::InstrProfiling::getOrCreateRegionCounters(llvm::InstrProfIncrementInst*) + 2642 5 swift 0x0000000110033278 llvm::InstrProfiling::run(llvm::Module&, llvm::TargetLibraryInfo const&) + 2648 6 swift 0x0000000111997dd8 llvm::legacy::PassManager::run(llvm::Module&) + 1112 7 swift 0x000000010e266e9a swift::performLLVM(swift::IRGenOptions&, swift::DiagnosticEngine*, llvm::sys::SmartMutex<false>*, llvm::GlobalVariable*, llvm::Module*, llvm::TargetMachine*, swift::version::Version const&, llvm::StringRef, swift::UnifiedStatsReporter*) + 6250 8 swift 0x000000010e26af1c ThreadEntryPoint(swift::irgen::IRGenerator*, llvm::sys::SmartMutex<false>*, int) + 220 9 swift 0x000000010e26af6f void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (*)(swift::irgen::IRGenerator*, llvm::sys::SmartMutex<false>*, int), swift::irgen::IRGenerator*, llvm::sys::SmartMutex<false>*, int> >(void*) + 47 10 libsystem_pthread.dylib 0x00007fff705a1661 _pthread_body + 340 11 libsystem_pthread.dylib 0x00007fff705a150d _pthread_body + 0 12 libsystem_pthread.dylib 0x00007fff705a0bf9 thread_start + 13 Stack dump: 0. Running pass 'Frontend instrumentation-based coverage lowering' on module '/Users/suhitpatil/Library/Developer/Xcode/DerivedData/UpGrad-dvslouwdtfhwmiaokpmmejttcrvc/Build/Intermediates.noindex/Pods.build/StagingDebug-iphoneos/M13Checkbox.build/Objects-normal/arm64/M13CheckboxStrokeController.o'. error: Segmentation fault: 11

I am using the latest pod version
pod 'M13Checkbox', '3.2.2'

I have commented the code and compiled the app but the error still there. Seems like the issue is in M13CheckboxStrokeController class as per the logs

Please help to resolve this issue.

I have the same issue. It seems this error is thrown when we are using a custom build configuration (not Debug or Release). From your logs I suppose your custom build configuration is called StagingDebug.

I'm using CocoaPods 1.5.0 and it seems M13Checkbox does not support well custom build configurations. I don't know if it is a bug on Cocoapods or M13Checkbox.

In my case I fixed this issue by specifying in Podfile that the new custom build configuration is associated to debug configuration.

Please try to add this line in your Podfile (at the beginning after line saying use_frameworks!:

project '<your project name>', 'StagingDebug' => :debug

Then run pod install. It will copy all settings from debug configuration to your custom build configuration inside your pods projects.

Maybe these links can help you to implement this workaround to fix temporarily this issue.

http://www.mokacoding.com/blog/cocoapods-and-custom-build-configurations/
https://guides.cocoapods.org/syntax/podfile.html#project

Please let me know if it works for you or if you've found another solution and more information about the cause of this issue.

@MarcoFilosi Thanks. It worked.