When I launch my app with XCode or with react-native run-ios
in an iOS emulator, it work good.
But if I do the same in a real device, it not work. I've got this error :
Undefined symbols for architecture arm64:
"YGConfig::YGConfig(int (*)(YGConfig*, YGNode*, YGLogLevel, char const*, char*))", referenced from:
_YGConfigNew in libyoga.a(Yoga.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
More informations :
react: 16.9.0
react-native: 0.60.5
Real device: iPad with iOS 12.4.4
Someone has solution ? Thanks
I just spent the last hour banging my head against the wall with this exact same issue, and stumbled across this comment in their repo that ended up fixing it for me. In my case it turned out to be an issue with Xcode's cache:
https://github.com/facebook/react-native/issues/25349#issuecomment-518830530
close xcode and any other IDE
rm -rf ~/library/developer/xcode/deriveddata
rm -rf ~/.rncache
rm -rf node_modules && npm install && cd ios && rm -rf Pods && pod install && cd ..
Hopefully that will help you, too!