0

Im experiencing something strange while updating my app in the Appstore. Version 1.4 worked fine for every device. However Version 2.0 crashes on some devices when updated. The loading screen wouldnt even show when starting up and the app would crash within a second. Removing and reinstalling the application from the app store solves this problem. Again this only happens on some devices (iPod, iPhone 4, iPhone 4s, iPad so far). I manages to get my hands on a crashing device and check the Device logs. Also I think I found something but I cant really understand the error. It says:

Dyld Error Message:
  Library not loaded: /System/Library/Frameworks/AdSupport.framework/AdSupport
  Referenced from: /var/mobile/Applications/(ID)/AppName.app/AppName
Reason: image not found
  Dyld Version: 199.6

I added AdSupport.framework because I implemented Facebook in my App in version 2.0 and the file is in my project in the folder 'Frameworks'. Does somebody know how to fix this?

Here is the full crash Report if useful.

Incident Identifier: ID
CrashReporter Key:   crash key
Hardware Model:      iPod4,1
Process:         AppName [35491]
Path:            /var/mobile/Applications/id/AppName.app/AppName
Identifier:      AppName
Version:         ??? (???)
Code Type:       ARM (Native)
Parent Process:  launchd [1]

Date/Time:       2013-03-05 23:23:35.041 +0100
OS Version:      iPhone OS 5.1.1 (9B206)
Report Version:  104

Exception Type:  EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x00000001, 0xe7ffdefe
Crashed Thread:  0

Dyld Error Message:
  Library not loaded: /System/Library/Frameworks/AdSupport.framework/AdSupport
  Referenced from: /var/mobile/Applications/(id)/AppName.app/AppName
  Reason: image not found
  Dyld Version: 199.6

Binary Images:
   0x7a000 -   0x106fff +AppName armv7  <0c108dce50ee3e65970e2538a3e319f8> /var/mobile/Applications/(id)/AppName.app/AppName
0x2fe79000 - 0x2fe9afff  dyld armv7  <77eddfd654df393ba9c95ff01715fd08> /usr/lib/dyld
0x3075a000 - 0x307d9fff  libsqlite3.dylib armv7  <bf01f5ed47b033d8bde30d735ff44416> /usr/lib/libsqlite3.dylib
0x3113c000 - 0x311a0fff  MessageUI armv7  <da7af4f9494b35558bf7892dfdb36ee3> /System/Library/Frameworks/MessageUI.framework/MessageUI

This iPod has iOS 5.1 but I also received report on iOS 6.1

Mark Molina
  • 5,057
  • 8
  • 41
  • 69
  • what is the difference between 1.4 and 2.0 , especially on Frameworks used ? – Raptor Mar 06 '13 at 08:58
  • Added a lot more frameworks 1.4: SystemConfiguration, CoreLocation, MapKit, QuartzCore, UIKit, Foundation, CoreGraphics, CoreData 2.0: MessagesUI, FacebookSDKResources.bundle, FacebookSDK, Social, Accounts, SystemConfiguration, CoreLocation, Mapkit, QuartzCore, UIKit, Foundation, CoreGraphics, CoreData – Mark Molina Mar 06 '13 at 09:01
  • Also added Flurry Analytics, Facebook Implementation, Email within App, – Mark Molina Mar 06 '13 at 09:03
  • possible duplicate of [dyld: Library not loaded different behavior for 6.0 simulator/6.0 device](http://stackoverflow.com/questions/12594070/dyld-library-not-loaded-different-behavior-for-6-0-simulator-6-0-device) – trojanfoe Mar 06 '13 at 09:04
  • http://stackoverflow.com/questions/12915050/still-dyld-library-not-loaded – trojanfoe Mar 06 '13 at 09:04
  • http://stackoverflow.com/questions/12610078/facebook-sdk-3-1-for-ios-runs-on-ios6-but-crashes-on-ios-5-x – trojanfoe Mar 06 '13 at 09:04
  • ill try that now. Keep you guys posted on the result – Mark Molina Mar 06 '13 at 09:07

1 Answers1

0

Because AdSupport.framework, is ONLY available on iOS 6. So Dyld cannot find something who doesn't exist on past IOS. Even if you are adding framework into your project, you don't actually include the binary, only the reference.

If it's not crashing when you are reinstalling your app, it's because maybe it doesn't use the adSupport functionality at that time. But i'm not sure of this theory because i haven't made your code ;)

Here the apple available framework link, hope it will help you http://developer.apple.com/library/ios/#documentation/miscellaneous/conceptual/iphoneostechoverview/iPhoneOSFrameworks/iPhoneOSFrameworks.html

Mr Bonjour
  • 3,330
  • 2
  • 23
  • 46
  • Thanks... I was pulling my hair out was you were typing that answer. Im checking all my frameworks now and will resubmit my app – Mark Molina Mar 06 '13 at 09:17
  • I also have the FacebookSDK.framework in my linked frameworks and Libraries. Cant find that framework in your list. Does this need to be set to required or optional? – Mark Molina Mar 06 '13 at 09:23
  • 1
    it seems that facebookSDK, is already given as static library for ios. That means that it will be compiled with you app binary. So that ok as long as you respect what FacebookSDK require. You should read their documentation to be sure. – Mr Bonjour Mar 06 '13 at 09:28