I'm creating a project with Core-Plot lib.
I add the lib with static way.
How can I run my app in 32 + 64 bit devices?
if I run lipo libCorePlot-CocoaTouch.a -info
console response:
Architectures in the fat file: libCorePlot-CocoaTouch.a are: armv7 armv7s arm64
But this library works only with 32bit devices/simulator with 64bit simulator give me this error:
ld: warning: ignoring file PATH/libCorePlot-CocoaTouch.a, missing required architecture i386 in file PATH/libCorePlot-CocoaTouch.a (3 slices)
Undefined symbols for architecture i386:
"_CPTDecimalFromCGFloat", referenced from:
-[HomeViewController configureSecondPlots] in HomeViewController.o
-[HomeViewController configureSecondAxes] in HomeViewController.o
"_CPTDecimalFromInteger", referenced from:
-[HomeViewController configureSecondAxes] in HomeViewController.o
"_OBJC_CLASS_$_CPTAxisLabel", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTColor", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTFill", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTGraphHostingView", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTMutableLineStyle", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTMutableTextStyle", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTPieChart", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTPlotSymbol", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTScatterPlot", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTTextLayer", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_CPTXYGraph", referenced from:
objc-class-ref in HomeViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
How can I fix this problem?
Thank you
Combine both libraries and make a universal binary
lipo -create <simulator_lib>.a <device_lib>.a -output lib.a
Open the Core Plot iOS project (CorePlot-CocoaTouch.xcodeproj), update the architecture build settings to include 64-bit, and build the "Universal Library" target. This will create a folder called "Release-universal" in your build folder containing a universal library with all architectures (device and simulator) and copies of all of the header files.
Related
We have an iOS application that is referencing the AWS Mobile frameworks directly and several other libraries using CocoaPods. The project builds fine
But, when we add the 'Quickblox-SDK' as an additional library to reference in the PodFile and run pod install I get several build/linker errors:
Undefined symbols for architecture x86_64:
"_AWSSNSErrorDomain", referenced from:
___88-[AWSPushManager interceptApplication:didRegisterForRemoteNotificationsWithDeviceToken:]_block_invoke.239 in AWSMobileHubHelper(AWSPushManager.o)
"_OBJC_CLASS_$_AWSSNS", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSPushManager.o)
"_OBJC_CLASS_$_AWSSNSCreatePlatformEndpointInput", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSPushManager.o)
"_OBJC_CLASS_$_AWSSNSGetEndpointAttributesInput", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSPushManager.o)
"_OBJC_CLASS_$_AWSSNSSetEndpointAttributesInput", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSPushManager.o)
"_OBJC_CLASS_$_AWSSNSSubscribeInput", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSPushManager.o)
"_OBJC_CLASS_$_AWSSNSUnsubscribeInput", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSPushManager.o)
"_OBJC_CLASS_$_FBSDKAccessToken", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSFacebookSignInProvider.o)
"_OBJC_CLASS_$_FBSDKApplicationDelegate", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSFacebookSignInProvider.o)
"_OBJC_CLASS_$_FBSDKGraphRequest", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSFacebookSignInProvider.o)
"_OBJC_CLASS_$_FBSDKLoginManager", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSFacebookSignInProvider.o)
"_OBJC_CLASS_$_GIDSignIn", referenced from:
objc-class-ref in AWSMobileHubHelper(AWSGoogleSignInProvider.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
If we remove the $(inherited) flag from the Other Linker Flags build setting, getting below errors:-
bash: /User/..../AWSCore.framework/strip-frameworks.sh: No such file or directory
uploadDSYM[13005:219405] Fabric.framework/run 1.4.1 (160)
uploadDSYM[13005:219405] Launched uploader in validation mode
bash: /Users/..../Frameworks/Quickblox.framework/strip-framework.sh: No such file or directory
Any Help will be appreciated..
Thanks,
in your Pods-{PROJECT_NAME}.debug.xcconfig and Pods-{PROJECT_NAME}.release.xcconfig file, find this line
OTHER_LDFLAGS = $(inherited) -ObjC -l"z" ....
and remove the -ObjC
Alternatively, you can also fix this from XCode by going to Build Settings -> Other Linker Flags, and remove -ObjC from there
MobileAppTracker ios SDK
Undefined symbols for architecture armv7:
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_SKPaymentQueue", referenced from:
objc-class-ref in MobileAppTracker(MATStoreKitDelegate.o)
"_OBJC_CLASS_$_SKProductsRequest", referenced from:
objc-class-ref in MobileAppTracker(MATStoreKitDelegate.o)
"_OBJC_CLASS_$_CTTelephonyNetworkInfo", referenced from:
objc-class-ref in MobileAppTracker(MATSettings.o)
"_ADBannerContentSizeIdentifierLandscape", referenced from:
l018 in MobileAppTracker(MATTracker.o)
"_OBJC_CLASS_$_ADBannerView", referenced from:
objc-class-ref in MobileAppTracker(MATTracker.o)
"_OBJC_CLASS_$_ADClient", referenced from:
objc-class-ref in MobileAppTracker(MATTracker.o)
"_ADBannerContentSizeIdentifierPortrait", referenced from:
l018 in MobileAppTracker(MATTracker.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Try this. Go to,
Your Project->Build Phases->Link Binary With Libraries
press + button and add iAd.framework , Security.framework and StoreKit.framework. Clean and Build your project.
I am facing the following issue while building the application with core plot library.
It was working before 2 days. But it suddenly stopped running.
libCorePlot-CocoaTouch.a (2 slices)
Undefined symbols for architecture x86_64:
"_CPTDecimalFromFloat", referenced from:
-[GraphView generateLayout] in GraphView.o
"_CPTDecimalFromInt", referenced from:
-[GraphView generateLayout] in GraphView.o
"_OBJC_CLASS_$_CPTAxisLabel", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTBarPlot", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTColor", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTConstraints", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTFill", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTGraphHostingView", referenced from:
_OBJC_CLASS_$_GraphView in GraphView.o
"_OBJC_CLASS_$_CPTMutableLineStyle", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTMutableTextStyle", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTPlotRange", referenced from:
objc-class-ref in GraphView.o
"_OBJC_CLASS_$_CPTXYGraph", referenced from:
objc-class-ref in GraphView.o
"_OBJC_METACLASS_$_CPTGraphHostingView", referenced from:
_OBJC_METACLASS_$_GraphView in GraphView.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Add new core plot library framework to your project. Remove the old library. These are the steps to follow
Download the core plot library.
open the xcode CorePlot-CocoaTouch.xcodeproj
Go to project and click on build
Now go to core plot framework folder in your mac. You can see build folder in that.
Now open the terminal and give your core plot path
cd CorePlot_1.4/Source/build/
Type lipo -create ./Debug-iphoneos/libCorePlot-CocoaTouch.a ./Debug-iphonesimulator/libCorePlot-CocoaTouch.a -output core_plot_all.a
New library created and now add this library and core headers to your project.
Now build your project.
After that add -ObjC to other linker flags
I am trying to archive my First iOS Project and I get the following errors. It seems like there is something bugged with the Facebook SDK and Google Plus SDK which i have used for Authentication. I have come across similar questions on stackoverflow but none's solutions helped me. Any help would be appreciated. Thanks in advance.
<pre>
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_FBRequest", referenced from:
objc-class-ref in LoginViewController.o
"_OBJC_CLASS_$_GTMLogger", referenced from:
objc-class-ref in LoginViewController.o
"_OBJC_CLASS_$_GTLQueryPlus", referenced from:
objc-class-ref in LoginViewController.o
"_kGTLAuthScopePlusLogin", referenced from:
-[LoginViewController getInfoForGoogle] in LoginViewController.o
"_OBJC_CLASS_$_GTLServicePlus", referenced from:
objc-class-ref in LoginViewController.o
"_OBJC_CLASS_$_GPPURLHandler", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_GPPSignIn", referenced from:
objc-class-ref in LoginViewController.o
"_OBJC_CLASS_$_FBSession", referenced from:
objc-class-ref in AppDelegate.o
objc-class-ref in LoginViewController.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
</pre>
The framework you are using is not arm64 ready, ie not for 64bit devices, you can either check if an updated framework is available, or exclude arm64 that from your build
Set the architecture in build settings to Standard architectures(armv7,armv7s)
Xcode 5 and iOS 7: Architecture and Valid architectures
I'm using Cocoapod to get Global Lib. It works fine in the simulator, but it has some error when I build on my device:
Undefined symbols for architecture armv7s:
"_OBJC_CLASS_$_FBRequest", referenced from:
objc-class-ref in HomeViewController.o
"_OBJC_CLASS_$_SBJsonParser", referenced from:
objc-class-ref in IQRequest.o
"_AFNetworkingOperationFailingURLResponseErrorKey", referenced from:
___78-[IQRequest performQueueOperationWithRequest:withSuccessBlock:andFailedBlock:]_block_invoke39 in IQRequest.o
"_OBJC_CLASS_$_AFHTTPRequestOperation", referenced from:
objc-class-ref in IQRequest.o
"_OBJC_CLASS_$_AFHTTPClient", referenced from:
objc-class-ref in IQRequest.o
"_OBJC_CLASS_$_FBSession", referenced from:
objc-class-ref in ChooseDesignerViewController.o
objc-class-ref in IQUser.o
objc-class-ref in IQAppDelegate.o
ld: symbol(s) not found for architecture armv7s
clang: error: linker command failed with exit code 1 (use -v to see invocation)
What has happened to my project?
It seems like your library isn't compiled for armv7s. If it's distributed as binary you'll have to ask the maintainer to rebuild it with an armv7s slice. If it's distributed as source code you have to check the projects build settings. I think you should look for valid architectures or something like that.