phonegap-build / GAPlugin

Google Analytics Plugin
MIT License
169 stars 140 forks source link

iOS 7 support #25

Open amritk opened 11 years ago

amritk commented 11 years ago

Hi,

I'm pretty new to programming for iOS (just started last night) but I believe this is an issue caused by my build target being 7?

Plugins/com.adobe.plugins.GAPlugin/GoogleAnalytics.a(GAITransaction.o), too many compact unwind infos in function anon for architecture i386

I did some googling and people the answer is to upgrade the google analytics library. Is can anyone tell me how to do this? The files I got from google don't exactly match the ones in this plugins source.

Cheers

amritk commented 11 years ago

Here's a bigger trace:

CpResource Hockey\ Community/config.xml build/Hockey\ Community.app/config.xml cd /Users/amritk/apps/hockeycommunity/platforms/ios setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/amritk/.rvm/gems/ruby-1.8.7-p370/bin:/Users/amritk/.rvm/gems/ruby-1.8.7-p370@global/bin:/Users/amritk/.rvm/rubies/ruby-1.8.7-p370/bin:/Users/amritk/.rvm/bin:/Developer/android-sdk-macosx/platform-tools:/Developer/android-sdk-macosx/tools:/Developer/bin:/usr/local/mysql/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/local/include/sbin:/sbin:/opt/X11/bin" builtin-copy -exclude .DS_Store -exclude CVS -exclude .svn -exclude .git -exclude .hg -resolve-src-symlinks /Users/amritk/apps/hockeycommunity/platforms/ios/Hockey\ Community/config.xml /Users/amritk/apps/hockeycommunity/platforms/ios/build/Hockey\ Community.app

Ld build/Hockey\ Community.app/Hockey\ Community normal i386 cd /Users/amritk/apps/hockeycommunity/platforms/ios setenv IPHONEOS_DEPLOYMENT_TARGET 7.0 setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/amritk/.rvm/gems/ruby-1.8.7-p370/bin:/Users/amritk/.rvm/gems/ruby-1.8.7-p370@global/bin:/Users/amritk/.rvm/rubies/ruby-1.8.7-p370/bin:/Users/amritk/.rvm/bin:/Developer/android-sdk-macosx/platform-tools:/Developer/android-sdk-macosx/tools:/Developer/bin:/usr/local/mysql/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/local/include/sbin:/sbin:/opt/X11/bin" /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.0.sdk -L/Users/amritk/apps/hockeycommunity/platforms/ios/build -L/Users/amritk/apps/hockeycommunity/platforms/ios/Hockey\ Community/Plugins/PayPalMobile -L/Users/amritk/apps/hockeycommunity/platforms/ios/Hockey\ Community/Plugins/com.adobe.plugins.GAPlugin -F/Users/amritk/apps/hockeycommunity/platforms/ios/build -filelist /Users/amritk/apps/hockeycommunity/platforms/ios/build/Hockey\ Community.build/Debug-iphonesimulator/Hockey\ Community.build/Objects-normal/i386/Hockey\ Community.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -weak_framework CoreFoundation -weak_framework UIKit -weak_framework AVFoundation -weak_framework CoreMedia -weak-lSystem -force_load /Users/amritk/apps/hockeycommunity/platforms/ios/build/libCordova.a -lc++ -ObjC -ObjC -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=7.0 -weak_framework UIKit -framework Security -framework QuartzCore -framework OpenGLES -framework MobileCoreServices -framework MessageUI -lxml2 -framework CoreVideo -weak_framework CoreMedia -framework AudioToolbox -weak_framework AVFoundation -framework CoreLocation -framework ImageIO -framework OpenAL -framework AssetsLibrary /Users/amritk/apps/hockeycommunity/platforms/ios/build/libCordova.a -framework Foundation -framework CoreGraphics -framework AddressBook -framework AddressBookUI -framework CFNetwork -framework MediaPlayer -framework SystemConfiguration -lPayPalMobile -framework CoreLocation /Users/amritk/apps/hockeycommunity/platforms/ios/Hockey\ Community/Plugins/com.adobe.plugins.GAPlugin/GoogleAnalytics.a -framework CoreData -Xlinker -dependency_info -Xlinker /Users/amritk/apps/hockeycommunity/platforms/ios/build/Hockey\ Community.build/Debug-iphonesimulator/Hockey\ Community.build/Objects-normal/i386/Hockey\ Community_dependency_info.dat -o /Users/amritk/apps/hockeycommunity/platforms/ios/build/Hockey\ Community.app/Hockey\ Community ld: in /Users/amritk/apps/hockeycommunity/platforms/ios/Hockey Community/Plugins/com.adobe.plugins.GAPlugin/GoogleAnalytics.a(GAITransaction.o), too many compact unwind infos in function anon for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation)

\ BUILD FAILED **

The following build commands failed: Ld build/Hockey\ Community.app/Hockey\ Community normal i386 (1 failure)

And the related stack overflow: http://stackoverflow.com/questions/18731667/xcode-5-gm-linker-error-too-many-compact-unwind-infos-in-function-anon-for-arch

bobeast commented 11 years ago

This is a known issue with GoogleAnalytics library version 3.0.0. We are working towards a solution. In the meantime, you can set your deployment target to 6.x if you need to run it in the simulator. Alternatively, you can run it on a device to avoid the problem as well.

admbtlr commented 11 years ago

Looks like this has been fixed in 3.0.1 (https://code.google.com/p/analytics-issues/issues/detail?id=338).

Any chance of updating the plugin to use this version?

jdhiro commented 10 years ago

Isn't the plugin still on the 2.x SDK? I'm running into this issue now as well.

Beagle25 commented 10 years ago

I'm encountering this issue as well. Has anyone figured out a work around to get this plugin to work when targeting iOS 7?

teusink commented 10 years ago

Check out this fork for v3 support! https://github.com/khalidb91/GAPlugin

cemerson commented 10 years ago

+1

cemerson commented 10 years ago

@teusink does that fork from khalidb91 have arm64 support? My initial attempts trying it show that it may not (?). :(

teusink commented 10 years ago

@cemerson You might want to change the Analytics library for ARM support. Not sure if the plug-in needs updating to support it.

cemerson commented 10 years ago

Sadly way out of my league to attempt that. I (hilariously) tried swapping out the *.a file from the official Google GA iOS archive with the GAPlugin version but that did not work! Someone who actually knows what they're doing will have to handle this!