How to fix Undefined symbol error in Xcode? - ios

I am developing a React-Native application, which has both an Android and iOS version.
When working in Xcode, I have had several errors, which included duplicated files and Mach-O Linker errors.
Right now I'm struggling with the following error.
This is the complete log with the error.
I also append some screenshots of my configuration.

It's a bit hard to deduce the problem with the given info (I appreciate you have tried to give a lot info but even still the error is so vague, it can be caused by multitudes of things)
If I were you, I would do the following
Create a bran new react-native app (lets call it buildMyIosApp for example)
Build and run that
Observe it building for ios (building buildMyIosApp through xcode works)
Change the react and react-native versions on buildMyIosApp to be the same as your project
Re-build buildMyIosApp
Compare the project setup of buildMyIosApp to your project
Hopefully you would be able to find the issue that way.

Related

Multiple commands produce error in react native project build in xcode 12.4

I am trying to add react native vector icons into my react native CLI project and linking it manually with iOS. First, it was giving me some weird errors about "React/RCTDefine.h not found" but I managed to get it but now it is giving Multiple command produce error as you can see below
I tried multiple solutions from the stack overflow but nothing seems to work for me, I do not know if I am doing them correctly or not, If any expert can help me in this regard please, Thanks in advance

Undefined symbols for architecture x86_64: "_OBJC_CLASS_$_MobilePayManager"

I know there is a lot of similar errors out there, but i tried doing exactly what the answers said, and nothing helped.
I have now even created a completely new DemoProj (React-Native app), linked the repository the error is in, and i STILL get the same error.
The repository can be found here: https://github.com/Renetnielsen/DemoProj
If one fetches it and runs xcode, and runs that, you would get the same error.
I have no solution to this what so ever, especially since im no Objective C programmer.
Please please help me!!
The module react-native-appswitch is a small 2 function module, that just exports some IOS SDK functionality (https://developer.mobilepay.dk/appswitch-integration)
Complete Stacktrace: https://github.com/Renetnielsen/DemoProj/blob/master/README.md
Solutions tried
- Create completely new app, refered repo, installed, got error
- Ran on device, same error.
- Cleaned build folder, pods and so on - still error
- Linking binary files and so on
It needs to be fixed using 64 bit architecture, so using 32 is not an option, since ios does not support that any more as far as i know.

Module "CocoaLumberjackSwift" not found in latest wikipedia-ios app on XCode 9

I am using wikipedia-ios app for educational purposes, and I successfully used XCode 8 with it. But after the update I get the following error on trying to build the app:
Module "CocoaLumberjackSwift" not found
File: WMFLogging.h
I have used the scripts/setup from wiki's archive, and also I have cleaned the build (and all of the derived data). I even removed the project entirely and download it anew. Still I get the same error. Could someone please help me out with it?

Building ios corePlot with Xcode 5.0 using a Dependent project scenario

I am new to IOS and am writing an ios 7.0 app that uses coreplot (latest version 1.3). I had the "Build active architecture" set to YES - so during the development, I did not run into any linking problem (I used static linking method as described at https://code.google.com/p/core-plot/wiki/UsingCorePlotInApplications
Then I built and deployed on my device (iphone 4, ios 7). It worked fine - I dont remember if it asked to change build settings or not. Today morning, when I tried to run the same code on simulator it started giving me linker error. After doing some research, I realized I need to set the build for active architecture to No and rebuild the core plot using "dependent project install" strategy.
I am stuck at the point where I need to set the header files search path. The compilation fails to detect the header file. The coreplot is in a directory CorePlot_1.3.
The main linking error reads as
"ignoring file /Users/rmenon/Documents/Developer/MoneyTrail/MoneyTrail/libCorePlot-CocoaTouch.a, missing required architecture x86_64 in file /Users/rmenon/Documents/Developer/MoneyTrail/MoneyTrail/libCorePlot-CocoaTouch.a (3 slices)"
As part of my attempt to solve this, I tried to load the coreplot project separately, change the architecure to Stndard (armv7 nd armv7s) and tried to build it. I get two deprecation errors below. Any help in getting me compile this library for ios 7 so I can use the same setting in debug and device would be really appreciated! Thank you!
You'll need to update to a newer version of Core Plot. It has been updated to work with Xcode 5 and iOS 7, but we haven't done a release with those changes yet. You can pull the latest code with Mercurial or wait for the next release, which should be soon (within the next week or so).

Xcode Error - missing required architecture i386 in file

I'm trying to compile a demo project from Unity in Xcode (it's actually a tutorial on a new Augmented Reality platform that integrates with Unity called String) and getting this error:
ignoring file libiPhone-lib.a, missing required architecture i386 in file
I've researched this a little, and it seems to be some sort of issue with what version of iOS you're deploying too, but I'm not sure. Regardless, I've tried to deploy to different versions, and they all result in this error.
Any ideas how to fix this?
I did some research and it seems Unity for iPhone doesn't deploy on simulator. It only works on device or in the Unity editor. Check out this link. Hope it helps.

Resources