When Xcode 7 was officially released on Sept 16, feedback from developers started flowing in that they were seeing a ton of warnings building their apps with LocationKit, our advanced location manager framework for iOS (and Android too, but of course that was unaffected here!).
We started scouring the web for similar issues and were unable to find much information about the issue as apparently it was brand new. So, after a lot of blood, sweat, and tears, our team finally solved it.
As with most annoying problems, the solution seems very simple and obvious in retrospect, but it took us awhile to arrive at. So I’m writing this in the hopes that it’ll help other developers compiling static libraries for iOS on Xcode 7.
When developers were using our LocationKit static library in their apps built on Xcode 7, they were seeing a ton (hundreds!) of warnings that looked like the following (it scrolls far to the right!):
We noticed they were present and included a lot of the core iOS libraries on which we were dependent, so in our case we saw errors including Foundation, CoreLocation, CoreMotion, and MapKit among others.
This was the same build of our static library which worked without any problems or warnings when added to an app built with Xcode 6, now blowing up in an app built with Xcode 7.
One notable problem with these warnings — the warnings included /Users/victor/ which would make sense on my laptop (since my name is victor and my user is victor so the path /Users/victor/ made sense for me), but it sure didn’t make sense for anyone else to be seeing those warnings with a path on my machine appearing when building their app! And that’s exactly what they were reporting.
Some more investigation and we discovered that, since LocationKit had been compiled on my laptop, when I compiled an app with LocationKit integrated (part of our standard release process), I had zero warnings because those paths existed on my local machine.
But as soon as someone else compiled an app with LocationKit in it, they would see all of the warnings referencing a path on my machine, the machine on which LocationKit had been built!
It appears Apple made some changes to the default compilation behavior in Xcode 7 which caused those warnings to be thrown. So, we made the following changes which fixed our issue and stopped LocationKit from throwing these errors when added to an app:
Under the Project Target > Build Settings, change the “Debug Information Format” from “DWARF with dSYM File” to “DWARF”, particularly for Release. See attached screenshot (click for full size image):
Alter the following build settings to inhibit such warnings: