IOS: C ++ compiler warnings after upgrading to Xcode 8.3

I updated to Xcode 8.3 last week. I cannot get rid of this compiler warning:

ld: warning: direct access in function 'std::__1::basic_filebuf<char, std::__1::char_traits<char> >::open(char const*, unsigned int)' from file '/Path/To/Derived/Data/Xcode/DerivedData/myapp/Build/Intermediates/myapp.build/Debug-iphoneos/myapp.build/Objects-normal/arm64/myapp_lto.o' to global weak symbol 'std::__1::basic_filebuf<char, std::__1::char_traits<char> >::open(char const*, unsigned int)' from file '/Path/To/Derived/Data/Xcode/DerivedData/myapp/Build/Intermediates/myapp.build/Debug-iphoneos/myapp.build/Objects-normal/arm64/myapp_lto.o' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.

What I was trying to solve this warning:

  • Change Symbols Hidden by Default

    to YES - for all purposes
  • Change Symbols Hidden by Default

    to NO - for all purposes
  • Essentially everything here (although not completely related)
  • Clearing / deleting derived data / etc
  • I added -fvisibility=hidden

    to my purpose, and also for all cocoapod purposes. ( here)

Any understanding is greatly appreciated. Thank you in advance.

UPDATE 2017-04-10:

This seems to be a problem caused by NewRelicAgent. Removing cocoapod from my project eliminates the warning. Studying this carefully.

+3


source to share


1 answer


Relic new support response:



We reviewed these warnings with our Mobile Engineering team. They reported that these warnings are related to a difference introduced in Xcode 8.3 that does not apply to the latest iOS New Relic agent created in Xcode 8.2.

They also emphasized that these warnings do not have any negative consequences, but please let us know if you notice any other issues.

This issue will likely be fixed in the next version of the agent when it is built with Xcode 8.3.

+1


source







All Articles