Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode7: libGGLAnalytics.a(GGLContext+Analytics.o)' does not contain bitcode

Using Xcode7. When I run my app on the simulator I get no errors. When I try to run on a real device I get this:

ld: 'Test-IOS/Pods/Google/Libraries/libGGLAnalytics.a(GGLContext+Analytics.o)' does not contain bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE), obtain an updated library from the vendor, or disable bitcode for this target. for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation) 

How do I resolve this error?

like image 946
confile Avatar asked Sep 21 '15 00:09

confile


People also ask

What is Bitcode Xcode?

Replies. Bitcode is an intermediate representation of a compiled program. Meaning you can slice/segment it out for different processors, etc. once it's in the store, reducing the payload do the user accordingly.


1 Answers

The issue is that Google Analytics for iOS doesn't have support for bitcode right now. Here's the issue on Google Code:

https://code.google.com/p/analytics-issues/issues/detail?id=671

The workaround currently is to disable bitcode for your project. In your project file in the Build Settings tab under Build Options set the Enable Bitcode flag to false.

Bitcode Flag

Note that if you disable it completely you won't be able to build for watchOS. There seems to be a way to also only disable it for iOS but then you won't be able to use analytics on watchOS.

like image 183
Florian Gutmann Avatar answered Oct 13 '22 15:10

Florian Gutmann