首页 > 解决方案 > 升级了 React Native,现在找不到 glog/logging.h 文件

问题描述

我已经将 React Native 从 0.52 升级到了 0.59 我知道这是一个巨大的飞跃,但我认为不妨继续努力,现在得到glog/logging.h file not found.

我也知道这里有类似的问题。但是我已经尝试了所有的方法,但我似乎无法解决这个问题。

这是我尝试过的事情之一:

cd node_modules/react-native/scripts && ./ios-install-third-party.sh && cd ../../../

cd node_modules/react-native/third-party/glog-0.3.4/ && ../../scripts/ios-configure-glog.sh && cd ../../../../

任何人都会认为这会解决它吗?我没有留下任何石头,它只是不想消失。乐趣!

在此处输入图像描述

标签: xcodereactjsreact-nativeglog

解决方案


在此处找到对带有空格的 XCode 应用程序名称的引用:

https://github.com/facebook/react-native/issues/19774

我还发现,当我使用多个版本时,我有“XCode 10.1.app”。当我将其更改为 XCode.app(并运行类似sudo xcode-select --switch /Applications/Xcode.app更新 XCode 路径之类的操作)时,我的应用程序构建时没有出现此问题,也没有我迄今为止使用 glog 遇到的任何其他问题。


推荐阅读