React Native CFBundleIdentifier Not Exist

在使用React Native最新版0.46.1的時候發(fā)現(xiàn)了問題:

Failed to install the requested applicationAn application bundle was not found at the provided path.Provide a valid path to the desired application bundle.Print: Entry, ":CFBundleIdentifier", Does Not ExistCommand failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/ReactNativexx.app/Info.plistPrint: Entry, ":CFBundleIdentifier", Does Not Exist

使用各種方法都沒有解決
比如react-native upgrade

后面終于找到了原因
node_modules/react-native/ios-install-third-party.sh執(zhí)行結(jié)果不正確,可能是網(wǎng)絡(luò)原因。

手動下載
https://github.com/google/glog/archive/v0.3.4.tar.gz
https://github.com/google/double-conversion/archive/v1.1.5.tar.gz
https://github.com/react-native-community/boost-for-react-native/releases/download/v1.63.0-0/boost_1_63_0.tar.gz
https://github.com/facebook/folly/archive/v2016.09.26.00.tar.gz

1.放進 ~/.rncache/.
2.解壓到node_modules/react-native/third-party/

在xcode中運行,會發(fā)現(xiàn)報錯,缺少glob config.h
1.進入終端cd node_modules/react-native/third-party/glog-0.3.4
2.運行../../scripts/ios-configure-glog.sh
會發(fā)現(xiàn)腳本幫忙生成了很多東西,包括config.h

再次在Xcode運行,就成功了。

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容