Include WebRTC in iOS project - ios

I trying to deal with the AppRTCDemo projet but I am getting error.
Which library I forget to include ?
Log error :
Undefined symbols for architecture armv7s:
"_OBJC_CLASS_$_RTCVideoRenderer", referenced from:
objc-class-ref in VideoView.o
"_OBJC_CLASS_$_RTCSessionDescription", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_RTCICECandidate", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_RTCVideoCapturer", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_RTCPair", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_RTCMediaConstraints", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_RTCPeerConnectionFactory", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_RTCICEServer", referenced from:
objc-class-ref in APPRTCAppClient.o
ld: symbol(s) not found for architecture armv7s
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Thanks

The solution is to set the "Other Linker Flags" in the build setting of your project to $(inherited).
Then it will be an inherited link options from the workspace.

Maybe this library isn't built for armv7s processors.
Is it static lib built in .a file?
If so, you can run in console lipo -info command to see what architectures is this library built for.
For example, this command for some library somelib.a lipo -info somelib.a gives output:
Architectures in the fat file: somelib.a are: armv7 i386
If armv7s architecture isn't supported, but armv7 is, you can also run your project, try setting this in your build options:
"Build Active Architecture Only" YES --> NO.

You may be testing on iPhone 5 or above which is on armv7s architecture (see http://iossupportmatrix.com/ for more info).
The AppRTCDemo was built on armv7, that assume to run it on devices issued between the iPhone 3GS and the iPad mini (that includes iPhone 4 and 4s).
Regards,
S.

you have to run the app in ios device....not in simulator

Related

GoogleMaps for iOS Linker Error

While building the Application i am getting the following error i have searched a lot but i am unable to figure out what is the problem.
ld: warning: ignoring file /Users/username/GoogleMaps/GoogleMaps.framework/GoogleMaps, missing required architecture arm64 in file /Users/username/GoogleMaps/GoogleMaps.framework/GoogleMaps (2 slices)
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_GMSPolyline", referenced from:
objc-class-ref in GPSController.o
"_OBJC_CLASS_$_GMSCameraPosition", referenced from:
objc-class-ref in GPSController.o
"_OBJC_CLASS_$_GMSMutablePath", referenced from:
objc-class-ref in GPSController.o
"_OBJC_CLASS_$_GMSMarker", referenced from:
objc-class-ref in GPSController.o
"_OBJC_CLASS_$_GMSMapView", referenced from:
objc-class-ref in GPSController.o
"_OBJC_CLASS_$_GMSServices", referenced from:
objc-class-ref in AppDelegate.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I am using GoolgeMaps SDK 1.4.3
PS:- I am relatively new to iOS programming so please avoid any blunders.
Adding value $(inherited) to BuildSettings->Linking->Other Linker Flags of your target
If you are developing an SDK/framework/POD you should do the same as above but under target name PROJECTNAME_tests.
Should fix the issue.
I had this problem too, and my solution was to add the frameworks to
Target -> Build Phases -> Link Binary With Libraries
ok I figured out the Problem
My Library was not built for 64-bit but i was trying to use that settings for my app, after i removed arm64 from architecture i successfully build the application.

Apple Mach-O Linker Error with Parse OBJC classes

Hi I have looked over similar questions and tried everything but I can seem to fix my code. Every time I try and archive it I get
Apple Mach-O Linker Errors for Parse User, Object, File, Query, Parse
and a linker command failed with exit code 1.
First I get an ld:
warning: ignoring file .., missing required architecture arm 64 in
file Parse.framework.Parse
Then the following errors:
Undefined symbols for architecture arm64: "_OBJC_CLASS_$_PFUser",
referenced from:
objc-class-ref in SignupViewController.o
objc-class-ref in LoginViewController.o
objc-class-ref in InboxViewController.o
objc-class-ref in EditFriendsViewController.o
objc-class-ref in FriendsViewController.o
objc-class-ref in CameraViewController.o "_OBJC_CLASS_$_PFObject", referenced from:
objc-class-ref in CameraViewController.o "_OBJC_CLASS_$_PFFile", referenced from:
objc-class-ref in CameraViewController.o "_OBJC_CLASS_$_PFQuery", referenced from:
objc-class-ref in InboxViewController.o "_OBJC_CLASS_$_Parse", referenced from:
objc-class-ref in AppDelegate.o ld: symbol(s) not found for architecture arm64 clang: error: linker command failed with exit code
1 (use -v to see invocation)
Please can someone with experience of this issue help me as I've spent about 3 hours researching this already.
I know it's something to do with the Linked Frameworks but I don't get what?
Things I've tried:
Updating to the latest version of Parse Framework.
Including various other Frameworks that might have been missing.
Changed the Architectures in Build Setting to Standard Architectures (armv7, arm64)
Changed Build active Architecture only to No.
I just want this X-code project to build and archive with 64-bit support but there seems to be something fundamentally wrong with how I'm implementing Parse for 64-bit

Undefined symbols for architecture x86_64 in ios

I am getting this error when i run it on iPhone 5s simulator. It executes normally in lower versions of iPhone 5s. In my app i am using 3rd party lib CompuwareUEM. And also added all the files and lib file related to CompuwareUEM and it is compatible for 64bit.
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_CompuwareUEM", referenced from:
objc-class-ref in AppDelegate.o
objc-class-ref in SplashScreenViewController.o
objc-class-ref in CreateProfileViewController.o
objc-class-ref in MyTripsViewController.o
objc-class-ref in SettingsViewController.o
objc-class-ref in TrackingViewController.o
objc-class-ref in UserloginViewController.o
...
"_OBJC_CLASS_$_UEMAction", referenced from:
objc-class-ref in SplashScreenViewController.o
objc-class-ref in CreateProfileViewController.o
objc-class-ref in MyTripsViewController.o
objc-class-ref in SettingsViewController.o
objc-class-ref in TrackingViewController.o
objc-class-ref in UserloginViewController.o
objc-class-ref in PickTripViewController.o
...
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
can any one of you help me thanks in advance
Run lipo -info libCompuwareUEM.a and check if there is x86_64
Check this website, there is a detailed setup.
Try to clean your complete build directory and derived data
open Xcode -> Product Clean and alt + product clean.
The x86_64 architecture is used when you run a 64bit iPhone simulator! DONT mix it with arm64 which is the 64-bit Device architecture.
The error clearly indicates that the library doesn't contain x86_64.
[you could also check with lipo as said by las but the error is quiet clear]
issue resolved. The main problem is with the CompuwareUEM i totally remove that 3rd party library. Now it working fine.

cordova 3.4.1 iOS command line build ignores Valid Architectures?

I am attempting to update the Sphero PhoneGap plugin to work with the latest Cordova 3.4.1 and XCode 5.1.
The build works fine if I run it in XCode. In the Build Settings, I have specified "Valid Architectures" to just be armv7 and armv7s.
But if I do cordova build --device ios on the command line, then I get:
Running command: /Users/peteshau/dev/src/pearson/prototypes/robots-sphero/phonegap-test/platforms/ios/cordova/build --device
Build settings from command line:
ARCHS = armv7 armv7s arm64
CONFIGURATION_BUILD_DIR = /Users/peteshau/dev/src/pearson/prototypes/robots-sphero/phonegap-test/platforms/ios/build/device
SDKROOT = iphoneos7.1
VALID_ARCHS = armv7 armv7s arm64
...
ld: warning: ignoring file RobotsSphero/Plugins/com.orbotix.sphero.SpheroPlugin/RobotKit.framework/RobotKit, missing required architecture arm64 in file RobotsSphero/Plugins/com.orbotix.sphero.SpheroPlugin/RobotKit.framework/RobotKit (2 slices)
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_RKRobotProvider", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKRawMotorValuesCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKPingCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKStabilizationCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKRollCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKCalibrateCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKBackLEDOutputCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKGoToSleepCommand", referenced from:
objc-class-ref in spheroGap.o
"_OBJC_CLASS_$_RKRGBLEDOutputCommand", referenced from:
objc-class-ref in spheroGap.o
"_RKDeviceConnectionOnlineNotification", referenced from:
-[spheroGap setupRobot] in spheroGap.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
** BUILD FAILED **
(Same errors with cordova run --device and it fails to launch).
I'm trying to build it for my iPhone 5S which is running iOS 7.1.
From my limited understanding (I'm pretty unfamiliar with iOS development), it looks like the Valid Architectures restriction specified in the Build Settings are being ignored by cordova? Is there a way I can tell it to omit arm64 so I can get it to run?
(In case it's relevant, the native "RobotKit" frameworks appear to require the Deployment Target being set to 6.0 and various Linker flags to be set. From the command line output, it appears to be using the specified Linker flags OK).
This is a confirmed "deficiency" of Cordova:
https://issues.apache.org/jira/browse/CB-6716
I was able to get around it for now, by changing "Build Active Architecture Only" to "Yes".

Apple Mach-O Linker Error With Parse

I need some assistance. I added Parse SDK and it works fine during testing. When I attempt to build it, it gives me four 'Apple Mach-O Linker' errors:
ld: warning: ignoring file
/Users/Amirhosein/Downloads/ParsePlatform-PushTutorial-63133fb/iOS/Parse.framework/Parse,
missing required architecture arm64 in file
/Users/Amirhosein/Downloads/ParsePlatform-PushTutorial-63133fb/iOS/Parse.framework/Parse
(3 slices) Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_PFPush", referenced from:
objc-class-ref in AppDelegate.o "_OBJC_CLASS_$_PFInstallation", referenced from:
objc-class-ref in AppDelegate.o "_OBJC_CLASS_$_Parse", referenced from:
objc-class-ref in AppDelegate.o ld: symbol(s) not found for architecture arm64 clang: error: linker command failed with exit code
1 (use -v to see invocation)
It sounds as if your library is not built for 64-bit iOS but you're trying to use that setting for your app. Try removing arm64 from the architecture entry in your build settings.
Cleaning the code and then building again solve the problem for me!

Resources