ofundefined
ofundefined

Reputation: 3309

Why do I get this error: 'import of module appears within namespace' on xcode with react-native?

I got this react-native project and I had to use use_modular_headers! on Podfile. I suppose I needed that because this pod MercadoPagoSDK is some sort of dynamic library (╯°□°)╯ which I don't really know what that means on iOS development world.

Now I'm getting this error during build on xcode!

import of module 'glog.glog.log_severity' appears within namespace 'google'

I am not finding a solution to this user_modular_headers! thing. I already tried all ideas from here https://github.com/google/glog/issues/393 but I am afraid none of them worked.

Upvotes: 12

Views: 11093

Answers (1)

avicene
avicene

Reputation: 187

Make sure to add the following code to your podfile, including the modular_headers part:

pod 'glog', :podspec => '../node_modules/react-native/third-party-podspecs/glog.podspec', :modular_headers => false

for more information check out the full thread here: https://github.com/facebook/react-native/issues/26217

Upvotes: 9

Related Questions