Closed ShaliniShanmugam7 closed 5 years ago
First, try integrating an empty Unity project with Ionic. If it works, then try applying this solution to your original project (basically, we are trying to see if the issue is related to Mapbox): https://github.com/yasirkula/UnityIonicIntegration/issues/27
i created new unity project and tried to integrate in ionic project using the steps. Now i am facing semantic issues, parse issues in UnityAppController.h, DisplayManager.h files
Attached the screenshot. please help to fix this. I am using all latest package version node v8.11.3, cordova cli version is 6.5.0, ionic version 4.0.6, mapbox package version 1.4.4, unity 2018.2.3f1, xCode 9.4.1
Set the Base SDK to 11.4 - not cleared all issues
Set the Base SDK to 11.4 -cleared all the issues
Where did you set the Base SDK?
Under the Build Settings in xCode. But still the issues are there. only once it cleared. I downgraded the unity 2018 to unity 2017. Still am getting plenty of semantic issues. Please help.
If Prefix.pch inside the Unity group doesn't have #import <UIKit/UIKit.h>
and/or #import <Foundation/Foundation.h>
in-between #ifdef __OBJC__
and #endif
lines, try adding them.
Its already present in Prefix.pch. still not able to clear the issues
Try adding #import <UIKit/UIKit.h>
to UnityAppController.h manually.
Thanks @yasirkula . After fixing this i am getting similar semantic issues in UnityAppController+UnityInterface file
I fixed it by setting prefix header path in build settings[prefix header path was blank]. But i feel this is not a right fix? @yasirkula let me know your thoughts
Referred - https://github.com/yasirkula/UnityIonicIntegration/issues/12
This is the correct fix. I will add instructions for when the prefix header path is blank to the README: https://github.com/yasirkula/UnityIonicIntegration/issues/12#issuecomment-389437474
P.S. Done! https://github.com/yasirkula/UnityIonicIntegration/commit/83128ea436ae1f79ebce76d7d33568240b664ac4
All the semantic issues are gone. Now am handling library file clang error.
clang: error: no such file or directory: 'lMapboxMobileEventsStatic'
Probably Mapbox requires some additional directories in Unity group in Xcode. You can try opening the Unity project alone in Xcode and compare its project hierarchy with the Unity group in Ionic integrated Xcode project.
All looks same. but not able to clear this clang error
How about Header Search Paths and/or Library Search Paths in Build Settings? Are there any additional paths in Unity Xcode project?
checked and added the additional paths like mapbox. now got this below error Undefined symbols for architecture arm64: somewhere its missing the linking.
Solution to clear all the semantic issues - Add all required frameworks (i compared with unity ios project) under General - linked frameworks and libraries. Redo the integration ios steps. App is working.
add the key and value in Info.plist
Key : Privacy - Camera Usage Description
Value : $(PRODUCT_NAME) camera use
Key : Privacy - Location When In Use Usage Description Value : $(PRODUCT_NAME) location use
I am trying to integrate mapbox unity project with ionic ios project.I followed all the iOS steps and ended up with this lexical or preprocessor issue.
Unity version 2018.2.3f1 mapbox https://www.mapbox.com