Onesignal Unity IOS Build Symbol not found error - ios

I am developed a game with Unity3D and exported IOS build. Xcode build project succesfully but App crash on launch.
Firstly I got this error:
dyld: Library not loaded: #rpath/OneSignalXC8.framework/OneSignalXC8 Referenced from: /var/containers/Bundle/Application/xxxx
Reason: image not found
After this, I added OneSignalXC8 framework to embeded binaries and error changed.
dyld: Symbol not found: __TMaCs29_NativeDictionaryStorageOwner
Referenced from: /private/var/containers/Bundle/Application/xxxx.app/Frameworks/OneSignalXC8.framework/OneSignalXC8
Expected in: /private/var/containers/Bundle/Application/xxxx.app/Frameworks/libswiftCore.dylib
in /private/var/containers/Bundle/Application/xxxx.app/Frameworks/OneSignalXC8.framework/OneSignalXC8
After this error, I set "Always Embed Swift Standard Libraries" to "Yes". Like saying here: https://stackoverflow.com/a/43117611/793880
But still I got same last error. How can I solve this?
I am using Xcode 8.3.3
I am using Unity 5.6.1f1
Unity exporting Xcode Project not workspace
I am using Objective-C
Thanks

I deleted OneSignal folder from Unity project.
Download last released plugin package from https://github.com/OneSignal/OneSignal-Unity-SDK
Import Unity project and build.
Runnning successfully

Related

iOS app is crashing after kill and relauch using Adobe xcframeworks

I have added adobe AEPCore.xcframework in my application and kept it as "Do not embed" in framework setting.
Screenshot:
When i kill and relaunch the application, It got crashed with following logs.
dyld: Library not loaded: #rpath/AEPAssurance.framework/AEPAssurance
Referenced from: /private/var/containers/Bundle/Application/6EF49835-678A-4B35-913B-5D88E3433DA3/app_name.app/app_name
Reason: image not found
dyld: launch, loading dependent libraries
Reason: image not found
dyld: launch, loading dependent libraries
dyld: launch, loading dependent libraries
DYLD_LIBRARY_PATH=/usr/lib/system/introspection
DYLD_INSERT_LIBRARIES=/Developer/usr/lib/libBacktraceRecording.dylib:/Developer/usr/lib/libMainThreadChecker.dylib:/Developer/Library/PrivateFrameworks/DTDDISupport.framework/libViewDebuggerSupport.dylib
When I changed the framework setting to "Embed and Sign" Then release build fails on Jenkins.
Error:
No UUID for /var/folders/zc/jp3qpb057hgf99tct24j3ch1xk6rfy/T/XcodeDistPipeline.~~~RRv4h3/libAEPMobileServices_iOS.a(AEPMobileServices.o)
Any Help will be appreciated. Happy Coding.
I have resolved this issue by keeping the framework setting as "Embed and Sign in" and kept AEPMobileServices framework as "Do not Embed" because this framework is a static library and It should not be included in the code.
This resolves the crash from QA build and export error from the release build.

dyld: Library not loaded: #rpath/libswiftCore.dylib - Ionic | Razorpay Cordova

I am trying to integrate Razorpay cordova plugin in my ionic app. It works find for Android. But for iOS I am getting below error when I run the app in Xcode. I am unable to proceed further. Please help me resolve the same. FYI, I have integrated as per the steps mentioned in the integration video and have added Razorpay framework in "Embedded Binaries" and have updated "Always Embed Swift Standard Libraries" to "Yes"
Error Msg:
dyld: Library not loaded: #rpath/libswiftCore.dylib
Referenced from: /Users//Library/Developer/CoreSimulator/Devices/B12116FD-C014-41B6-A5BF-6CEE7F079850/data/Containers/Bundle/Application/A76F064E-8CCA-4F93-A6CC-6E2C140CC231/The SICA.app/Frameworks/Razorpay.framework/Razorpay
Reason: image not found
IDE Specs
Xcode: 10.1
Swift version: 4.2.1
Razorpay Version: 1.4.8 (com.razorpay.cordova)
Screenshot - 1 - Build Settings
Screenshot - 2 - Build Settings
Update X-code version to the latest 11.3.1 and ensure that you have the framework added in Frameworks, Libraries, and
Embed Content under Target settings - General.
Change Embed value of Razorpay.framework under Frameworks, Libraries, and Embed Content from 'Do not Embed' -> 'Embed & Sign'.

iOS build issue With Xcode (10.2)

My Xcode Version is 10.2 and MacOS Version is 10.14.4.
I am new to iOS. I have a project in Unity, which I export and build in Xcode. If I build my project with Xcode-9.4 it works perfectly. But When I try to build my project with XCode-10.2 it gives me this error:
dyld: Library not loaded: #rpath/libswiftCore.dylib
Referenced from: /private/var/containers/Bundle/Application/FE30DBA8-091A-4350-9E8F-2CAF3FF03497/MyApp.app/Frameworks/libBluetooth.framework/libBluetooth
Reason: image not found
I have google it a lot but found nothing helpful any help is highly appreciated.
Below are the solutions I have already tried.
Always Embed Swift Standard Libraries => Yes (Not helpful)
"Clean" my project (shift+cmd+K) a
My Apple World Wide Certificate is already valid.
This fixed it for me :
Close Xcode
Open Keychain Access
Right click on your certificate -> Get Info
Under Trust -> Change When using this certificate value to Use System Default

Unity Xcode build AdBannerViewController.h file not found

I'm attempting to build some existing Unity 4.6 projects in Unity 5 and Xcode 6.1.1 Unity build is successful. However when building the file in Xcode 6.1.1 I am getting the error AdBannerViewController.h file not found. The error is occurring in
Unity-iPhone/Libraries/Scripts/Front/NativeUIBinding.m. It is being imported and referenced in that file.
These appear to be unity developed files with no relevance to the app. Any idea why this header file would be missing? I searched the project but cannot find it and its a very simple two scene app that doesn't use ads.

Xcode 6 Error - "Missing Required Architecture i386" When Building for iOS Simulator

I have created a custom Objective-C framework. I would like to import it into any given iOS project and use its provided functionality on both the iOS Simulator and an actual device. To import the framework, I link it using the Build Phases > Link Binary With Libraries setting in the app's target. I'm then able to import it into one of my classes with this statement:
#import <CustomFramework/CustomFramework.h>
I can instantiate my framework's classes just fine, but when I try to run my project on a device, I get the following error message:
dyld: Library not loaded: #rpath/CustomFramework.framework/CustomFramework
Referenced from: /var/mobile/Applications/A61E882D-481A-4C0B-B4FD-69F5D24968BF/TestApp.app/TestApp
Reason: image not found
And if I try to run it on the simulator, I get a different error message:
ld: warning: ignoring file /Users/user/Desktop/CustomFramework.framework/CustomFramework, missing required architecture i386 in file /Users/user/Desktop/CustomFramework.framework/CustomFramework (2 slices)
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_CustomFramework", referenced from:
objc-class-ref in AppDelegate.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
This occurs when I instantiate a class from the framework. If I import the framework but don't actually use it, my app builds successfully. It just errors whenever I instantiate a class from the framework for some reason.
To get the app to build on a device, I followed this SO answer. Instead of linking the framework, I added a new Copy Files phase in the target's Build Phases setting, set the Destination to Framework, and added my framework.
That works great; however, I'd like to test my app on the iOS Simulator as well. When I try to run my app on the simulator, I still get the "missing required architecture i386" error. I've tried the solutions proposed at just about every related SO topic I could find, and nothing has helped me resolve this issue.
Please note that I am trying to use my custom framework in a new Xcode project, so none of the app/build settings have been changed from their defaults.
How can I fix this error so that I can run my app on both the iOS Simulator and a device with my framework included in the project? Any insight would be greatly appreciated!
The issue was that the framework was not compiled for the iOS Simulator's architecture, which is i386. Xcode only compiles a framework for the target architecture, so if I built the framework for the iOS Simulator, it wouldn't work on a device, and if I built the framework for a device, it wouldn't work on the iOS Simulator.
I created my framework from scratch with help from this tutorial: http://www.raywenderlich.com/65964/create-a-framework-for-ios
The multi-architecture build script is what allowed my framework to run on both the iOS Simulator and a device.
I encountered this same problem with Xcode 7.1 when trying to build for the simulator.
Someone else said it worked for them under Xcode 8.2.1, so I tried building/running there and it worked. I didn't have to change targets or anything in my project.
So try upgrading your Xcode if you can, you will presumably get additional bug fixes as well.

Resources