- Home /
iOS LocationManager Framework not included
I make a bluetooth asset. I am now including support for iBeacon which requires the use of LocationManager on iOS.
I just built my application in 2018.2.13f and when I try to build in xcode I get a linker error that the CLLocationManager objects are missing when linking.
I click on my .mm file in the plugin folder and check the frameworks and CoreLocation is checked. In fact you can't uncheck it.
I also have included the Location Services description on the project settings for iOS.
This exactly same project builds fine when I build with Unity 5.6 and 2017 and 2018.1.6.
It does not work in 2018.2.9 or 2018.2.13.
If I manually add the CoreLocation framework to the xcode project after building from Unity then it builds fine.
Why is Unity 2018 not including the CoreLocation framework when it says it should in settings?
This seems like a pretty important problem. Does anyone have any kind of information about it? Does this happen for anyone else?
I have the same situation.
xCode project from Unity2018.2.5f1 is buildable, but from Unity 2018.3.5f1 not.
After some investigation of xCode project, it looks like CoreLocation is missing in some xml blocks.
I reported this problem under issue number 1131399.
As temporary workaround, I disabled test on already existing file in xCode project in XuPorter XCProject.cs file..
//Check if there is already a file
PBXFileReference fileReference = GetFile( System.IO.Path.GetFileName( filePath ) );
if( fileReference != null ) {
Debug.Log("File already exists: " + filePath); //not a warning, because this is normal for most builds!
//HAC$$anonymous$$ for Unity issue with CoreLocation framework - 1131399
if (filePath != "System/Library/Frameworks/CoreLocation.framework")
return null;
}
Answer by Hotshot10101 · Feb 26, 2019 at 02:22 PM
This was fixed in a later 2018.2 version.
I am not sure why you are now having it happen in 2018.3.5.
I just did a brand new project in 2018.3.6. I imported the latest version of the plugin and built the SimpleTest scene.
I built to iOS and opened in xCode and it built fine there. I don't know if maybe there was an error in 2018.3.5 or not, but .6 seems to work.
Your answer
